Posted by Plamen Ratchev on 06/05/07 12:28
You can use CASE, like this: SELECT Cust, CASE WHEN Type = 1 THEN Amount ELSE 0.0 END AS Type1, CASE WHEN Type = 2 THEN Amount ELSE 0.0 END AS Type2 FROM Foobar HTH, Plamen Ratchev http://www.SQLStudio.com
[Reply to this message]
Copyright © 2005-2006 Powered by Custom PHP Programming