Re: better sql code

  • From: Jared Still <jkstill@xxxxxxxxx>
  • To: raja4list@xxxxxxxxx
  • Date: Wed, 26 Oct 2005 22:43:01 -0700

As someone has pointed out to me, if you can access the data
with an external table, why not just use a single SQL statement
to update the table.

That would make a lot of sense now, wouldn't it?

Jared (red-faced :)


On 10/25/05, Jared Still <jkstill@xxxxxxxxx> wrote:
>
> Comments inline:
>
> create an external table and a test table
> drop table loadtest;
>
> create table loadtest(
> filename varchar2(50)
> )
> organization external
> (
> type oracle_loader
> default directory forall_dir
> access parameters
> (
> records delimited by newline
> badfile 'loadtest.bad'
> discardfile 'loadtest.dis'
> logfile 'loadtest.log'
> fields terminated by "," optionally enclosed by '"'
> (
> filename char
> )
> )
> location ('loadtest.txt')
> )
> reject limit unlimited
> /
>
> ...
>
>


--
Jared Still
Certifiable Oracle DBA and Part Time Perl Evangelist

Other related posts: