dbTalk Databases Forums  

DTS Datapump Column Order Unstable

microsoft.public.sqlserver.dts microsoft.public.sqlserver.dts


Discuss DTS Datapump Column Order Unstable in the microsoft.public.sqlserver.dts forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
Jamie Carper
 
Posts: n/a

Default DTS Datapump Column Order Unstable - 07-18-2005 , 04:21 PM






I am coding in activescript in a transformation of a datapump.

When I use the wizard to assign source and destination properties I expect
the order of the properties to be based on the order of properties in the
wizard. However everytime I access the wizard to remove or add another
column, the order of the properties reversed on me. If I repeat the process
above sometimes the order reverts back to normal. I dont know what is causing
this OR how to stop it.

I cannot code against these columns in the transformation using the ordinal
property if the ordinal property keeps toggling bewteen reversing the order
and then reverting back to normal.

Is this a known bug in DTS? How can I ensure that the properties will remain
in the order I specify?

Reply With Quote
  #2  
Old   
Allan Mitchell
 
Posts: n/a

Default Re: DTS Datapump Column Order Unstable - 07-19-2005 , 05:27 AM






Can you not use Column Names?

I do not believe you should rely on ordinal number ever.

--



Allan Mitchell MCSE,MCDBA, (Microsoft SQL Server MVP)
www.SQLDTS.com - The site for all your DTS needs.
www.SQLIS.com - You thought DTS was good. here we show you the new stuff.
www.konesans.com - Consultancy from the people who know


"Jamie Carper" <JamieCarper (AT) discussions (DOT) microsoft.com> wrote

Quote:
I am coding in activescript in a transformation of a datapump.

When I use the wizard to assign source and destination properties I expect
the order of the properties to be based on the order of properties in the
wizard. However everytime I access the wizard to remove or add another
column, the order of the properties reversed on me. If I repeat the
process
above sometimes the order reverts back to normal. I dont know what is
causing
this OR how to stop it.

I cannot code against these columns in the transformation using the
ordinal
property if the ordinal property keeps toggling bewteen reversing the
order
and then reverting back to normal.

Is this a known bug in DTS? How can I ensure that the properties will
remain
in the order I specify?



Reply With Quote
  #3  
Old   
Jamie Carper
 
Posts: n/a

Default Re: DTS Datapump Column Order Unstable - 07-19-2005 , 09:00 AM



According to the SQL Online Help I have been reading. It is more effiecient
to reference the columns by index than by name. So I find it curious that the
index cannot be trusted. But all that set aside...

Normally I would use the Column name in most situations. However I am
reading 1000s of Excel files with inconsistent column structures. I
therefore have some code that reads the column headings of each column and
then attempts to reconcile these headings with the field names in my target
table. Essentially I am dynamically mapping the columns to the fields for
each worksheet I read (upto 60 in each file).

For this to work I need to reference the Destination fields in a specific
known order. The problem is that order keeps changing! And when I say
changing I mean the entire collection reverses at times and reverts at other
times. I cannot put my finger on what causes the problem. I know it is a
wizard issue and occurs anytime I reenter the wizard dialog
source/destination tabs.

At one time I tried to force the issue by removing and re-adding the fields
in the order I wanted. But that really screwed up the process because now
when the Source collection order is correct, the Destination order is
reversed and visa-versa.

"Allan Mitchell" wrote:

Quote:
Can you not use Column Names?

I do not believe you should rely on ordinal number ever.
Jamie



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



Powered by vBulletin Version 3.5.3
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.