Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2005 Forums
 Transact-SQL (2005)
 Crazy question

Author  Topic 

yosiasz
Master Smack Fu Yak Hacker

1635 Posts

Posted - 2008-05-09 : 14:48:25
Hi,

Is this at all possible to do. I have been stuck for a couple of hours trying.

SELECT DISTINCT ItemTag,
ItemBinLocation
FROM VInventory
WHERE
(
SELECT
CASE x
WHEN 'x'
THEN (LEFT(ItemBinLocation, 1) = 'abc'
WHEN 'y'
THEN LEFT(ItemBinLocation, 3) = 'efg'
END
FROM dbo.OtherTable
)

???
I need some Yak Milk please!

Lamprey
Master Smack Fu Yak Hacker

4614 Posts

Posted - 2008-05-09 : 14:56:27
Can you describe in words what youa re trying to do? Also, how does VInventory relate to OtherTable (is there a common column between them)?
Go to Top of Page
   

- Advertisement -