Coder Social home page Coder Social logo

Comments (2)

blm14 avatar blm14 commented on June 11, 2024

Oracle actually stores dates as a series of bytes not a string like MySQL or other databases. You have to wrap all dates in oracle in TO_DATE with an argument specifying what format the date string is in. in this case it would be

To_date(name_of_column,’YYYYMMDD’)

Are you using SQL*Loader or command line sqlldr?

From: leeanhu789 [mailto:[email protected]]
Sent: Sunday, August 28, 2016 9:28 PM
To: OHDSI/DatabaseConnector [email protected]
Subject: [OHDSI/DatabaseConnector] load date format (yyyymmdd, e.g. 20091001) from sample CDM format csv file into oracle database (#28)

Dear All,
I am trying to load Lee Evans provided CDM format csv files into my database. I encountered one problem. Hope someone advise.

some csv data files (e.g. CDM_death.csv, CDM_visit_occurrence.csv) have dates columns, but the format is yyyymmdd., e.g. 20080413). In oracle.sql, the format for DEATH_DATE column for DEATH table is defined as "date". The sqlldr failed to load the this numerical format "yyyymmdd" into DEATH table.
I thought there must be a reason Lee Evans used this kind of numerical format in the csv file.

Could someone advise how to load this type of format as a date format into oracle database? I am using sqlplus.
Thank you very much in advance!
Lian


You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHubhttps://github.com//issues/28, or mute the threadhttps://github.com/notifications/unsubscribe-auth/AHXnuA8BbrQC0lZoc6BY_2opbFzzfBqxks5qkjW7gaJpZM4JvEsV.

from databaseconnector.

leeanhu789 avatar leeanhu789 commented on June 11, 2024

@blm14 ,
Thank you for your help. I am using SQL*Loader, not in command line. I will follow your instruction and let you know the result. Thank you again for your kind help.
Lian

from databaseconnector.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.