• Switch Function (A2K SP1)

    Author
    Topic
    #371787

    I have a db with several queries but can anyone tell me why a calculated field in one of my queries will format to currency when it’s an “Iif (…) statement but won’t format at all when I change it to Switch(…)?
    It’s a rather long ‘Iif ‘ and I think I read somewhere that Switch is more efficient.
    Peter

    Viewing 1 reply thread
    Author
    Replies
    • #592113

      I don’t know for certain, but I’d maybe because Switch() returns a variant. You might try wrapping the Switch function within CCur function.

    • #592124

      If you want a definitive answer, you’ll have to post your Switch() statement.

      • #592240

        Charlotte
        Thanks for your response. CCur() worked ( see Mark L’s rsponse)
        Peter

    Viewing 1 reply thread
    Reply To: Switch Function (A2K SP1)

    You can use BBCodes to format your content.
    Your account can't use all available BBCodes, they will be stripped before saving.

    Your information: