Updating multiple records in oracle Furry live sex


updating multiple records in oracle-81updating multiple records in oracle-55updating multiple records in oracle-80

Regards Michel Hi Michel, I am giving another example:- update application_xml_q2007 a set a.xml_name = (select b.xml_name from application_xml_info_add b where a.form_id = b.form_id); Here the subquery is returning multiple records.

Suppose the table has 100 records and inner query returns 100 different values...should I update the table. Hi update application_xml_q2007 a set a.xml_name = (select b.xml_name from application_xml_info_add b where a.form_id = b.form_id); Here the subquery is returning multiple records.

Please suggest me as how to update multiple records in this kind of scenario. Thanks and Regards, Mona This 2 sentences have no relation.

The first one means you want to update a field of ONE row with several values which is impossible.

I have created a Cursor: CURSOR c_fgsr IS SELECT DISTINCT SUM(b.qty/1000) inv_qty, a.division division, a.sopcust sopcust, a.program program, a.sopgrp sopgrp, a.sopclothtype sopclothtype, a.color_group color_group, a.sized sized, a.sopmfgtype sopmfgtype, a.product_type product_type, b.scheddate, DECODE(COUNT(a.skutype),1,a.skutype,'****') skutype, DECODE(a.sopmfgtype,'MAKE','NA','SOURCED') mfgloc FROM springs.si_sop_fgitem a, springs.si_sop_fgsr b WHERE = GROUP BY b.item, a.division, a.sopcust, a.program, a.sopgrp, a.sopclothtype, a.color_group, a.sized, a.sopmfgtype, a.product_type, b.scheddate, skutype FOR v_sr IN c_fgsr LOOP INSERT INTO springs.si_sop_aggr_fgsr (sbu, customer, program, sopgrp, cloth_type, fin_type, fin_size, mfg_type, prod_type, fg_type, mfg_loc, Mfg_fac) VALUES (v_sr.division, v_sr.sopcust, v_sr.program, v_sr.sopgrp, v_sr.sopclothtype, v_sr.color_group, v_sr.sized, v_sr.sopmfgtype, v_sr.product_type, v_sr.skutype, v_sr.mfgloc, NULL); n_ins_inv_cnt := n_ins_inv_cnt 1; END LOOP; This Insert statement inserts 100 records.