Dual Case Column names fail in select ORDER BY clause
675390Dec 12 2008 — edited Dec 12 2008This one is solved, but I thought someone might be able to explain why it happens.
I'm a newbie, since I just downloaded Oracel XE last night, and am trying it out.
I set up a trivial table with 4 text columns. As it happened, I used dual case for some of my column names, such as 'Nickname'.
When trying out the Query Builder, the Select statement failed whenever I added a sort.
After some head scratching and back-and-forth with the sample data base (HR), I finally renamed all the columns to upper case. (e.g. column 'Nickname' became 'NICKNAME'). Then it works.
Seems like a bug, but maybe it's just a feature. Here's the code generated by the Query Builder. As you can see, there are no quotes around the Table name or column names in the ORDER BY clause (and the dual case version of the column name works if I put the quotes in manually and run it with SQL command.) Seems quirky.
select "TEAMS"."NICKNAME" as "NICKNAME",
"TEAMS"."CITY" as "CITY",
"TEAMS"."DIVISION" as "DIVISION",
"TEAMS"."CONFERENCE" as "CONFERENCE"
from "TEAMS" "TEAMS"
order by TEAMS.NICKNAME ASC