Sql LOader- Mysql Migration to Oracle
Hai all,
I am using Sql loader to migrate Mysql Database to Oracle 10g.
Almost all the migration is succesfully done but i have got stuck at one point. Since We know that in Mysql there is Null Date format is 0000:00:00 00:00 and when i am trying to load this date in oracle it says that cannot insert 0 in date.
Since In my mysql there is date combination of both regular dates and 0000:00:00 ..... so i want that what shoud i use in Sql*Loader that .When it seen the 0000:00:00 in date column it insert the date 1900:01:01 and when it sees the reglular date ..it simply insert in date .
Thanks and Regards!!
Pankaj
Hi,
The decode command I mwntioned means
if :date = 0000:00:00 00:00
then
to_date('1900:01:01','YYYY:MM:DD')
else
to_date( <give your date format> )
end
Change your command to
publishtodate "decode(:publishtodate, '0000:00:00 00:00', to_date('1900:01:01','YYYY:MM:DD'), to_date(:publishtodate,'YYYY/MM/DD' ) )"
The last bit (i.e. to_date(:publishtodate,'YYYY/MM/DD' ) ) is the else part, which will load the actual date data.
Here you have to give the format of dates of your MySql generated data.
Whats the format of date data? I guess, its not just YYYY/MM/DD, there must be time component (as the error text says).
If the dates are like "2007/05/21 23:45", then give the format "YYYY/MM/DD HH24:MI" or else follow your format.
Cheers
Similar Messages
-
Can SQL*Loader be used for Oracle html pages, for e.g Customer, Tasks etc
Hi,
Can SQL*Loader be used for Oracle html pages, for e.g Customer, Tasks etc.
Reason: We have a job that creates leads, tasks in 11i, but r12 is not working as expected, an SR is open with Oracle for a long time and no solution so far. I am thinking of using SQL*loader to populate the data, but these are html pages. Will SQL* Loader work?
12.1.4 / 11g db
Appreciate your inputs.
Thanks,
KCan SQL*Loader be used for Oracle html pages, for e.g Customer, Tasks etc. It should work.
Reason: We have a job that creates leads, tasks in 11i, but r12 is not working as expected, What is the issue you have with R12?
an SR is open with Oracle for a long time and no solution so far. I am thinking of using SQL*loader to populate the data, but these are html pages. Will SQL* Loader work?What was Oracle feedback? Did they say it is certified and can be used?
Thanks,
Hussein -
Where is SQL*Loader error message in oracle 8i documentation?
I have error message which is SQL*Loader-522: lfiopn failed for
file (D:\xiaw\Badfiles\faculty_info.BAD). I can't find the
solution from oracle 8i documentation. Can someboday help me?
Thanks
weiWei:
They're in Chapter 24 of the Error Messages manual:
SQL*Loader-00522 lfiopn failed for file (string)
Cause: LFI failed to open the file.
Action: Check for any possible operating system errors and/or
potential memory problems.
Hope this helps.
Peter -
SQL Server 2000 Migration to Oracl 10g
Hi,
We are plannig to migrate the SQL Server 2000 to Oracle 10g. I have following queries.
1. Does the Oracle SQL Developer tool is the one that to be used? (Previously OWMB used to support SQL Server 2000, but it is no longer supporting.)
2. When I tried to migrate using Oracle SQL Developer tool, there were some errors for @@spid and the tool did go further?
3. In OMWB it used to provide the details like how many DB objects migrated successfully and how many failed, how to generate similar reports in Oracle SQL Developer?
Please let me know.
ThanksMake sure you use
Oracle SQL Developer Migration Workbench
http://www.oracle.com/technology/tech/migration//workbench/index_sqldev_omwb.html -
SQL Server 2005 Migration to Oracle 10g
Does anyone have any idea if a Migration Workbench beta plug-in exists for SQL Server 2005 to Oracle 10g. I have a production system waiting to be moved over to Oracle and the users are getting impatient.
If there is nothing yet, does anyone have an alternate procedure to migrate a small schema (20 tables + 10 stored procedures) with a large amount of data?Probably late in the day for this but
The workbench cannot handle SS2K5 directly at the moment. However as long as no new SS2K5 functionality has been used with a few tweaks this can be achieved.
1. Firstly use the SS2K offline capture scripts to build the directories for the database(s) you want to capture.
2 Secondly edit
(a) SS2K_SYSLOGINS.dat and take out long SS2K5 user records
(b) SS2K_SYSINDEXES.dat change FIRST ( forth column) to a value (say hex 1).
(c) SS2K_SYSUSERS.dat change ROLES (sixth column) to a value (say hex 1).
This should now load into the workbench. If it does not check the error.log file in <OMWB HOME>\log. -
Help: SQL server 2000 migration to Oracle 10.1.0.2
Hi all,
I need to migrate databases from SQL Server 2000 to Oracle 10.1.0.2 on HP-UX.
I read the SQL Developer documentation, but it doesn't seem to be available for HP-UX (only Windows, Mac OS, and Linux).
If I can't use this tool, what do you suggest to do this migration?
Any info. would be appreciated.
SIStored procedures will have to be converted manually--T-SQL is far enough removed from PL/SQL that there is no choice.
DTS generally handles the data conversions ok, for standard data types, I'm not 100% sure on blobs. Standard indexes and views should come accross as well. -
MS SQL Server 2008 Migrating to Oracle 11.2g
Hi.........
Can any body help me how to migrate the MS SQL Server 2008 to Oracle 11.2g. Plz do needful ASAP.
Thanks in Advance.
RanjithRanjith,
You can use the SQL*Developer migration workbench to migrate from SQL*Server to Oracle. It is free to download and use.
You can download SQL*Developer from here -
http://www.oracle.com/technetwork/developer-tools/sql-developer/overview/index.html
then there is information on migration from non-Oracle systems here -
Oracle Database Migration Technology
http://www.oracle.com/technetwork/database/migration/index-084442.html
From here there is a link to specific information on migrating SQL*Server -
http://www.oracle.com/technetwork/database/migration/sqlserver-095136.html
Please review this information and if you have any further questions or problems it would be better to ask them in this forum -
Forum: Database and Application Migrations
Database and Application Migrations
One thing I would recommend is that unless the SQL*Server database is very small you make an offline migration. This gives you more control over how it is done and to resolve any problems.
Regards,
Mike -
MS SQL Server 2000 migrate to Oracle 8
Hi -
i am trying to migrate 8 distinct databases from SQL Server 2000 to Oracle 8 using the Migration Assistant Utility.
as i am new to Oracle, i am having some challenges.
1. do i need to migrate the SQL Server "Master" database first?
2. the Migration Assistant runs and is able to "define" the source model, but when it tries to create the Oracle model, it errors with a number of problems, typically with messages like "null" for the keys.
can anybody explain and/or point to me a clear and concise explanation of what is the procedure here?
thanksCheck out the following tech bulletin
http://otn.oracle.com/support/tech/migration/workbench/htdocs/bulletins/sqlserver_01.htm
it will help u
Hi -
i am trying to migrate 8 distinct databases from SQL Server 2000 to Oracle 8 using the Migration Assistant Utility.
as i am new to Oracle, i am having some challenges.
1. do i need to migrate the SQL Server "Master" database first?
2. the Migration Assistant runs and is able to "define" the source model, but when it tries to create the Oracle model, it errors with a number of problems, typically with messages like "null" for the keys.
can anybody explain and/or point to me a clear and concise explanation of what is the procedure here?
thanks -
SQL Connect problem - migration from Oracle 7.3.4 to Oracle 8.0.6
Our development environment has just been upgraded from HP10.20
to HP11 and the database from Oracle 7.3.4.0 to Oracle 8.0.6.0.
I am now having problems with one of the PRO*C programs. The old
executable( compiled in the old enviroment HP10/Oracle734) is
working fine in the new environment. But after I successfully re-
compiled this program in the new environment, the new executable
is not working and stops at the statement: 'EXEC SQL CONNECT:
userid'. I have checked the userid and Oracle settings, they are
correct. Right after the EXEC SQL, I've tried checking the
status of connection, but it never gets there. The
only change to the make file is using
$(ORACLE8_HOME)/precomp/lib/env_precomp.mk instead of using
$(ORACLE7_HOME)/precomp/env_precomp.mk
Other PRO*C programs which are using exactly the same connecting
statemment are working fine.
Anyone have any ideas, I would appreciate them?
Thanks,I am upgrading with precisely the same varaibles that you encountered
and am receiving the same inability to do a simple CONNECT with
Pro*C. Were you able to resolve this problem? If so, please reply
with some guidance.
Thank you.
- Tad Franson
[email protected] -
Insalling SQL Loader in 11.2 Oracle client
Hi,
I have installed 11g client on my Linux machine but do not see sqlldr installed alongwith.
Can someone please help me getting sqlldr utility installed with my client?
Not sure if Oracle ships SQLLDR with 11g clients now. If No, Any steps get sqlldr running on my machine?
Thanks,
TejBeen a while since I installed that, but as I recall there was a separate option you needed to select that was not selected by default.
"Database Utilities" or something like that.
You can still install it after the fact. -
I have this database running in my-sql. nOw i want to convert into ORACLE.Can anyone shed light on this please..does sql loader
support this?
Thanks in advance..your help will be much appreciated..
ashishvipinvijay wrote:
Hi All,
In my application, the existing database is oracle. we need to migrate from Oracle db to My SQL.
We need to have the below procedure;
1.export data from Oracle.
2.Import data to My SQL from the exported oracle file.
and vice versa from My SQL to Oracle.
my questions are
1) is it possible to import .dmp (oracle export data) into My SQL. No you cannot use .dmp which are exported from oracle using exp/expdp utility
2) which tool is better for this migrationUse sql developer to migrate from oracle to my sql
3) Can we get the migration scripts from the tools?Explore sql developer you'll get easy migration
http://www.oracle.com/technetwork/database/migration/mysql-093223.html
http://www.oracle.com/technetwork/database/migration/sqldevelopermigration21-wp-131240.pdf
Here is demonstration which will help you to migrade to oracle from mysql
http://www.oracle.com/technetwork/database/migration/mysqllauncher-086083.html
From oracle to mysql
http://www.ispirer.com/doc/sqlways-oracle-to-mysql-whitepaper.pdf -
Help in calling sql loader and an oracle procedure in a script
Hi Guru's
please help me in writing an unix script which will call sql loader and also an oracle procedure..
i wrote an script which is as follows.
!/bin/sh
clear
#export ORACLE_SID='HOBS2'
sqlldr USERID=load/ps94mfo16 CONTROL=test_nica.ctl LOG=test_nica.log
retcode=`echo $?`
case "$retcode" in
0) echo "SQL*Loader execution successful" ;;
1) echo "SQL*Loader execution exited with EX_FAIL, see logfile" ;;
2) echo "SQL*Loader execution exited with EX_WARN, see logfile" ;;
3) echo "SQL*Loader execution encountered a fatal error" ;;
*) echo "unknown return code";;
esac
sqlplus USERID=load/ps94mfo16 << EOF
EXEC DO_TEST_SHELL_SCRIPT
it is loading the data in to an oracle table
but the procedure is not executed..
any valuable suggestion is highly appriciated..
Cheersmultiple duplicate threads:
to call an oracle procedure and sql loader in an unix script
Re: Can some one help he sql loader issue. -
Utility to convert ASE fmt files to ctl files for sql*loader
Does anyone have a utility to convert bcp format files to oracle ctl files for use with sql*loader?
Hi,
The Oracle Migration Workbench will produce both BCP and the equivalent Oracle .ctl files for all tables in a database.
Regards
John -
How can I use sql loader to load a text file into a table
Hi, I need to load a text file that has records on lines tab delimited into a table. How would I be able to use the sql loader to do this? I am using korn shell to do this. I am very new at this...so any kind of helpful examples or documentation would be very appreciated. I would love to see some examples to help me understand if possible. I need help! Thanks alot!
You should check out the documentation on SQL*Loader in the online Oracle document titled Utilities. Here's a link to the 9iR2 version of it: http://otn.oracle.com/docs/products/oracle9i/doc_library/release2/server.920/a96652/part2.htm#436160
Hope this helps. -
I use SQL Loader to read a file into a table. In my tests a lot of rows are rejected and written to the bad file. But there are no error messages.
Is there a way to find out why the row was rejected.The Bad File
The bad file contains records that were rejected, either by SQL*Loader or by the Oracle database server. Some of the possible reasons for rejection are discussed in the next sections.
SQL*Loader Rejects
Datafile records are rejected by SQL*Loader when the input format is invalid. For example, if the second enclosure delimiter is missing, or if a delimited field exceeds its maximum length, SQL*Loader rejects the record. Rejected records are placed in the bad file.
Oracle Rejects
After a datafile record is accepted for processing by SQL*Loader, it is sent to the Oracle database server for insertion into a table as a row. If the Oracle database server determines that the row is valid, then the row is inserted into the table. If the row is determined to be invalid, then the record is rejected and SQL*Loader puts it in the bad file. The row may be invalid, for example, because a key is not unique, because a required field is null, or because the field contains invalid data for the Oracle datatype.
YOU WILL get more information
sqlldr help=y
also send your control file syntax
kuljeet pal singh
Maybe you are looking for
-
Recovery and proper SSD configuration
I have a U845-s406 and I had to restore it last night. Using the restore DVD's I created, everything went well except one thing and the "Techs" at the Toshiba Support Center have no idea what I am talking about. They kept asking what SSID I was conne
-
HT204400 Apple TV won't play anything with different password
I recently changed my password and now Apple TV will not play anything I purchased with the old password. Can anyone tell me how to resolve this? Cheers
-
Oracle RAC on AIX gpfs.base
Oracle Database Enterprise Edition 11.2.0.2 IBM AIX 6.1 Hi I need to install Oracle RAC on IBM AIX 6.1. For shared storage, we need gpfs.base as per documentation. We are using Netapp SAN for storage. Are there any alternatives to gpfs.base which can
-
Hi , I would like to create a variant for a custom report with time being dynamic.Purpose is to execute this report every hour as background job with time also as an input .ie suppose job is running every hour , report should fetch data within this
-
Always show my Adobe Flash need upgrade but it was the latest
I visit Youtube website though Firefox however the website always shows that my Adobe Flash need an upgrade. But, my Adobe Flash was already the latest one. I try to visit the website with another browser and Youtube didn't show my Adobe Flash need u