I have the following code and im not sure what is missing or coded wrong here...
Using: Oracle 10g
The reason that i'm basically using the same exact set of code to output data because the color_cursor (color_tab) doesn't has some individuals that the color_cursor_pre (color_tab_pre) has so basically what i'm trying to do is if a individual isn't found in the color_tab to go down a search for them in the color_tab_pre...hope this explaniataion helps. Currently when i try to compile the code is throws an error at the second 'open x cursor'...so i'm assuming im missing some code there.
Edited by: user652714 on Dec 26, 2008 8:55 AM
Using: Oracle 10g
Code:
open x_cursor;
loop
fetch x_cursor bulk collect into x_tab;
for ii in 1 .. x_tab.count loop
personID := x_tab(ii).personID;
if profile_tab.exists (ipersonID) and
color_tab.exists(ipersonID) then
utl_file.put_line(file_handle, x_tab(ii).first_name|| ',' ||
x_tab(ii).last_name || ',' ||
profile_tab(ipersonID).weight || ',' ||
profile_tab(ipersonID).birth_year || ',' ||
color_tab(personID).skin || ',' ||;
end if;
end loop;
elsif
open x_cursor;
loop
fetch x_cursor bulk collect into player_tab_pre;
for ii in 1 .. x_tab.count loop
ipersonID := player_tab_pre(ii).personID;
if profile_tab.exists (ipersonID) and
color_tab_pre.exists(ipersonID) then
utl_file.put_line(file_handle, x_tab(ii).first_name|| ',' ||
x_tab(ii).last_name || ',' ||
profile_tab(ipersonID).weight || ',' ||
profile_tab(ipersonID).birth_year || ',' ||
color_tab_pre(personID).skin || ',' ||
end if;
end loop;
exit when x_cursor%notfound;
end loop;
close x_cursor;
The reason that i'm basically using the same exact set of code to output data because the color_cursor (color_tab) doesn't has some individuals that the color_cursor_pre (color_tab_pre) has so basically what i'm trying to do is if a individual isn't found in the color_tab to go down a search for them in the color_tab_pre...hope this explaniataion helps. Currently when i try to compile the code is throws an error at the second 'open x cursor'...so i'm assuming im missing some code there.
Edited by: user652714 on Dec 26, 2008 8:55 AM