How to create an external table.



How to create an external table...

Answer / ravi satyadarshi

//1st of all create a directory to store ur external table
CREATE DIRECORY EMP_DIR AS '/FLAT_FILES' ;


// now write the following line of code to create an
external table at that directory

CREATE TABLE OLDEMP(ENO NUMBER,ENAME CHAR(20),DOB DATE,)
ORGANIZATION EXTERNAL
( TYPE ORACLE_LOADER
DEFAULT DIRECTORY EMP_DIR
ACCESS PARAMETERS
(RECORDS DELIMITED BY NEWLINE
BADFILE 'BAD_EMP')
LOGFILE 'LOG_EMP'
FIELDS TERMINATED BY ','
(ENO CHAR , ENAME CHAR DOB CHAR DATE_FORMAT
DATE MASK "DD-MON-YYYY"
)
)
LOCATION ('EMP1.TXT')
)
PARALLEL 5
REJECT LIMIT 200;

Is This Answer Correct ?    2 Yes 0 No

Post New Answer

More DB Development Interview Questions

When installing the datastage7.5x2 edtion iam getting aproblem i.e the cpu count is 2 but the cpu count in installation is one . how can i install in my p.c (system is dual core).

1 Answers  


I have a few records all are same structures data, I want to store data in multiple targets how

1 Answers   CTR, Infosys, Polaris,


Any sample or model question of punjab national bank for deputy manger IT or any sample of PNB.any1 plz do send on

1 Answers  


How would you design a database for an online site, which would average a million hits a day?

1 Answers  


Explain the family trees and connection by clause.

1 Answers  


You have a table with three columns: amount1, amount2, and amount3 in a single row only one of these three columns will have a value and the other two will be null. Write a sql query to retrieve the values from these columns?

1 Answers  


Explain the cube operator?

1 Answers  


What are the constraints on severity level in raiseerror?

1 Answers  


Write the difference between case version and decode version.

2 Answers  


Explain the role of indexing in databases?

1 Answers  


On friday, you issued several insert statements using query analyzer. You then verified the data had been correctly entered with a select statement on monday, your users report that the data is not there what happened?

1 Answers  


Explain about the storage and physical database design?

1 Answers  


Categories