This content has been marked as final. Show 9 replies
try to create a variable with that type in a package scope in database. One trigger can set the variable, and then other trigger read the package-scope variable.
Do you want me to define the pl sql type as an object in DB ?
1 person found this helpful
I have defined the pl/sql type in database package. So I have initialized the pl/sql table type in one trigger.I guess you are talking about PL/SQL arrays, as Types are something completely different.
As you can't access Database Package Globals directly from forms you'd need to have setter/getters; the quick and dirty method would be
which populate / access a global array declared in the package body. The init is called in the first trigger, and the get is called in the second trigger. Of course you have to realize that the state of this array is held for your entire database session. In addition holding a lot of data in this package global array is probably a very bad idea as there will be a lot of memory allocated in the PGA of the database which isn't freed that easy.
procedure init_array(some_parameter in some_datatype); -- function get_array return your_array_type;
It all boils down to: what problem are you trying to solve with this?
My aim is to restore checked box after Control F11 ....this means .. if the user checked some check box and do f11 --> control F11 ... I need to restore those checked boxes... so what I am thinking to store this checked box position in PL/SQL table or array when KEY_COMMIT trigger and when user press F11 ... COntroll F11 ... i will restore this values by calling that pl/sql table type in trigger KEY-EXEQRY ....
I will try with your solution will let you know ...
Please let me know if their is any other way to achieve this ..
A package is not a bad solution, but you don't need to create it in the database. Create a Forms module package, and, as said, use a getter/setter function to pass it from one trigger to another one.
Let me try that .... I will update once it is done and working :)
Declare the PL/SQL table type in the package specification.
yes, you can define it in database. Alternatively, you can define in Form in the program unit sub tree as told by the Guru.
Thank the problem is resolved.