How to insert data into two tables using single control file?

Answers were Sorted based on User's Feedback



How to insert data into two tables using single control file?..

Answer / rajiv

LOAD DATA
APPEND
DISCARDMAX 9999999
INTO TABLE UPLOAD_HDR
WHEN agreementno='~'
FIELDS TERMINATED BY ","
(
AGREEMENTNO CHAR(20),
FILENAME CHAR(30),
BATCHID constant 112)
INTO TABLE UPLOAD_TMP
WHEN agreementno <>'~'
FIELDS TERMINATED BY ","
TRAILING NULLCOLS
(
AGREEMENTNO POSITION(1) CHAR(20),
EMI_AMT INTEGER EXTERNAL(16),
BATCHID constant 112)

Is This Answer Correct ?    10 Yes 1 No

How to insert data into two tables using single control file?..

Answer / emmanuel - tcs

A Small changes in above control file

Add below insert stmt to above CTL File
Insert into Table Tab_name_1 -- This is for one table
Insert into Table Tab_name_2 -- This is for Second Table

First mention first table column and mention second table
columns

Is This Answer Correct ?    3 Yes 1 No

How to insert data into two tables using single control file?..

Answer / bobbyiiit

Using "When"

we use "When" condition to load data into multiple tables.

Syntax:

Load Data infile '&1'
Insert into table table1
(
.
.
.
.
)
Insert into table table2
when <condiation>
(
.
.
.
);

Is This Answer Correct ?    1 Yes 0 No

Post New Answer

More Oracle Apps Technical Interview Questions

when we run payment batch what are the 3 concurrent programs?

1 Answers   Genpact, Wipro,


about TCA architecture

1 Answers   TCS,


diff between key and descriptive flexfield.

4 Answers   Convergys,


In unix Schell sript what is very 1st line to be wriiten .

2 Answers   IBM,


hi gurus my name is ramesh i was completed orcale apps technical trainning i wnt to put 3+yrs experience is it correct r not ,if any freshers jobs are available in market pls suggest me. my mail id rameshmcaou@gmail.com and contact no is 9000342411

3 Answers   Oracle,


In one flat file i got headers and lines data how you can write control file now ?

1 Answers   KPMG,


What should be the batch size (number of customer records) general guidelines for optimal performance?

1 Answers  


What is the Use of User Exit in Oracle apps and when we are developeing the new report you need to pass one parameter called P_CONC_REQUEST_ID,what is the use of this parameter and is it mandatory.Can't we develop report without this User exit's and P_CONC_REQUEST_ID parameter

12 Answers   TCS,


can we execute one concurrent program through another concurrent program?

1 Answers   KPIT,


what are the functions you are used in utl_file at the time of transferring the data?

2 Answers   Oracle,


What are the files we submit while your program move to testing instance?

4 Answers   Cap Gemini,


what is difference between API and Interface?

2 Answers   Infogain,


Categories
  • Oracle Apps Technical Interview Questions Oracle Apps Technical (547)
  • Oracle Apps Financial Interview Questions Oracle Apps Financial (793)
  • Oracle Apps Manufacturing Interview Questions Oracle Apps Manufacturing (53)
  • Oracle Apps HRMS Interview Questions Oracle Apps HRMS (169)
  • Oracle Apps CRM Interview Questions Oracle Apps CRM (9)
  • Oracle Apps SCM Interview Questions Oracle Apps SCM (141)
  • Oracle Install Base Interview Questions Oracle Install Base (62)
  • Oracle Service Contracts Interview Questions Oracle Service Contracts (101)
  • Oracle Apps AllOther Interview Questions Oracle Apps AllOther (114)