2 Replies Latest reply on Feb 21, 2013 3:13 AM by 927588

    Multiple rows insertion - need help

      Hello all,

      I need to insert multiple rows in the table with a single query and the number of rows is 269470.
      Here one of the columns is determined by another sub query which returns multilple rows and the other 2 columns remain same for all.

      I came up with the following query but need a loop to make it run multiple time(269470 times).

      insert into EMLUSRRECV
      (user_id, storeent_id, receiveml)
      (+(select user_id from users where user_id not in (select distinct user_id from EMLUSRRECV) and CURR = 'USD' and rownum = 1)+, 11154, 1);

      Thanks in advance.