dbTalk Databases Forums  

DTS Lookups

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


Discuss DTS Lookups in the microsoft.public.sqlserver.dts forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
Craig Sanborn
 
Posts: n/a

Default DTS Lookups - 07-17-2003 , 12:59 PM






I am new to DTS but I have quickly found that it is very
Powerful. I have started building my transform that
inserts records into a "holding" table. I need to check
to see if an ID exists in another table. If it does get
the values from 3 fields if not then use some constant
values. I started to write my own function but then found
Lookups thank goodness), and a very good site
www.sqldts.com. My question is what happens if the lookup
returns an empty recordset and how would I trap that? I
know I will get an array if a record is found but is an
error thrown with an empty rs on the execute method?

Craig

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

Default Re: DTS Lookups - 07-17-2003 , 03:04 PM






Does ISEMPTY() meet your needs ?

--

----------------------------
Allan Mitchell (Microsoft SQL Server MVP)
MCSE,MCDBA
www.SQLDTS.com
I support PASS - the definitive, global community
for SQL Server professionals - http://www.sqlpass.org



"Craig Sanborn" <csanborn (AT) asbuilts (DOT) com> wrote

Quote:
I am new to DTS but I have quickly found that it is very
Powerful. I have started building my transform that
inserts records into a "holding" table. I need to check
to see if an ID exists in another table. If it does get
the values from 3 fields if not then use some constant
values. I started to write my own function but then found
Lookups thank goodness), and a very good site
www.sqldts.com. My question is what happens if the lookup
returns an empty recordset and how would I trap that? I
know I will get an array if a record is found but is an
error thrown with an empty rs on the execute method?

Craig



Reply With Quote
  #3  
Old   
Craig Sanborn
 
Posts: n/a

Default Re: DTS Lookups - 07-17-2003 , 03:27 PM



It does. That's how I ended up writing it. It's just at
the time it seemed to simple :-)

Thanks for the reply and the good stuff on SQLDTS.com

Craig
Quote:
-----Original Message-----
Does ISEMPTY() meet your needs ?

--

----------------------------
Allan Mitchell (Microsoft SQL Server MVP)
MCSE,MCDBA
www.SQLDTS.com
I support PASS - the definitive, global community
for SQL Server professionals - http://www.sqlpass.org



"Craig Sanborn" <csanborn (AT) asbuilts (DOT) com> wrote in message
news:004401c34c8d$1d165b50$a601280a (AT) phx (DOT) gbl...
I am new to DTS but I have quickly found that it is very
Powerful. I have started building my transform that
inserts records into a "holding" table. I need to check
to see if an ID exists in another table. If it does get
the values from 3 fields if not then use some constant
values. I started to write my own function but then
found
Lookups thank goodness), and a very good site
www.sqldts.com. My question is what happens if the
lookup
returns an empty recordset and how would I trap that? I
know I will get an array if a record is found but is an
error thrown with an empty rs on the execute method?

Craig


.


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.