Solved

How to Load Date Field to Timestamp(6) Field in Oracle Using SQLLOADER?

Posted on 2014-11-22
1
418 Views
Last Modified: 2014-11-23
Dear Experts,

I want to load CSV (comma-delimited) text files to an Oracle table using SQLLOADER. In text file, one of the fields comes in Date Format YYYY-MM-DD HH:MI:SS. However, in the table the corresponding  field is TIMESTAMP(6). How can I load this field to that table?

Other thing: How can I do "INSERT INTO TAB1 (A) SELECT X FROM TAB2" if A is TimeStamp(6)  and X is DATE?

BR
0
Comment
Question by:GurcanK
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
1 Comment
 
LVL 35

Accepted Solution

by:
johnsone earned 500 total points
ID: 40460565
There shouldn't be a problem loading dates into timestamp fields.  The subsecond portion of the timestamp will just be all 0s.

Are you getting an error with SQL*Loader?  If so, then you need to specify the date format in the control file.

The insert statement you have should work without issue.
0

Featured Post

PeopleSoft Has Never Been Easier

PeopleSoft Adoption Made Smooth & Simple!

On-The-Job Training Is made Intuitive & Easy With WalkMe's On-Screen Guidance Tool.  Claim Your Free WalkMe Account Now

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

When it comes to protecting Oracle Database servers and systems, there are a ton of myths out there. Here are the most common.
Shell script to create broker configuration file using current broker Configuration, solely for purpose of backup on Linux. Script may need to be modified depending on OS-installation. Please deploy and verify the script in a test environment.
This video shows how to Export data from an Oracle database using the Datapump Export Utility.  The corresponding Datapump Import utility is also discussed and demonstrated.
This video shows how to recover a database from a user managed backup

734 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question