AnsweredAssumed Answered

Repeat row for specific table

Question asked by satish.kumar.enni on Jan 11, 2017
Latest reply on Jan 11, 2017 by gilta03

Hi ,

 

I  have below test data has to be generated using data maker, currently i am having multiple entries in my data pool i know which is not standard practice. i want to make my script to be in a single row that which generates multiple rows, please suggest me any functions

 

My output should be

sno    Line_No   count   Item_No   child_Sno 

123      0                4        1876765        0

124      1                0         2900847      123

125      2                0         8767377       123

126      3                0         5454545       123

 127      4                0        7878787       123

 

describe of above columns

sno-we have our own oracle procedure we call using function @execproc which returns next value of that sequence

Line_No- since these are static values we are hard coding

count: every time where column line_no=0 then column count  row should have count of below entries, in my case below count of entries are 4 those which are having value zeros

item_no:These are static, i am hardcoding but order shouldn't change with respective adjacent columns

child_sno: when column line_no=0 then child_sno row value should have 0, remaining entries should have first column value of sno column

 

 

 

Hopefully i have explained clearly, can you suggest how can i make my script more compact and smart.

 

 

Thanks,

Satish.

Outcomes