Unix Technical Forum

IXF LOADing w/ different column orders

This is a discussion on IXF LOADing w/ different column orders within the DB2 forums, part of the Database Server Software category; --> DB2 WSUE LUW v8.2 FP4 (aka v8.1 FP11) RHEL AS 4 I am EXPORTing in IXF format from one ...


Go Back   Unix Technical Forum > Database Server Software > DB2

Register FAQ Members List Calendar Search Today's Posts Mark Forums Read
  #1 (permalink)  
Old 02-27-2008, 06:28 AM
aj
 
Posts: n/a
Default IXF LOADing w/ different column orders

DB2 WSUE LUW v8.2 FP4 (aka v8.1 FP11)
RHEL AS 4

I am EXPORTing in IXF format from one schema and then LOADing into
another schema.

The DB modeling tool I am using likes to put the PK columns at the
very top of the CREATE TABLE ddl, so the ordering of the columns in
the FROM schema is different from the ordering in the TO schema.
All of the columns are there named the same way, just different order.

When I try to do the LOAD w/ no METHOD specified, it complains about
columns being non-null and how the input is invalid. However, if I
use METHOD N on the LOAD and explicitly list out the column order,
it works.

The column names are the same on both sides. Why does the order of the
columns matter? Can't LOAD figure this out by itself?

TIA

aj

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #2 (permalink)  
Old 02-27-2008, 06:28 AM
darshan.vaishnav@gmail.com
 
Posts: n/a
Default Re: IXF LOADing w/ different column orders

The Column Order always matters. When you export data from table, it
will have the column order.

So your "From" data will have the perticular order. While import/Load
you should maintain that order, if your "TO" Table is same as your
"FROM" table including column order.

But if "TO " table column order is changed then you have to use the
Method N.

Be careful while using load and import because if you have big datafile
to import and if the column order does not match, it may take long
time, because every time it will try to import/Load the data it will
throw an error. So take care in that.

Hope this helps.

Darshan.

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On
Forum Jump


All times are GMT. The time now is 09:56 AM.


Powered by vBulletin® Version 3.6.5
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
SEO by vBSEO 3.2.0
www.UnixAdminTalk.com