New on Teradata. For a client I am trying to format some numbers. The wish is to paste the string 'EUR' to a value as follows.
We have tried different formats, but face some challenges. For instance, the format G9D99 works fine for the first two, but does not work with the larger numbers. And the formate G-Z(10)D9(2) works fine for the larger numbers, but removes the first zero with the smaller numbers.
Is there a format that can fullfill both our wishes?
Hope to hear something :)
THANK YOU CARLOS!!!!!
I understand the format mostly, only the part (9)9 not totally. Do you have an explanation for this?
I saw that the format 'G-999999999D(9)2' fills up the positions with zero's, while your solution fills it up with spaces. Why is that?
Anyway; many thanks!
-(9)=Minus sign (if applicable) for 9 positions
9=Last number before decimal separator mandatory.
9(2)= two decimal positions.
Got it! Thats why my 999999999 resulted in leading zero's, because you then say it is mandatory to put a number on that position.
Well, you made me and a client happy today, thanks and have a good day!