This content has been marked as final. Show 8 replies
user1427702 wrote:I'd really like to see this implemented too, but you wouldn't have to change your code. You'd need to spend time renaming the entries in the model to match what your code is using.
Any update on this topic?
I have been using dotConnect by Devart for some time now and I have a large Entity model with all Pascal case entities.
How nice it would be to move to ODP.NET but if all generated entities remain UPPER_CASE then I'll have a lot of code to change.
That's tedious of course, but far less tedious then updating the code to upper case names. :)
A question for everyone asking for Pascal Case. Pascal Case means that capitalized words are concatenated.
Now, that seems easy enough if it means removing underscores when converting to EF (and remembering to add them back in the DB) and capitalizing just the first letter and lower casing the remaining ones. But what about columns named "ProductName"or "ProdName" or "DriversLicenseId"? How would a data provider know to capitalize the "N" in the name?
Does DevArt do that or just capitalize only the first letter and remove underscores?
For Devart it all happens in <edmx:Mappings>.
For example ...
<ScalarProperty Name="ScorecardId" ColumnName="SCORECARD_ID" />
<ScalarProperty Name="SubsystemId" ColumnName="SUBSYSTEM_ID" />
<ScalarProperty Name="ScorecardDs" ColumnName="SCORECARD_DS" />
<ScalarProperty Name="RollupHierarchy" ColumnName="ROLLUP_HIERARCHY" />
<ScalarProperty Name="Division" ColumnName="DIVISION" />
<ScalarProperty Name="GrpId" ColumnName="GRP_ID" />
<ScalarProperty Name="AsHierarchy" ColumnName="AS_HIERARCHY" />
<ScalarProperty Name="MaxDrills" ColumnName="MAX_DRILLS" />
<ScalarProperty Name="DimId" ColumnName="DIM_ID" />
<ScalarProperty Name="CubeNm" ColumnName="CUBE_NM" />
<ScalarProperty Name="HierarchyNm" ColumnName="HIERARCHY_NM" />
Can't be too hard eh Oracle?
I discussed it with my team. One of the key things we want to know is why developers are spending so much time changing the case between Oracle and EF. Is there a compelling functional need to change from upper case to Pascal case, not just a cosmetic one?
On the feature request tool and this thread, people have asked for the feature, but not offered a reason why Pascal casing is so important that they would be willing to conduct the manual mapping changes.
If there is a strong case for an automated mapping file, Oracle can make the case to Microsoft as well to implement mapping case into EF tools. That way, all providers can benefit from this infrastructure.
Keeping with the platform and organizational naming conventions is a pretty compelling reason, I'd say. People aren't spending upwards of an hour on a large model renaming everything because they're bored.
Is that a functional reason? Probably not. But strictly speaking you could name the variables anything and it'd function. We give things clear and consistent names to improve code quality.