Select to view content in your preferred language

Field name "level" is changed to "level_" in an sde

152
3
Jump to solution
2 weeks ago
JürgenBiendara
Regular Contributor

Hello,

A customer would like to generate a data model via ArcGIS Pro 3.1 in a SQL Server Arc SDE. The basis for this is an existing data model in another system. I have noticed that some attribute names in the SDE are supplemented with an underscore (e.g. "level" becomes "level_"), probably because they are keywords. I have two questions about this:

1.

Do the affected attribute names depend on the underlying database system (are they possibly keywords of the underlying database system)?

2.

Is there a list of attribute names which, as in our case "level", are supplemented with an underscore when the data model is defined or which may/may not be used for a specific reason?

Thank you very much for your help and best regards,

Jürgen

Tags (2)
0 Kudos
1 Solution

Accepted Solutions
CodyPatterson
MVP Regular Contributor

Hey @JürgenBiendara 

For #1, the attribute names do depend on the underlying database system from what I've found. I also have a feature class called Level, and in my PostrgreSQL database, it's just "Level" as it's non-reserved but in Microsoft SQL Server, it's "Level_".

For #2, here's a list of the reserved keywords that will do this: https://learn.microsoft.com/en-us/sql/t-sql/language-elements/reserved-keywords-transact-sql?view=sq...

This is for SQL Server, other database platforms this will be different, for reference, search the database platform and "reserved words" or "key words" and you'll find your problematic names!

Cody

View solution in original post

3 Replies
CodyPatterson
MVP Regular Contributor

Hey @JürgenBiendara 

For #1, the attribute names do depend on the underlying database system from what I've found. I also have a feature class called Level, and in my PostrgreSQL database, it's just "Level" as it's non-reserved but in Microsoft SQL Server, it's "Level_".

For #2, here's a list of the reserved keywords that will do this: https://learn.microsoft.com/en-us/sql/t-sql/language-elements/reserved-keywords-transact-sql?view=sq...

This is for SQL Server, other database platforms this will be different, for reference, search the database platform and "reserved words" or "key words" and you'll find your problematic names!

Cody

DavidPike
MVP Notable Contributor

Cody's answer is absolutely correct, and I have first hand experience of 'level' not working in a SQL Server view.

JürgenBiendara
Regular Contributor

Thank you for your help, guys!

0 Kudos