Voici les étapes que j'ai effectué pour créer une table externe basée sur un fichier que j'ai mis
dans C:\testdirectory\data\department.dat




profil DBA

C:\testdirectory\data



CREATE OR REPLACE DIRECTORY bad_dir AS 'C:\testdirectory\bad\';
CREATE OR REPLACE DIRECTORY log_dir AS 'C:\testdirectory\log\';
CREATE OR REPLACE DIRECTORY data_dir AS 'C:\testdirectory\data\';

grant read, write on directory log_dir to titi;

(GRANT) acceptée.

grant read, write on directory data_dir to titi;

(GRANT) acceptée.

grant read, write on directory bad_dir to titi;



Profil titi OU profil DBA


CREATE TABLE department_ext (
dept_id NUMBER(15)
, name VARCHAR2(100)
, location VARCHAR2(100)
)
ORGANIZATION EXTERNAL (
TYPE ORACLE_LOADER
DEFAULT DIRECTORY data_dir
ACCESS PARAMETERS (
records delimited by newline
badfile bad_dir:'department.bad'
logfile log_dir:'department.log'
fields terminated by ',' optionally enclosed by '"'
missing field values are null
(dept_id, name, location)
)
LOCATION ('department.dat')
)
REJECT LIMIT UNLIMITED
/

Table créée.



Profil titi OU profil DBA


select * from department_ext

*
ERREUR à la ligne 1 :
ORA-29913: erreur d'exécution de l'appel ODCIEXTTABLEOPEN
ORA-29400: erreur de cartouche de données
KUP-04063: unable to open log file department.log
OS error The system cannot find the file specified.
ORA-06512: à "SYS.ORACLE_LOADER", ligne 14
ORA-06512: à ligne 1



Je ne comprend pas cette erreur.

Pouvez-vous m'aider?

Merci encore