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

c# - SignalR: "Protocol error: Unknown transport." when navigating to hub -

class - Kivy: how to instantiate a dynamic classes in python -

python - mayavi mapping a discrete colorbar on a surface -