HELP !!!! : How Set v$session.module in Oracle Forms [message #181079] |
Thu, 06 July 2006 11:51  |
henryhrcr
Messages: 6 Registered: July 2006
|
Junior Member |
|
|
Hello.
I need to set v$session.module or v$session.program in oracle forms, but i net to set before the post-logon trigger in database was executed.
I really need identify my application, and in the post-logon trigger verify if the application is my application.
Generaly, a forms application not set the v$sesssion.module or v$session.program. They are Null. So, I need set but before the post-logon trigger in database is executed, because i need to do some validations if the application is running is 'My-Application'.
Thanks for your help.
|
|
|
|
Re: HELP !!!! : How Set v$session.module in Oracle Forms [message #181235 is a reply to message #181140] |
Fri, 07 July 2006 10:46   |
henryhrcr
Messages: 6 Registered: July 2006
|
Junior Member |
|
|
Thanks David.
Let me explain you.
I need identify my application, so i use dbms_application_info.set_module in the POST-LOGON of the principal form of my application, i use :
dbms_application_info.set_module('MY-APPLICATION',NULL);
this sentence let me identify my application, so if i query the v$session.module in sql, i can see 'MY-APPLICATION' in v$session. This work good !!!
But the problem is, i need to do some restrictions in the POST-LOGON trigger in DATABASE, but this trigger in database start before the post-logon trigger in the form. So when i going to verify in the post-logon in database, the v$session.module is not set yet. This is in blanks or null.
This is the code example :
IN THE FORM
IN POST-LOGON TRIGGER
Dbms_Application_Info.Set_Module('MY-APPLICATION',Null);
IN DATABASE LEVEL
CREATE OR REPLACE TRIGGER Check_Restrictions
After Logon ON DATABASE
declare
vc_module varchar2(200);
begin
select S.module
into vc_Module
from v$session S
where audsid = USERENV('sessionid');
if vc_Module <> 'MY-APPLICATION' then
-- Fire the restrictions
end if;
end;
The problem is, when my application starts, the after logon trigger in database starts before POST-LOGON trigger in the forms, so the v$session.module is not set yet, so i can not do the restrictions.
I Apreciate your help.
Thanks !!!
|
|
|
Re: HELP !!!! : How Set v$session.module in Oracle Forms [message #181237 is a reply to message #181079] |
Fri, 07 July 2006 10:50   |
henryhrcr
Messages: 6 Registered: July 2006
|
Junior Member |
|
|
Thanks David.
Let me explain you.
I need identify my application, so i use dbms_application_info.set_module in the POST-LOGON of the principal form of my application, i use :
dbms_application_info.set_module('MY-APPLICATION',NULL);
this sentence let me identify my application, so if i query the v$session.module in sql, i can see 'MY-APPLICATION' in v$session. This work good !!!
But the problem is, i need to do some restrictions in the POST-LOGON trigger in DATABASE, but this trigger in database start before the post-logon trigger in the form. So when i going to verify in the post-logon in database, the v$session.module is not set yet. This is in blanks or null.
This is the code example :
IN THE FORM
IN POST-LOGON TRIGGER
Dbms_Application_Info.Set_Module('MY-APPLICATION',Null);
IN DATABASE LEVEL
CREATE OR REPLACE TRIGGER Check_Restrictions
After Logon ON DATABASE
declare
vc_module varchar2(200);
begin
select S.module
into vc_Module
from v$session S
where audsid = USERENV('sessionid');
if vc_Module <> 'MY-APPLICATION' then
-- Fire the restrictions
end if;
end;
The problem is, when my application starts, the after logon trigger in database starts before POST-LOGON trigger in the forms, so the v$session.module is not set yet, so i can not do the restrictions.
I Apreciate your help.
Thanks !!!
|
|
|
|