Home » SQL & PL/SQL » SQL & PL/SQL » Regarding bulk update
Regarding bulk update [message #239662] Wed, 23 May 2007 00:33 Go to next message
rolex.mp
Messages: 161
Registered: February 2007
Senior Member
I am updating records in a table using bulk update ....

but since i am using array of reords its throwing an error saying

65/34 PLS-00382: expression is of wrong type
65/34 PLS-00436: implementation restriction: cannot reference fields of
BULK In-BIND table of records

i have also copied the code

FORALL i IN 1..l_count
UPDATE my_fnd_columns
SET last_update_date = l_fnd_cols_rowi).last_update_date,
last_updated_by = l_fnd_cols_row(i).last_updated_by,
last_update_login = l_fnd_cols_row(i).last_update_login,
translate_flag = l_fnd_cols_row(i).translate_flag,
description = l_fnd_cols_row(i).description,
default_value = l_fnd_cols_row(i).default_value,
irep_comments = l_fnd_cols_row(i).irep_comments,
update_permited = l_fnd_cols_row(i).update_permited,
domain_code = l_fnd_cols_row(i).domain_code,
domain_app_id = l_fnd_cols_row(i).domain_app_id,
obsolete = l_fnd_cols_row(i).obsolete
WHERE application_id = l_fnd_cols_row(i).application_id
AND table_name = l_fnd_cols_row(i).table_name
AND column_name = l_fnd_cols_row(i).column_name;


IS there any other alternative for doing the same?
Re: Regarding bulk update [message #239675 is a reply to message #239662] Wed, 23 May 2007 01:03 Go to previous messageGo to next message
dhananjays
Messages: 2
Registered: February 2005
Junior Member
hi,

first of all format your code using the [code] tags.at a glance i see an error at this line.
Quote:
UPDATE my_fnd_columns
SET last_update_date = l_fnd_cols_rowi).last_update_date




regards,
Re: Regarding bulk update [message #239677 is a reply to message #239662] Wed, 23 May 2007 01:11 Go to previous messageGo to next message
Frank
Messages: 7880
Registered: March 2000
Senior Member
An alternative is to define a collection per column, instead of for the whole record.
That means, create 1-dimensional arrays instead of a 2-dimensional.
Re: Regarding bulk update [message #239681 is a reply to message #239662] Wed, 23 May 2007 01:18 Go to previous message
rolex.mp
Messages: 161
Registered: February 2007
Senior Member
Is there any other option for the same ..

Since creating a collection per column may be fine if the columns are less , but if the columns are much more it will not solve the problem right ?
Previous Topic: Is correct function..
Next Topic: Statement Ignored 'Error Message occured while calling for RPAD'
Goto Forum:
  


Current Time: Fri Dec 02 12:44:56 CST 2016

Total time taken to generate the page: 0.11061 seconds