Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
For vTableNo = 1 to noOfRows('XXX')
Let vTable = peek('X',vTableNo-1,'XXX');
Select * from [$(vTable)] ;
Next vTableNo
For vTableNo = 1 to noOfRows('XXX')
Let vTable = peek('X',vTableNo-1,'XXX');
Select * from [$(vTable)] ;
Next vTableNo
Thank you Henric. This was extremely helpful. I appreciate you taking the time to share this with me!
Hello, try this script.
LET vOwner = 'TONIAL';
OLEDB CONNECT32 TO [Provider=MSDAORA.1;User ID=$(vOwner);Data Source=XE] (XPassword is SXRQVYRNJbaEDYEGRJBA);
Tabs:
SQLTables;
TABLES:
LOAD TABLE_SCHEMA&'.'&TABLE_NAME AS TN,*
Resident Tabs
Where TABLE_TYPE ='TABLE'
and not WildMatch(TABLE_NAME, 'APEX*')
and TABLE_SCHEMA = Upper('$(vOwner)');
DROP Table Tabs;
FOR i = 0 to NoOfRows('TABLES');
LET vTableName = Peek('TABLE_NAME', $(i), 'TABLES');
TRACE $(vTableName);
$(vTableName):
SQL SELECT *
From $(vTableName);
LET vNoOfRows = NoOfRows('$(vTableName)');
IF $(vNoOfRows) >0 THEN
TRACE STORE TABLE $(vTableName);
STORE $(vTableName) INTO $(vTableName).QVD;
ENDIF
DROP Table $(vTableName);
NEXT
This is close to what I ended up with. Excellent example. Thank you for your time and effort.