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.
Author |
Topic |
Yonkouturko
Yak Posting Veteran
59 Posts |
Posted - 2012-12-06 : 09:02:58
|
is it possible for 2 columns in database to be compared directly??need your comments on these matterplease be good to me im just a newbie thanks in advance!SELECT ProductID, Barcode, Category, ProductName, Unit, Quantity, AmountPerUnit, UnitCeiling, UnitFlooringFROM Table_ProductWHERE (ProductName LIKE '%' + @SEARCH + '%') AND (Quantity <= UnitFlooring) |
|
sunitabeck
Master Smack Fu Yak Hacker
5155 Posts |
Posted - 2012-12-06 : 09:21:13
|
If you are referring to the AND (Quantity <= UnitFlooring), assuming that they are compatible data types in the same table, you CAN do that. |
|
|
Yonkouturko
Yak Posting Veteran
59 Posts |
Posted - 2012-12-06 : 09:23:55
|
@sunitabeckohmygashmy post is not clear though... yes im referring to that line of code... tnx for the reply ..!!! |
|
|
|
|
|