Results 1 to 7 of 7

Thread: sql*loader

  1. #1
    Join Date
    Mar 2004
    Posts
    13

    Post Unanswered: sql*loader

    how can I load data which should be later then specific date
    into the database with sql*loader

  2. #2
    Join Date
    Jul 2003
    Posts
    2,296

    Re: sql*loader

    Originally posted by kfir
    how can I load data which should be later then specific date
    into the database with sql*loader
    please explain in greater clarity and post an example
    - The_Duck
    you can lead someone to something but they will never learn anything ...

  3. #3
    Join Date
    Mar 2004
    Posts
    13
    I have a file which look like this

    column1|column2|date_column|column3

    example ->
    dsdsd|hhhhh|17/1/2004|jjjj

    I want to load into the database only the date which later from
    specific date ( 20/2/2004 )

  4. #4
    Join Date
    Mar 2004
    Posts
    13
    I have a file which look like this

    column1|column2|date_column|column3

    example ->
    dsdsd|hhhhh|17/1/2004|jjjj

    I want to load into the database only rows that consist date which later from
    specific date ( 20/2/2004 )

  5. #5
    Join Date
    Mar 2004
    Posts
    10
    You can have conditions in SqlLoader.
    However the best would be to put a check constraint on the column of the table and set the errors high in SqlLoader command line. Those rows will automatically get filtered out.
    Sudip Datta
    Server Technologies
    Oracle Corporation

  6. #6
    Join Date
    Jul 2003
    Posts
    2,296
    you can use a case statement to filter out what you want.
    something like:

    PHP Code:
    RDNG_DT  "CASE
                      WHEN to_date(:RDNG_DT, 'dd/mm/yyyy')
                         >  to_date('20/2/2004','dd/mm/yyyy')
                      THEN
                         to_date(:RDNG_DT, 'dd/mm/yyyy')
                      END"

    since you are not converting any other strings to dates, sql*loader will just spit the row out as an error. Just make sure to set your ERRORS parameter large enough to account for that.
    - The_Duck
    you can lead someone to something but they will never learn anything ...

  7. #7
    Join Date
    Mar 2004
    Posts
    13
    thanks alot

Posting Permissions

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