StrataFrame Forum

ORACLE (Build) Query problem

http://forum.strataframe.net/Topic18893.aspx

By Ertan Deniz - 9/2/2008

I've executed object.FillByPrimaryKey on ORACLE database. (

I've got the query by setting debug-on feature.

The query :

SELECT "id", "group_id", "base_message_id", "type", "state", "inserted_user_id", "insert_date" FROM "dbo"."sn_srv_messages" WHERE id IN (TongueARAM0)  

After the query was executed, "ORA-00942: table or view does not exist." Error.

After I 've cleared the "" characters and run the query on a DB tool like SQLNavigator, the Query was succesfully executed.

Why does strataframe fail to run the query ? Why are "" characters generated by the framework ? 

Note : I've run the same query with object.FillDataTable. The operation is also successful.

By Dustin Taylor - 9/2/2008

The configuration for Oracle is to use quotes as the delimiters for quoted identifiers. Did you run the query with or without quotes when you used FillDataTable?

Regardless, quotes are the rule for Oracle, so it sounds as though the issue lies elsewhere.

By Ertan Deniz - 9/2/2008

I've run the query through FillDataTable method without quotes.
By Ertan Deniz - 9/2/2008

What does it mean "rules for the ORACLE" ?

Is there a configuration on ORACLE Database or strataframe ?

By Ertan Deniz - 9/2/2008

One thing to make it clear ;

Quotes in the from part of SQL cause (From "dbo".sn_srv_messages") "table or view does not exist" message. If I remove the quotes then quotes in the selected fields part of the sql causes error. 

By Greg McGuffey - 9/3/2008

A quoted identifier is setup in Oracle (or SQL Server or any other database) that allow you to have identifiers (table names, column names, index names) that break the rules for names of such things (which is specific to the DBMS your using, Oracle in this case). This could be the case if you want spaces in names or want to use a reserved name for something. Dusting is just saying that by default, Oracle uses double quotes to quote an identifier in this way. This normally is a nicety that allows you more freedom (and typically less errors) when dealing with tables. Personally, I think using reserved names for identifiers is a bad idea, so I never use quoted identifiers, but that is not always an option. In any case, check out this link for more info:



http://download.oracle.com/docs/cd/B10500_01/server.920/a96540/sql_elements9a.htm



I looked a bit on Google but couldn't find out how to configure this for a database. Unsure
By Ertan Deniz - 9/3/2008

Thanks.
By Ertan Deniz - 9/3/2008

I've searched but I couldn't find any information about configuration for quoted identifiers.

I've found related topic in a support article (Link was attached)

There are simple rules ;

"If the table and column names were created in Oracle without quoted identifiers,
use all uppercase names."
"If the table and column names were created in Oracle with quoted identifiers,
use the same case for all letters of the names as was used when the names were created in Oracle."

http://support.microsoft.com/kb/240340