Click here to Skip to main content
15,912,578 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hi
I want to Import the Data from CSV to Oracle, while importing i need to

validate each cell data with required format and need to check whether the column names are same or not.

Please suggest how to go ahead.
Posted

There are a lot of options for this:

1) You can use articles in CodeProject for reading CSV files (just search) and doing the logic yourself.
2) There are programs for data migrations (just search google).
3) SQL server has a data transform wizard which can do this.
 
Share this answer
 
There is a lot of way to go about this problem and from your question it looks like you need to perform some specified data checks and validation and in this case you can use two things

1)Build an application which will read the data from csv file do the validation and then store it in some offline storage(like datatable) and once you have all the valid data in one table you can insert the data into Oracle database at once.it's always a good practice to keep a record of invalid data in some sort of file or something(it's up to you how you want to do that)

2)Create the table in the database and put a validation conditions for column (something like it will allow the inset only when the date is valid and all). I think it's called check constraint in Oracle and then you can use the default utility provided by oracle to inset the data into table and save invalid data into some other file.

Hope this helps
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900