Converting money to varchar still gives me the values in my result set. HELP~~!

  • Why is the query below still giving me .0000 in my result?

    SELECT A.MerchantLocationID, ML.MerchLocName, ML.MerchLocContact, ML.MerchLocPhoneNumber, A.AccountNumber, A.CashPurse1 as CurrentBalance

    FROM Transactions T

    JOIN dbo.MerchantLocations ML on T.MerchantLocationID = ML.MerchantLocationID

    JOIN Accounts A ON T.AccountNumber=A.AccountNumber

    JOIN (SELECT AccountNumber, MAX(TransID) as LastTransID

    FROM Transactions

    GROUP BY AccountNumber) X ON X.LastTransID=T.TransID

    JOIN TransactionType Y ON T.TransType = Y.TransactionType

    WHERE CONVERT(varchar, A.CashPurse1) <> ('.0000')

  • Did you try

    WHERE A.CashPurse1 < > 0



    Lutz
    A pessimist is an optimist with experience.

    How to get fast answers to your question[/url]
    How to post performance related questions[/url]
    Links for Tally Table [/url] , Cross Tabs [/url] and Dynamic Cross Tabs [/url], Delimited Split Function[/url]

  • Lutz,

    I didn't think of that, but it worked!!! YOU ROCK!!!

    Thanks much!!!

    -David

Viewing 3 posts - 1 through 2 (of 2 total)

You must be logged in to reply to this topic. Login to reply