MartinF
Member²
Hi,
My problem occur in PLSD 7.xx and 8rc2. It is partially caused by Oracle but maybe you can do something for this.
Let say a user schedule a job with DBMS_JOB. The user nls_language=FRENCH. So the job is schedule and the value of NLS Environment is : NLS_LANGUAGE='FRENCH' NLS_TERITORY=....
Now if me i am connecting to PLSD and edit the job to change the date of the schedule(My NLS_LANGUAGE=AMERICAN).
So i go in the window, change the date and hit apply. From this point the NLS Environment become: NLS_LANGUAGE='AMERICAN' NLS_TERITORY=....
So the job will not run with the good language that it was initially schedule.
The way i found to bypass this problem is instead of pressing apply after changing the date is pressing "View Sql", cut and paste the code in another window, execute an alter session and run the code to change the date.
Here is what i found that is causing the problem. If i only change the date of my dbms_job and click on view SQL. The generated code is :
The problem with this code is the "what" parameter. When using dbms_job.change, if "what" is not null the NLS Environement are initialized to use the new value of the current session. But if instead you run code like this:
The NLS Environement stay as it was before the change.
So i don`t know if it`s possible for you to detect if only the date have change but if yes, you could probably pass null to the what parameter and this will solve the problem with the change of NLS Environement values.
Sorry for the long post,
Regards
My problem occur in PLSD 7.xx and 8rc2. It is partially caused by Oracle but maybe you can do something for this.
Let say a user schedule a job with DBMS_JOB. The user nls_language=FRENCH. So the job is schedule and the value of NLS Environment is : NLS_LANGUAGE='FRENCH' NLS_TERITORY=....
Now if me i am connecting to PLSD and edit the job to change the date of the schedule(My NLS_LANGUAGE=AMERICAN).
So i go in the window, change the date and hit apply. From this point the NLS Environment become: NLS_LANGUAGE='AMERICAN' NLS_TERITORY=....
So the job will not run with the good language that it was initially schedule.
The way i found to bypass this problem is instead of pressing apply after changing the date is pressing "View Sql", cut and paste the code in another window, execute an alter session and run the code to change the date.
Here is what i found that is causing the problem. If i only change the date of my dbms_job and click on view SQL. The generated code is :
Code:
begin
sys.dbms_job.change(job => 91057,
what => 'GIC_EDI.AIGUILLER_TRANSMISSION(''2293'');',
next_date => to_date('24-09-2009 15:15:00', 'dd-mm-yyyy hh24:mi:ss'),
interval => 'null');
commit;
end;
/
The problem with this code is the "what" parameter. When using dbms_job.change, if "what" is not null the NLS Environement are initialized to use the new value of the current session. But if instead you run code like this:
Code:
begin
sys.dbms_job.change(job => 91057,
what => null,
next_date => to_date('24-09-2009 15:15:00', 'dd-mm-yyyy hh24:mi:ss'),
interval => 'null');
commit;
end;
/
The NLS Environement stay as it was before the change.
So i don`t know if it`s possible for you to detect if only the date have change but if yes, you could probably pass null to the what parameter and this will solve the problem with the change of NLS Environement values.
Sorry for the long post,
Regards