FunkMaster
Technical User
Hello
ARRggh
i get this error message below for the script important points below that, as far i see its all in order and i have swaped lots of bits about:-
ORA-06510: PL/SQL: unhandled user-defined exception
ORA-06512: at "SYS.UTL_FILE", line 98
ORA-06512: at "SYS.UTL_FILE", line 157
ORA-06512: at line 143
ORA-06510: PL/SQL: unhandled user-defined exception
OPEN Cur_Job_Data;
v_stmt := 'FETCH CURSOR Cur_Job_Data';
LOOP
FETCH Cur_Job_Data
INTO
V_JOB_WINDOW_START,
V_JOB_WINDOW_END,
V_JOBSTATUS_DESC,
V_ABS_APPT_TYPE,
V_MPAN,
V_JOBCODE_DESC,
V_DISP_NOTES,
V_ENQ_NO,
V_APPT_NO,
V_RESP_UNITS;
IF Cur_Job_Data%NOTFOUND THEN
EXIT;
END IF;
utl_file.put_line(v_output_file, V_JOB_WINDOW_START||','||
V_JOB_WINDOW_END||','||
V_JOBSTATUS_DESC||','||
V_ABS_APPT_TYPE||','||
V_MPAN||','||
V_JOBCODE_DESC||','||
Replace(Replace(Replace(Replace(Replace(Replace(V_DISP_NOTES,',',' ') ,chr(13),' '),'*',' '),chr(10),' '),chr(8),' '),chr(9),' ')||','||
V_ENQ_NO||','||
V_APPT_NO||','||
V_RESP_UNITS);
END LOOP;
Close Cur_Job_Data ;
anyone help
oh v_job_window_start and END is an date and defined as date
and this is the cursor below:-
CURSOR Cur_Job_Data is
SELECT
to_char(APPOINTMENT.JOB_WINDOW_START,'dd/mm/yyyy HH24:mi:ss'),
to_char(APPOINTMENT.JOB_WINDOW_END,'dd/mm/yyyy HH24:mi:ss'),
JOBSTATUS.DESCRIPTION,
APPOINTMENT.ABS_APPT_TYPE,
APPOINTMENT.MPAN,
JOBCODE.DESCRIPTION,
APPOINTMENT.DISPATCHER_NOTES,
APPOINTMENT.ENQUIRY_NUMBER,
APPOINTMENT.APPOINTMENT_NO,
RESPONSIBILITY_UNITS.DESCRIPTION
FROM
SRC.APPOINTMENT APPOINTMENT,
SRC.DEPOTS DEPOTS,
SRC.JOBCODE JOBCODE,
SRC.JOBSTATUS JOBSTATUS,
SRC.RESPONSIBILITY_UNITS RESPONSIBILITY_UNITS
WHERE
JOBSTATUS.REC_ID = APPOINTMENT.JOBSTATUS_REC_ID
AND JOBCODE.REC_ID = APPOINTMENT.JOBCODE_REC_ID
AND DEPOTS.REC_ID = APPOINTMENT.DEPOT_REC_ID
AND DEPOTS.RESPONSIBILITY_UNITS_REC_ID = RESPONSIBILITY_UNITS.REC_ID
AND APPOINTMENT.JOB_WINDOW_START >= v_start_Report_date
And APPOINTMENT.JOB_WINDOW_START < v_end_Report_date
AND JOBSTATUS.DESCRIPTION='Unassigned'
;
5% is not an rise, its an poke in the eye.
ARRggh
i get this error message below for the script important points below that, as far i see its all in order and i have swaped lots of bits about:-
ORA-06510: PL/SQL: unhandled user-defined exception
ORA-06512: at "SYS.UTL_FILE", line 98
ORA-06512: at "SYS.UTL_FILE", line 157
ORA-06512: at line 143
ORA-06510: PL/SQL: unhandled user-defined exception
OPEN Cur_Job_Data;
v_stmt := 'FETCH CURSOR Cur_Job_Data';
LOOP
FETCH Cur_Job_Data
INTO
V_JOB_WINDOW_START,
V_JOB_WINDOW_END,
V_JOBSTATUS_DESC,
V_ABS_APPT_TYPE,
V_MPAN,
V_JOBCODE_DESC,
V_DISP_NOTES,
V_ENQ_NO,
V_APPT_NO,
V_RESP_UNITS;
IF Cur_Job_Data%NOTFOUND THEN
EXIT;
END IF;
utl_file.put_line(v_output_file, V_JOB_WINDOW_START||','||
V_JOB_WINDOW_END||','||
V_JOBSTATUS_DESC||','||
V_ABS_APPT_TYPE||','||
V_MPAN||','||
V_JOBCODE_DESC||','||
Replace(Replace(Replace(Replace(Replace(Replace(V_DISP_NOTES,',',' ') ,chr(13),' '),'*',' '),chr(10),' '),chr(8),' '),chr(9),' ')||','||
V_ENQ_NO||','||
V_APPT_NO||','||
V_RESP_UNITS);
END LOOP;
Close Cur_Job_Data ;
anyone help
oh v_job_window_start and END is an date and defined as date
and this is the cursor below:-
CURSOR Cur_Job_Data is
SELECT
to_char(APPOINTMENT.JOB_WINDOW_START,'dd/mm/yyyy HH24:mi:ss'),
to_char(APPOINTMENT.JOB_WINDOW_END,'dd/mm/yyyy HH24:mi:ss'),
JOBSTATUS.DESCRIPTION,
APPOINTMENT.ABS_APPT_TYPE,
APPOINTMENT.MPAN,
JOBCODE.DESCRIPTION,
APPOINTMENT.DISPATCHER_NOTES,
APPOINTMENT.ENQUIRY_NUMBER,
APPOINTMENT.APPOINTMENT_NO,
RESPONSIBILITY_UNITS.DESCRIPTION
FROM
SRC.APPOINTMENT APPOINTMENT,
SRC.DEPOTS DEPOTS,
SRC.JOBCODE JOBCODE,
SRC.JOBSTATUS JOBSTATUS,
SRC.RESPONSIBILITY_UNITS RESPONSIBILITY_UNITS
WHERE
JOBSTATUS.REC_ID = APPOINTMENT.JOBSTATUS_REC_ID
AND JOBCODE.REC_ID = APPOINTMENT.JOBCODE_REC_ID
AND DEPOTS.REC_ID = APPOINTMENT.DEPOT_REC_ID
AND DEPOTS.RESPONSIBILITY_UNITS_REC_ID = RESPONSIBILITY_UNITS.REC_ID
AND APPOINTMENT.JOB_WINDOW_START >= v_start_Report_date
And APPOINTMENT.JOB_WINDOW_START < v_end_Report_date
AND JOBSTATUS.DESCRIPTION='Unassigned'
;
5% is not an rise, its an poke in the eye.