db2 luw - Using a variable to reference a schema and table in DB2 stored procedure -


I am storing schema names in the table column (e.g., SOURCE_SCHEMA , TARGET_SCHEMA ) and retrieving the schema name, I want to work with a variable in the DB2 stored procedure (e.g., vSchema ).

How can I then use variables in an SQL statement, for example:

  SELECT * to vSchema.TABLE_NAME  
< P> Is there a better way of doing this? Thanks in advance.

UTIILET Pat = TU_LBRIAA, OTA_LBRAIA


Comments

Popular posts from this blog

winforms - C# Form - Property Change -

java - Messages from .properties file do not display UTF-8 characters -

javascript - amcharts makechart not working -