New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Allow to retrieve original field names (without uppercasing) [CORE5766] #6029
Comments
Commented by: Sean Leyne (seanleyne) The Firebird engine is following the SQL standard as it relates to the handling of column names in results, by default all column names are case insensitive, and are returned in upper case. Case sensitive handling for column names is supported via the SQL-92 "Delimited Identifiers" functionality. This requires that column names be defined and always referenced using quotes/". I.e. CREATE TABLE T ("FieldName" as SomeType); and Select "FieldName" from T |
Commented by: fbbt (fbbt) Sean, |
Modified by: fbbt (fbbt)summary: Allow to get original name of fields (without uppercasing) => Allow to retrieve original field names (without uppercasing) |
Commented by: @mrotteveel The way SQL works, if you didn't quote the object names, then those names **are** uppercase, even if you entered them lowercase or mixed case in the query. If you want to get those names as entered, then you must quote them. You really need to motivate why you want this (explain the use case). |
Commented by: fbbt (fbbt) I want to have a way to extract original names. That's all. Original names for tables and fields can be placed in system tables. They can be used by IDEs, report designers, query builders. |
Commented by: @mrotteveel That doesn't explain why you need the case from the query, and it doesn't provide a real use case. For create table xyz (...), the table name is XYZ, and recreating it with create table XYZ (...) or using XYZ in a query builder works just as well. If you want case preserved, you need to use create table "xyz" (...), etc. I'm looking for a rationale (a 'business case' if you will) why the Firebird project should invest time and energy to build something like this, when there are a range of other issues to tackle and new features to build. You need to "sell" this feature (convince 'us' that we should build this). |
Commented by: fbbt (fbbt) This is question of readability and usability. I don'tt want to use underscores for dividing letters. Especially in current restriction of length = 31 symbol. Just compare: - normal names: https://www.devart.com/dbforge/sql/studio/query-builder.html |
Commented by: @asfernandes The request is very obvious, so I don't see any need to sell it. It's obviously as the stored procedures source code being stored as entered, instead of keywords being upper-cased or extra spaces removed. |
Submitted by: fbbt (fbbt)
Duplicates CORE1645
Examples:
-- select FieldName from T
-- select FieldName as FieldNameAlias from T
need a way to get FieldName and FieldNameAlias at client not just in uppercase, but in original case too (as they written in sql)
-- create table TableName (FieldName integer)
need a way to get TableName and FieldName from system tables not just in uppercase, but in an original case too (as they written in statement)
The text was updated successfully, but these errors were encountered: