Re: Velocity parsing value as Exponential

Anonymous
Not applicable

Velocity parsing value as Exponential

Hi,

We have an issue where we have a string value - 41E20.  It is a string in Salesforce and a string in Marketo but when read via Velocity it is incorrectrly being parsed as a 4.1E20 or 4,000,000,000,000,000,000 etc if I toString() it.  I can't for the life of me fix the way it is outputting to its "String" format!  it also seems to have stumped Marketo Support/Dev so any ideas would be greatly appreciated!

Thanks

N

Tags (1)
3 REPLIES 3
Kenny_Elkington
Marketo Employee

Re: Velocity parsing value as Exponential

Hi Neil,

I can't seem to reproduce this.  Do you think you should share your script snippet?

SanfordWhiteman
Level 10 - Community Moderator

Re: Velocity parsing value as Exponential

I was about to say the same thing!  I created a script with both an SFDC-synced string and a Marketo-builtin string set to "41E20" and it didn't turn either into a float.

Neil_Robertson6
Level 5

Re: Velocity parsing value as Exponential

Marketo confirmed the issue as a bug so I am interested to see how you got your values working!!!?!!?  NOTE: our value which is synchronised is a forumula field (Text). It is also in a List Loop to be used in a TriggerObject process.

The only way I could get this to output was to add an apostrophe to the front of the value and then remove on output.