BEGIN
  FOR l_rec IN (SELECT 1
                  FROM user_tables
                 WHERE table_name = 'EXT_LEADTIMES') LOOP
    EXECUTE IMMEDIATE 'DROP TABLE ext_leadtimes';
  END LOOP;
END;
/
create table ext_leadtimes
(
  ENTY_CODE  varchar2(240),
  METY_CODE  varchar2(240),
  MESC_CODE  varchar2(240),
  SVCPT_CODE  varchar2(240),
  LEAD_TIME  varchar2(240)
   )  
   ORGANIZATION EXTERNAL
( type oracle_loader
default directory webmip_bulk_load
access parameters
( records delimited by NEWLINE
  READSIZE 10485760
  skip 2
  fields terminated by ',' 
  optionally enclosed BY '"'
  missing field values are null
  (
  ENTY_CODE,
  METY_CODE,
  MESC_CODE,
  SVCPT_CODE,
  LEAD_TIME
  )
)
location ('LEADTIMES.csv')
)
reject limit unlimited
/
