Welcome to dbForumz.com!
FAQFAQ    SearchSearch      ProfileProfile    Private MessagesPrivate Messages   Log inLog in

Subquery in DTS No Longer Works After Years

 
   Database Forums (Home) -> General Discussions RSS
Next:  table copy  
Author Message
Docster2005

External


Since: Oct 12, 2006
Posts: 1



(Msg. 1) Posted: Thu Oct 12, 2006 5:50 am
Post subject: Subquery in DTS No Longer Works After Years
Archived from groups: comp>databases>ms-sqlserver (more info?)

Hi folks,

A DTS package we have run for years now no longer works. The specific
part that is not working is a subquery in the SOURCE object of a
transformation. The source is based on a Microsoft Data Link to a
Sybase database (DSN changed a couple months ago but the connection
string was updated successfully for the new 12.51 version of ASE) and
the destination is a link to a local SQL Server 2000 database.

The transformation has always worked and when I remove the subquery
everything works OK. The problem is that I need the subquery!

Does anyone have a clue what is going on?

Here is the full query.

select TableKey = RVSN_TYPE_ID,
TableCode = RVSN_TYPE,
RevisionDate = RVSN_DATE,
RevisionReasonCode = RSN_CODE,
RevisionGroup = RVSN_GRP_ID,
RevisedField = (select L.FieldID
from tempdb.guest.lkpRevisedField L
where L.TableID = R.RVSN_TYPE
and L.FieldName = R.CHNG_FLD),
RevisedValue = OLD_FLD_VAL,
RevisionTimestamp = RVSN_TIMESTAMP
from RVSN R,
tempdb.guest.MaxTimeStamp TS
where R.RVSN_TIMESTAMP > TS.Rtimestamp
and R.RVSN_TIMESTAMP is NOT NULL

John H.

 >> Stay informed about: Subquery in DTS No Longer Works After Years 
Back to top
Login to vote
Stu

External


Since: May 31, 2005
Posts: 44



(Msg. 2) Posted: Fri Oct 13, 2006 11:07 am
Post subject: Re: Subquery in DTS No Longer Works After Years [Login to view extended thread Info.]
Archived from groups: per prev. post (more info?)

When you say "it doesn't work", what do you mean? Do you get no data,
or does it throw a syntax error? Does it just stall and hang?


wrote:
> Hi folks,
>
> A DTS package we have run for years now no longer works. The specific
> part that is not working is a subquery in the SOURCE object of a
> transformation. The source is based on a Microsoft Data Link to a
> Sybase database (DSN changed a couple months ago but the connection
> string was updated successfully for the new 12.51 version of ASE) and
> the destination is a link to a local SQL Server 2000 database.
>
> The transformation has always worked and when I remove the subquery
> everything works OK. The problem is that I need the subquery!
>
> Does anyone have a clue what is going on?
>
> Here is the full query.
>
> select TableKey = RVSN_TYPE_ID,
> TableCode = RVSN_TYPE,
> RevisionDate = RVSN_DATE,
> RevisionReasonCode = RSN_CODE,
> RevisionGroup = RVSN_GRP_ID,
> RevisedField = (select L.FieldID
> from tempdb.guest.lkpRevisedField L
> where L.TableID = R.RVSN_TYPE
> and L.FieldName = R.CHNG_FLD),
> RevisedValue = OLD_FLD_VAL,
> RevisionTimestamp = RVSN_TIMESTAMP
> from RVSN R,
> tempdb.guest.MaxTimeStamp TS
> where R.RVSN_TIMESTAMP > TS.Rtimestamp
> and R.RVSN_TIMESTAMP is NOT NULL
>
> John H.

 >> Stay informed about: Subquery in DTS No Longer Works After Years 
Back to top
Login to vote
Display posts from previous:   
Related Topics:
Multicolumn correlated subquery? - Hi, I have a history table with about 400 million rows, with a unique composite nonclustered index on two columns (object id and time period) which is used for most of the queries into the table, and an identity column for the clustered primary key. ..

How top actually works - I'm coming from Oracle world and trying to find something similar to rownum in Oracle. I know there exists TOP which normally if used in the same select woth order by firstly sorts data and then only gets top n. So the question is what actually happens..

Collation error - I can ussually resolve this issue but I'm looking for help this time. I'm running the following select statement on one server and pulling the information from a second server. SELECT CustomerName from [SQL-STL].FSDBPE.dbo.FS_Customer Results: Server:....

Concurrency in Transaction - hi gurus the scenario Frontend - MS Access (not yet decided whether MDB or ADP) Backend - MS SQL Server it is a conversion from MS Access backend to MS SQL Server Backend. Planning to create stored procedures for all the Inserts, Updates, Deletes and....

Configuring SQL MAIL - Hi All, My question is that can I configure SQL MAIL, if my EXCHANGE SERVER is on different domain and my SQL is running on different domain.Can anyone guide me for this because I googled a lot without any result. I am using SQL SERVER 2000..
   Database Forums (Home) -> General Discussions All times are: Pacific Time (US & Canada) (change)
Page 1 of 1

 
You can post new topics in this forum
You can reply to topics in this forum
You can edit your posts in this forum
You can delete your posts in this forum
You can vote in polls in this forum



[ Contact us | Terms of Service/Privacy Policy ]