You must have an older version. All of the text manipulation functions work in the current version.

----- Original Message ----- From: <[email protected]>
To: "RBASE-L Mailing List" <[email protected]>
Sent: Thursday, April 14, 2011 1:55 PM
Subject: [RBASE-L] - Re: VarChar conversion




Thanks Mike,

However I get :

-ERROR- SLEN does not allow VARCHAR arguments. (2156)
-ERROR- Expression cannot be evaluated. (2179)



-Bob





----- Original Message ----- From: "Mike Byerley" <[email protected]>
To: "RBASE-L Mailing List" <[email protected]>
Sent: Thursday, April 14, 2011 12:18:19 PM
Subject: [RBASE-L] - Re: VarChar conversion

Here's how.

set var x varchar = ['Test.dat']
set var vtext text = (sget(.x(Slen(.x)),1))
set var vFloat = (float(.vtext))

sho var vFloat






----- Original Message ----- From: <[email protected]>
To: "RBASE-L Mailing List" <[email protected]>
Sent: Thursday, April 14, 2011 9:44 AM
Subject: [RBASE-L] - VarChar conversion




I load a value into a variable from a text file



set var x varchar = null

set var x = ['Test.dat']



sho var x

17.62



I now need to work with this value. However, I cannot find any conversion
functions that seem to

work with varchar datatype.


FLOAT states that it does not work with varchar



CTXT gives the following



set var Y text = null

set var Y = (CTXT(.x))



sho var Y

*



How can I convert the varchar variable type to something I can work with?



Thanks,



-Bob








----- Original Message ----- From: "Mike Byerley" <[email protected]>
To: "RBASE-L Mailing List" <[email protected]>
Sent: Thursday, April 14, 2011 12:18:19 PM
Subject: [RBASE-L] - Re: VarChar conversion

Here's how.

set var x varchar = ['Test.dat']
set var vtext text = (sget(.x(Slen(.x)),1))
set var vFloat = (float(.vtext))

sho var vFloat






----- Original Message ----- From: <[email protected]>
To: "RBASE-L Mailing List" <[email protected]>
Sent: Thursday, April 14, 2011 9:44 AM
Subject: [RBASE-L] - VarChar conversion




I load a value into a variable from a text file



set var x varchar = null

set var x = ['Test.dat']



sho var x

17.62



I now need to work with this value. However, I cannot find any conversion
functions that seem to

work with varchar datatype.


FLOAT states that it does not work with varchar



CTXT gives the following



set var Y text = null

set var Y = (CTXT(.x))



sho var Y

*



How can I convert the varchar variable type to something I can work with?



Thanks,



-Bob


Reply via email to