Page 1 of 1

CURRENCY function

PostPosted: Sun Feb 10, 2019 9:54 pm
by latimeria
Dear wise people of the internet,
please help! I'm trying to use DB2 CURRENCY function somehow and I have no idea where to basically put this whole currency thing in my SQL select. Let's say it's a primitive 'select * from abc.def' and I need the output displayed with nice commas (123,45.00) and euro sign. And what to put btw cause first the manual says CURRENCY but then in examples it says VALUES, none of them works for me (I get -104 error for illegal symbols all the time in all the variations I try), and I haven't found a single example of the whole line anywhere in the internet for that. Please help! Thank you in advance.

Re: CURRENCY function

PostPosted: Mon Feb 11, 2019 11:03 pm
by latimeria
Ok, for possible future generations of poor people like me: it's SELECT DSN8.CURRENCY( 'VALUE','CURRENCY','INDICATOR' ) FROM TABLE;

Re: CURRENCY function

PostPosted: Tue Feb 12, 2019 2:44 pm
by NicC
Thank you for posting the solution (and well done for persisting!).

Re: CURRENCY function

PostPosted: Tue Feb 12, 2019 2:48 pm
by latimeria
Thank you :)