how to use Global temporary table [message #645436] |
Sun, 06 December 2015 23:40 |
snsiddiqui
Messages: 172 Registered: December 2008
|
Senior Member |
|
|
I create this global temporary table and create a form, where I am calling report through a push button but report isn't showing records.
Kindly advise me, how to use global temporary table in reports.
-------------------------
-- GLOBAL TEMPORARY TABLE
-------------------------
create global temporary table PROD_INV
(
WDATE DATE,
DOCNO VARCHAR2(10),
CUSTM VARCHAR2(7)
)
on commit preserve rows;
-----------------
-- CALLING REPORT
-----------------
Run_Product(REPORTS, :Global.Report_Path || 'SD_PRODINV', ASYNCHRONOUS, RUNTIME,FILESYSTEM, pl_id, NULL);
|
|
|
|
Re: how to use Global temporary table [message #645445 is a reply to message #645444] |
Mon, 07 December 2015 02:33 |
|
Littlefoot
Messages: 21823 Registered: June 2005 Location: Croatia, Europe
|
Senior Member Account Moderator |
|
|
A workaround might be populating the GTT in report's After Parameter Form trigger, if possible. For example, if you used a (stored) procedure in a form, you can call it from the report as well - you'd just pass required parameters. Or, if you can distinguish which records you want in the GTT and have a mechanism (i.e. WHERE clause) to do so, report can easily do it as well.
Otherwise, you might need to discard the GTT idea and return back to a "normal" table (and include some kind of an identifier which will prevent two or more users reading the same data).
|
|
|