Results 1 to 4 of 4
  1. #1
    Join Date
    Mar 2014
    Posts
    2

    Unanswered: Help needed in writing a batch file- A newbie

    SET sql_connect = user/pass@db

    SET control = 'ABC.ctl'

    SET data = 'DATA.csv'

    SET log = 'logfile.log'

    SET bad = 'badfile.bad'

    sqlldr %sql_connect% control =%control% log=%log% data =%data% bad = %bad%

    I am getting a syntax error. It would be great if someone can please help.

    Thanks

  2. #2
    Join Date
    Aug 2003
    Location
    Where the Surf Meets the Turf @Del Mar, CA
    Posts
    7,776
    Provided Answers: 1
    C:\Users\bcm\Downloads\words>SET data = 'DATA.csv'

    C:\Users\bcm\Downloads\words>echo %data%
    %data%

    C:\Users\bcm\Downloads\words>set fubar=ID10T

    C:\Users\bcm\Downloads\words>echo %fubar%
    ID10T

    C:\Users\bcm\Downloads\words>
    You can lead some folks to knowledge, but you can not make them think.
    The average person thinks he's above average!
    For most folks, they don't know, what they don't know.
    Good judgement comes from experience. Experience comes from bad judgement.

  3. #3
    Join Date
    Mar 2014
    Posts
    2
    Thanks. I liked the way you replied.

  4. #4
    Join Date
    Aug 2003
    Location
    Where the Surf Meets the Turf @Del Mar, CA
    Posts
    7,776
    Provided Answers: 1
    now that you see how to do it correctly, posted working script back here
    You can lead some folks to knowledge, but you can not make them think.
    The average person thinks he's above average!
    For most folks, they don't know, what they don't know.
    Good judgement comes from experience. Experience comes from bad judgement.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •