Re: Pro*C -- How to pass a value (String) into a SQL !!

From: WS <ws_at_d255s269.mch.sni.de>
Date: 27 Mar 1995 06:55:03 GMT
Message-ID: <3l5ng7$1bn_at_luxor.mch.sni.de>


Yih-feng Hwang (CS 688) (yhwang) wrote:
: Hi there,
 

: Does any one know how to pass a value (string) into a host variable ?
 

: Ex:
: EXEC SQL SELECT :Attribute_Name
: FROM :Name_of_TABLE;
 

: Is it possible to pass values into :Attribute_Name and :Name_of_TABLE ?

: Thanks In Advanced,
 

: Yih-Feng Hwang
: George Mason University
 

: yhwang_at_fusion.site.gmu.edu

To pass table names or attributes into host variables you need to use dynamic SQL, probably Method 4. Please refer to your Oracle Precompiler Guide, chapter 9.

Have fun with it...

Stefan  

--
--------------------------------------------------------------------------
   Stefan Griesser

   currently at:                          permanent address:

   SNI BS2000 TP 133                      FMI, Universit"at Passau
   oracle_at_mch.sni.de                      griesser_at_fmi.uni-passau.de
--------------------------------------------------------------------------
Received on Mon Mar 27 1995 - 08:55:03 CEST

Original text of this message