You are not logged in.
Announcement
Unanswered posts
|
Pages: 1
Hello:
I need convert some numbers, from a BD in format double, to a XML file. I need than the number has two decimals. How can I do, when the original number is 0? I only get the result 0.0, but I need 0.00
Another example of the same problem: when I pass the number 8.36 to SML, I need six decimals, and so I need 8.360000
Greetings Thanks
Jose
With java jobs, you can use the java class "DecimalFormat" in a tJavaRow :
DecimalFormat myFormat = new DecimalFormat("0.00");
rowX.myFormattedDate = myFormat.format(rowX.myNumericRow);Offline
Thank you for the answer, but...
I need put this code in the "expression Builder", in a component tMap. In this place, it don't work,it say "syntax error". I think than I could use a direct function to became the result. Some idea??
Greetings
Hello
in a component tMap. In this place, it don't work,it say "syntax error"
Write these code in a routine, then call the routine on tMap.
Best regards
shong
Offline
Thank you for the answer.
If I wat to use a conditional sentence, can I used some function in a tMap, or I must add this conditional sentence in a routine too?
I think, for example:
if field1 == Y
"ELECTRONIC"
else
POSTAL
Greetings
Pages: 1