dbTalk Databases Forums  

DTS Data Pump VBScript runtime error Type mismatch

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


Discuss DTS Data Pump VBScript runtime error Type mismatch in the microsoft.public.sqlserver.dts forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
-=JLK=-
 
Posts: n/a

Default DTS Data Pump VBScript runtime error Type mismatch - 12-01-2004 , 07:46 AM






I have a strange problem. What was working fine on all machines, now does
not work at all on one of three machines. As far as I can tell all three
machines have exactly the same configuration and identical hardware. We are
running:

Microsoft SQL Server 2000 - 8.00.818 (Intel X86) May 31 2003 16:08:15
Copyright (c) 1988-2003 Microsoft Corporation Developer Edition on Windows
NT 5.1 (Build 2600: Service Pack 2)

(It is really service pack 3, but the select @@version produces the above on
all three machines).

The machine with the problem can not use "IF" statements that have variables
in them in ActiveX scripts. I.e.
IF 1 = 1 THEN --Works Fine

Dim Var1, Var2
Var1 = 1
Var 2 = 1
IF Var1 = Var2 THEN -- Throws the Type MisMatch error.

What's really strange is it doesn't do it in all DTS packages however
recreating a package with the problem just duplicates the problem, but only
on one of the three machines.

Has anyone seen or heard of anything like this? I have uninstalled and
reinstalled SQL Server, changed the packages to talk to a different server
while running on client but always with the same result.

TIA,

James Knowlton



Reply With Quote
  #2  
Old   
-=JLK=-
 
Posts: n/a

Default Re: DTS Data Pump VBScript runtime error Type mismatch - 12-01-2004 , 10:26 AM






It appears that it has nothing to do with the machine itself. Problem can
now be duplicated on all machines. So I guess it is something internal with
DTS.


"-=JLK=-" <jlkguard-newsgroups (AT) yahoo (DOT) com> wrote

Quote:
I have a strange problem. What was working fine on all machines, now does
not work at all on one of three machines. As far as I can tell all three
machines have exactly the same configuration and identical hardware. We
are running:

Microsoft SQL Server 2000 - 8.00.818 (Intel X86) May 31 2003 16:08:15
Copyright (c) 1988-2003 Microsoft Corporation Developer Edition on
Windows NT 5.1 (Build 2600: Service Pack 2)

(It is really service pack 3, but the select @@version produces the above
on all three machines).

The machine with the problem can not use "IF" statements that have
variables in them in ActiveX scripts. I.e.
IF 1 = 1 THEN --Works Fine

Dim Var1, Var2
Var1 = 1
Var 2 = 1
IF Var1 = Var2 THEN -- Throws the Type MisMatch error.

What's really strange is it doesn't do it in all DTS packages however
recreating a package with the problem just duplicates the problem, but
only on one of the three machines.

Has anyone seen or heard of anything like this? I have uninstalled and
reinstalled SQL Server, changed the packages to talk to a different server
while running on client but always with the same result.

TIA,

James Knowlton




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

Default Re: DTS Data Pump VBScript runtime error Type mismatch - 12-01-2004 , 01:13 PM



You do know you have a space between var and 2 right?



--
--

Allan Mitchell MCSE,MCDBA, (Microsoft SQL Server MVP)
www.SQLDTS.com - The site for all your DTS needs.
www.konesans.com - Consultancy from the people who know


"-=JLK=-" <jlkguard-newsgroups (AT) yahoo (DOT) com> wrote

Quote:
I have a strange problem. What was working fine on all machines, now does
not work at all on one of three machines. As far as I can tell all three
machines have exactly the same configuration and identical hardware. We
are running:

Microsoft SQL Server 2000 - 8.00.818 (Intel X86) May 31 2003 16:08:15
Copyright (c) 1988-2003 Microsoft Corporation Developer Edition on
Windows NT 5.1 (Build 2600: Service Pack 2)

(It is really service pack 3, but the select @@version produces the above
on all three machines).

The machine with the problem can not use "IF" statements that have
variables in them in ActiveX scripts. I.e.
IF 1 = 1 THEN --Works Fine

Dim Var1, Var2
Var1 = 1
Var 2 = 1
IF Var1 = Var2 THEN -- Throws the Type MisMatch error.

What's really strange is it doesn't do it in all DTS packages however
recreating a package with the problem just duplicates the problem, but
only on one of the three machines.

Has anyone seen or heard of anything like this? I have uninstalled and
reinstalled SQL Server, changed the packages to talk to a different server
while running on client but always with the same result.

TIA,

James Knowlton




Reply With Quote
  #4  
Old   
-=JLK=-
 
Posts: n/a

Default Re: DTS Data Pump VBScript runtime error Type mismatch - 12-01-2004 , 01:25 PM



Yea, just a type-o as I was creating the message. Thanks though.


"Allan Mitchell" <allan (AT) no-spam (DOT) sqldts.com> wrote

Quote:
You do know you have a space between var and 2 right?



--
--

Allan Mitchell MCSE,MCDBA, (Microsoft SQL Server MVP)
www.SQLDTS.com - The site for all your DTS needs.
www.konesans.com - Consultancy from the people who know



Reply With Quote
  #5  
Old   
-=JLK=-
 
Posts: n/a

Default Re: DTS Data Pump VBScript runtime error Type mismatch - 12-02-2004 , 08:10 AM



While I didn't solve the problem I did come up with a work around. I
replaced the SQL Source Query in the Data Driven Query Object from:

select pk,
coalesce(pk_CustomerOrganizationDim,0) as pk_CustomerOrganizationDim,
1 as fk_CustomerIndividualDim,
coalesce(pk_eventdim,0) as pk_eventdim,
coalesce(pk_datedim,0) as pk_datedim
from xntisuser x left outer join ebiework..CustomerOrganizationDim c on
(c.customercode = x.c01_depositaccount and c.CustomerCodeSource = 'NTIS')
left outer join ebiework..eventdim e on (e.eventsource =
'NTIS' and e.eventname = (Case processaction when 'A' then 'Created' when
'C' then 'Updated' when 'D' then 'Deleted' end))
left outer join ebiework..datedim d on (d.Dateyyyymmdd =
convert (varchar (50), getdate(), 112))
where x.processstatus = 'P2'
and x.batchnumber = ?
and x.processaction <> 'I'

To:

select *
from xntisuser
where processstatus = 'P2'
and batchnumber = ?
and processaction <> 'I'

Each of the Primary Keys needed for the record being created are now looked
up using "Lookup" objects rather than doing it all at once in a single SQL
statement. I don't know if this will help anyone else but at least now the
Active X vb scripts work as expected. Maybe DTS gets confused with the
weird SQL statement, though that statement works fine in Query Analyzer.

Thanks,

James.

"-=JLK=-" <jlkguard-newsgroups (AT) yahoo (DOT) com> wrote

Quote:
I have a strange problem. What was working fine on all machines, now does
not work at all on one of three machines. As far as I can tell all three
machines have exactly the same configuration and identical hardware. We
are running:

Microsoft SQL Server 2000 - 8.00.818 (Intel X86) May 31 2003 16:08:15
Copyright (c) 1988-2003 Microsoft Corporation Developer Edition on
Windows NT 5.1 (Build 2600: Service Pack 2)

(It is really service pack 3, but the select @@version produces the above
on all three machines).

The machine with the problem can not use "IF" statements that have
variables in them in ActiveX scripts. I.e.
IF 1 = 1 THEN --Works Fine

Dim Var1, Var2
Var1 = 1
Var 2 = 1
IF Var1 = Var2 THEN -- Throws the Type MisMatch error.

What's really strange is it doesn't do it in all DTS packages however
recreating a package with the problem just duplicates the problem, but
only on one of the three machines.

Has anyone seen or heard of anything like this? I have uninstalled and
reinstalled SQL Server, changed the packages to talk to a different server
while running on client but always with the same result.

TIA,

James Knowlton




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.