Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.databases.ms-sqlserver > #879
| Path | csiph.com!x330-a1.tempe.blueboxinc.net!usenet.pasdenom.info!weretis.net!feeder4.news.weretis.net!eternal-september.org!feeder.eternal-september.org!mx04.eternal-september.org!.POSTED!not-for-mail |
|---|---|
| From | Erland Sommarskog <esquel@sommarskog.se> |
| Newsgroups | comp.databases.ms-sqlserver |
| Subject | Re: is there a way to put a table into a parameter |
| Date | Wed, 21 Dec 2011 23:34:30 +0100 |
| Organization | Erland Sommarskog |
| Lines | 20 |
| Message-ID | <Xns9FC2EFD164A4FYazorman@127.0.0.1> (permalink) |
| References | <7aa6e91d-24ac-4416-8d12-36cfcf89f8bb@i6g2000vbe.googlegroups.com> <jctas0$h5n$1@dont-email.me> |
| Mime-Version | 1.0 |
| Content-Type | text/plain; charset=windows-1252 |
| Content-Transfer-Encoding | 8bit |
| Injection-Info | mx04.eternal-september.org; posting-host="nBFDv6s1VJQDuF1w6hpX2A"; logging-data="26813"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1+2i5FHzCI5BUE8PApaUUbC" |
| User-Agent | Xnews/2006.08.24 Mime-proxy/2.1.c.0 (Win32) |
| Cancel-Lock | sha1:nyVNk1YXHCFbhrCMdm/VPKPOSGo= |
| Xref | x330-a1.tempe.blueboxinc.net comp.databases.ms-sqlserver:879 |
Show key headers only | View raw
Bob Barrows (reb01501@NOyahooSPAM.com) writes:
> select * from pharm where fieldname in (select fieldname from
> interested_ndccodes)
OR
SELECT *
FROM pharm p
WHERE EXISTS (SELECT *
FROM interested_ndccodes ndc
WHERE parm.ndc LIKE ndc.ndc_coding)
--
Erland Sommarskog, SQL Server MVP, esquel@sommarskog.se
Links for SQL Server Books Online:
SQL 2008: http://msdn.microsoft.com/en-us/sqlserver/cc514207.aspx
SQL 2005: http://msdn.microsoft.com/en-us/sqlserver/bb895970.aspx
Back to comp.databases.ms-sqlserver | Previous | Next — Previous in thread | Find similar
is there a way to put a table into a parameter Apsteinberg <apsteinberg@hotmail.com> - 2011-12-21 10:47 -0800
Re: is there a way to put a table into a parameter "Bob Barrows" <reb01501@NOyahooSPAM.com> - 2011-12-21 14:08 -0500
Re: is there a way to put a table into a parameter Erland Sommarskog <esquel@sommarskog.se> - 2011-12-21 23:34 +0100
csiph-web