String Containing all Numeric Values Misbehaving [large number as string literal overflows to negative integer]



I have a string that I need to insert into a URL. The string is currently, but not always, all numbers. webCoRE keeps converting the string into something else.

Here is an example piston:


And here is what happens when I run the piston (comparing exampleID to newID).


I can’t even enter the value in an expression without the same thing happening, i.e.

{string} + “71723887741830301”

I’m assuming this is an extension of this issue that appears unresolved except for a possible workaround for that particular circumstance.


No idea why it tries to cast regardless of how you’re using the string, but try getting the number with an expression that avoids the all-numeric value by adding a letter and using a function to remove the letter, like this:




You’re welcome? Or does that mean the workaround that I found did not work for you?


Sorry, was on my phone at the time and the post got away from me. I apparently deleted the rest of my text when I added the emoticon. Fading eyesight and tiny keyboards can be an unfortunate combination. :smirk:

Of course I appreciate the help, although I had already found a similar workaround. I’m just a little frustrated the growing number of workarounds in my pistons. But since I lack the skills to help with the fixes, I’m fully aware I have no basis to complain. :smile::man_shrugging:


Same here, particularly with expressions there are a lot of little gotchas… Unfortunately it would be too risky to make any changes in the complex expression handling and casting code when there is some sort of workaround. Please leave this bug report open since the workaround is not a permanent substitute for a proper fix.


What’s interesting here is the problem does not seem occur if you use a global variable.