Home » RDBMS Server » Server Administration » Forms_ddl
Forms_ddl [message #149732] Sat, 03 December 2005 11:11 Go to next message
abubaker0370
Messages: 9
Registered: November 2005
Junior Member
I'm trying to use the following command, but it doesn't sees to work:

FORMS_DDL('alter session set optimizer_mode=rule');

by the way, I'm using Forms 6i with Oracle 9i. I would happy if anyone can give any useful information regarding to the problem.

abubaker
Re: Forms_ddl [message #150070 is a reply to message #149732] Tue, 06 December 2005 02:22 Go to previous messageGo to next message
djmartin
Messages: 10181
Registered: March 2005
Location: Surges Bay TAS Australia
Senior Member
Account Moderator
Have you solved your problem?

David
Re: Forms_ddl [message #150234 is a reply to message #150070] Tue, 06 December 2005 19:20 Go to previous messageGo to next message
abubaker0370
Messages: 9
Registered: November 2005
Junior Member
Thanks for your replay.

I haven't sloved yet.

By the way, The Form seems success, because I am using the follwing commands, and no problems occurred:


FORMS_DDL('commit');

IF NOT FORM_SUCCESS THEN


Many Thanks, I will be waiting
abubaker
Re: Forms_ddl [message #150255 is a reply to message #150234] Tue, 06 December 2005 22:58 Go to previous messageGo to next message
djmartin
Messages: 10181
Registered: March 2005
Location: Surges Bay TAS Australia
Senior Member
Account Moderator
Okay. Please supply the full code that you are running. Have you read the Forms Reference manual concerning this command? Have you tested to make sure that there are no outstanding changes in the form before you do your Forms_ddl call? How do you know that the command is not working?

David
Re: Forms_ddl [message #150257 is a reply to message #150255] Tue, 06 December 2005 23:10 Go to previous messageGo to next message
abubaker0370
Messages: 9
Registered: November 2005
Junior Member
Thanks again

The following is the code:
begin	
  FORMS_DDL('alter session set optimizer_mode=rule');   
  FORMS_DDL('commit');

  IF NOT FORM_SUCCESS THEN
      SHOW_MESSAGE('The Rule optimizer invoking Failed...'); 	
      RAISE FORM_TRIGGER_FAILURE;
      exit_form(NO_VALIDATE);
  ELSE		            	
      SHOW_MESSAGE('The Rule optimizer has been invoked...');
      exit_form(NO_VALIDATE);
  END IF;                              
end;
what do you mean by (outstanding changes).

the command is not working, because when I connected to the SQLPLUS, and tryed 'show parameter optimizer_mode' command, I got 'choose'

abubaker

Mod-upd: Add code tags.

[Updated on: Wed, 07 December 2005 00:03] by Moderator

Report message to a moderator

Re: Forms_ddl [message #150278 is a reply to message #150257] Wed, 07 December 2005 00:09 Go to previous messageGo to next message
djmartin
Messages: 10181
Registered: March 2005
Location: Surges Bay TAS Australia
Senior Member
Account Moderator
I assume that the FORMS_DDL('commit'); statement was added later and that you got the same behaviour when you had FORMS_DDL('alter session set optimizer_mode=rule'); immediately preceding the IF NOT FORM_SUCCESS test.

Concerning outstanding changes the documentation says to "Commit (or roll back) all pending changes before you issue the FORMS_DDL command." so do IF :system.form_status = 'CHANGED' then do a Commit_Form before doing your FORMS_DDL command.

Unfortunately, I don't think the 'alter session set optimizer_mode=rule' command applies to any session other than the current session so by looking in another PL/SQL session is not going to help. You will have to check the PL/SQL documentation on this point.

David
Re: Forms_ddl [message #150279 is a reply to message #150278] Wed, 07 December 2005 00:12 Go to previous messageGo to next message
djmartin
Messages: 10181
Registered: March 2005
Location: Surges Bay TAS Australia
Senior Member
Account Moderator
You can test the Alter Session by signing on to PL/SQL, issue the command, sign off and sign on and see whether the Alter Session is as you wish. I think not as it is a SESSION command, not a configuration change command.

David
Re: Forms_ddl [message #150435 is a reply to message #150279] Wed, 07 December 2005 19:27 Go to previous messageGo to next message
abubaker0370
Messages: 9
Registered: November 2005
Junior Member
Do you mean SQLPLUS. by the way, you are right, I checked it and the session changing was not saved, as when I reconnect to SQLPLUS the session return to 'CHOOSE'.

Do you think there is a way to make it;

thanks for all your replys

abubaker

[Updated on: Wed, 07 December 2005 19:27]

Report message to a moderator

Re: Forms_ddl [message #150441 is a reply to message #150435] Wed, 07 December 2005 19:49 Go to previous messageGo to next message
djmartin
Messages: 10181
Registered: March 2005
Location: Surges Bay TAS Australia
Senior Member
Account Moderator
Change the parameters which are used to start you database. Then restart the database.

David
Re: Forms_ddl [message #150463 is a reply to message #150441] Thu, 08 December 2005 00:24 Go to previous messageGo to next message
abubaker0370
Messages: 9
Registered: November 2005
Junior Member
David, which parameters do you mean, coz what I want to do is changing the 'optimizer_mode' from the my Form.

However, if you meant that to change the parameter from my Form, I did that and restarted my database, but the parameter return how it was 'CHOOSE';

abubaker
Re: Forms_ddl [message #150663 is a reply to message #150463] Fri, 09 December 2005 00:00 Go to previous messageGo to next message
djmartin
Messages: 10181
Registered: March 2005
Location: Surges Bay TAS Australia
Senior Member
Account Moderator
You can change the mode from forms for THIS session.

I don't know whether you can change the 'optimizer_mode' parameter setting PERMANENTLY from the SQL*Plus prompt.

I will move your question to a better forum.

David
Re: Forms_ddl [message #150920 is a reply to message #150663] Mon, 12 December 2005 00:26 Go to previous message
abubaker0370
Messages: 9
Registered: November 2005
Junior Member
Thanks David, I will be waiting

abubaker
Previous Topic: ORA-12560: TNS:protocol adapter error
Next Topic: ORA-01406: fetched column value was truncated when trying to startup the database
Goto Forum:
  


Current Time: Thu Sep 26 18:12:38 CDT 2024