Re: Table substitution with PRO*C Dynamic SQL

From: Joe Fulson-Woytek <joefw_at_eosdev1.gsfc.nasa.gov>
Date: 8 Jun 1993 16:44:48 GMT
Message-ID: <1v2fm0$ivu_at_skates.gsfc.nasa.gov>


In answer to my question about tablemname substitution and dynamic SQL: In article <C8B6AB.5Mu_at_spss.com> brent_at_spss.com (Brent Lambert) writes:
>
>You can't use a variable for a table name. See the section
>"Referencing Host Variables" (page 1-10 in my book) of the first
>chapter in "ORACLE Precompilers, Pro*C Supplement".
:
>each table. Dynamic Method 4 is better (IMO) if you need that kind of
>flexibility.
>
This seems, at this point to be the consensus. And while I accept that you can't do table name substitution with Dynamic Method 3, I am still confused by the following statment in the ORACLE Precompiler manual:

"the names of database objects such as tables and columns need not be specified until runtime"

This is located in the section on Using Method 3. Am I misinterpreting what it says (that with Method 3 you don't have to name the table until runtime), or, as it seems more likely now, is this a documentation mistake and it should just say "such as columns"?

Joe Fulson-Woytek
Code 902/Goddard DAAC
NASA/Goddard Space Flight Center
joefw_at_eosdev1.gsfc.nasa.gov Received on Tue Jun 08 1993 - 18:44:48 CEST

Original text of this message