[U2] Manage $ values
Dale: Be careful with this if running UniData. Here are some UDT.OPTIONS documentation: UDT.OPTIONS 56 - U_CONV_BADRETURN Normally, if an OCONV or ICONV conversion fails due to invalid data or an invalid conversion code, UniData returns the input string. In BASICTYPE P, if you turn on UDT.OPTIONS 56, UniData returns an empty string. ON If this option is on, UniData returns an empty string when an OCONV or ICONV conversion fails. Note: For compatibility with most Pick® systems, turn this option on. OFF If this option is off, UniData returns the original string when an OCONV or ICONV conversion fails. I've been bitten by this in the past. :-( Bill - Original Message - *From:* dalekel...@dalewkelleyinc.com *To:* U2 Users List u2-users@listserver.u2ug.org *Date:* 5/7/2013 3:06 PM *Subject:* Re: [U2] Illegal use of the file, select, cursor, BCI, Socket, HTTP, XML, SCTX , MQS, SOAP or database variable. if var is XXX.XX ICONV(var,MD2) then OCONV(var,MD0) Dale On 05/07/2013 12:04 PM, Sathya wrote: Hi,. Thanks everyone for the suggestions and I have sorted out the issue. Now I want to write some dollar values to a file. But the format in which it is in the file is XXX.XX, but I need to write it as X. Without the decimals the simple numbers. Can some help me in doing so. Thanks Regards, Sathya V. ___ U2-Users mailing list U2-Users@listserver.u2ug.org http://listserver.u2ug.org/mailman/listinfo/u2-users
Re: [U2] Manage $ values
On 07/05/13 23:23, Bill Haskett wrote: Dale: Be careful with this if running UniData. Here are some UDT.OPTIONS documentation: UDT.OPTIONS 56 - U_CONV_BADRETURN Normally, if an OCONV or ICONV conversion fails due to invalid data or an invalid conversion code, UniData returns the input string. This is what INFORMATION did. In BASICTYPE P, if you turn on UDT.OPTIONS 56, UniData returns an empty string. ON If this option is on, UniData returns an empty string when an OCONV or ICONV conversion fails. Note: For compatibility with most Pick® systems, turn this option on. This is how - I believe - all systems based on true Pick code behaved. OFF If this option is off, UniData returns the original string when an OCONV or ICONV conversion fails. I've been bitten by this in the past. :-( The option was introduced in UV and UD because the two main codebases (PI and Pick) had these different behaviours. I've got bitten by a similar-but-different behaviour. Dunno how, but I fed a number like 9012 into a date ICONV, and wondered why I got a truly weird result. I think I was trying to convert an internal date for display and got my ICONV and OCONV mixed up ... Bill Cheers, Wol ___ U2-Users mailing list U2-Users@listserver.u2ug.org http://listserver.u2ug.org/mailman/listinfo/u2-users
Re: [U2] Manage $ values
Bill, I've had a little UniData experience, but nowdays I'm all UniVerse; I'm not sure what happens but hopefully I'd catch it before it went to homeland security. Thanks for the tip. Dale On 05/07/2013 05:23 PM, Bill Haskett wrote: Dale: Be careful with this if running UniData. Here are some UDT.OPTIONS documentation: UDT.OPTIONS 56 - U_CONV_BADRETURN Normally, if an OCONV or ICONV conversion fails due to invalid data or an invalid conversion code, UniData returns the input string. In BASICTYPE P, if you turn on UDT.OPTIONS 56, UniData returns an empty string. ON If this option is on, UniData returns an empty string when an OCONV or ICONV conversion fails. Note: For compatibility with most Pick® systems, turn this option on. OFF If this option is off, UniData returns the original string when an OCONV or ICONV conversion fails. I've been bitten by this in the past. :-( Bill - Original Message - *From:* dalekel...@dalewkelleyinc.com *To:* U2 Users List u2-users@listserver.u2ug.org *Date:* 5/7/2013 3:06 PM *Subject:* Re: [U2] Illegal use of the file, select, cursor, BCI, Socket, HTTP, XML, SCTX , MQS, SOAP or database variable. if var is XXX.XX ICONV(var,MD2) then OCONV(var,MD0) Dale On 05/07/2013 12:04 PM, Sathya wrote: Hi,. Thanks everyone for the suggestions and I have sorted out the issue. Now I want to write some dollar values to a file. But the format in which it is in the file is XXX.XX, but I need to write it as X. Without the decimals the simple numbers. Can some help me in doing so. Thanks Regards, Sathya V. ___ U2-Users mailing list U2-Users@listserver.u2ug.org http://listserver.u2ug.org/mailman/listinfo/u2-users ___ U2-Users mailing list U2-Users@listserver.u2ug.org http://listserver.u2ug.org/mailman/listinfo/u2-users