ORA-0092 error when trying to create an external table
For some reason, I always received the following error whenever I attempt to create an
External table.
ORA-0092:missing or invalid option
This is the code that I am using in SQL Plus:
SQL> create table products (
2 product_no number,
3 description varchar2(100),
4 price varchar2(20)
5 )
6 organization EXTERNAL (
7 type oracle_loader
8 default directory PRODUCT_DIR
9 access parameters
10 ( records delimited by newline
11 badfile 'products.bad'
12 logfile 'products.log'
13 fields terminated by ','
14 )
15 location ('products.csv')
16 )
17 reject ('products.csv')
18 )
19 reject limit unlimited
20 /
organization EXTERNAL (
*
ERROR at line 6:
ORA-00922: missing or invalid option
This is the statement that I used to create my directory:
CREATE DIRECTORY PRODUCT_DIR AS 'd:\products';
Does that directory have to be an actual physical directory in UNIX for this to work, or
will it be looking for a products folder in the d drive of my Windows NT machine?