Ray:

You need to use a dot when you are using variables, when you are using column names a dot is not needed.

 

>>1: TEXT     : D  : vNames1 = T_2.COMBNAMES & T_2.FamName
>>2: TEXT     : D  : vZipcodes = (IFNULL(Zipcodex,Zipcode,(Zipcode + '-' + Zipcodex)))
>>3: TEXT     : D  : vCityStateZip = City + ', ' + State + '  ' + vZipcodes


On line 1 you are using 2 column names (T_2.COMBNAMES and T_2.FamName) and thus you do not need a dot, same thing for line 2 (assuming Zipcode and Zipcodex are columns names.)

On line 3 you are using the variable vZipcodes and 2 columns (City and State) and hence you need to use a dot in front of the variable, the correct _expression_ should be:

 

TEXT     : D  : vCityStateZip = (City + ', ' + State & .vZipcodes)

 

Note the dot in front of the variable vZipcodes…makes sense? Also “+” adds 2 text items (variables or column names) together with no space in between but when you use “&” instead of “+” it places a blank space in between; thus “&” replaces “+ ‘  ‘ +” and simplifies the _expression_. 

 

Javier,

Javier Valencia, PE

President

Valencia Technology Group, L.L.C.

14315 S. Twilight Ln, Suite #14

Olathe, Kansas 66062-4578

Office (913)829-0888

Fax (913)649-2904

Cell (913)915-3137

================================================

Attention:

The information contained in this message and or attachments is intended

only for the person or entity to which it is addressed and may contain

confidential and/or privileged material.  Any review, retransmission,

dissemination or other use of, or taking of any action in reliance upon,

this information by persons or entities other than the intended recipient

is prohibited. If you received this in error, please contact the sender and

delete the material from all system and destroy all copies.

======================================================

 

-----Original Message-----
From: [email protected] [mailto:[EMAIL PROTECTED]On Behalf Of [EMAIL PROTECTED]
Sent: Friday, May 06, 2005 1:51 PM
To: RBASE-L Mailing List
Subject: [RBASE-L] - Re: postal service zipcodes

 

I posted this question and in less than 30 minutes I had no less than 5 good answers, some with explanations, and two more the next morning. Thanks to each of you. I forgot to say I have RBase 6.5++ and Window XP with SP2.

 

This is how the variables for one label look now ( the label is based on a view):

1: TEXT     : D  : vNames1 = T_2.COMBNAMES & T_2.FamName
2: TEXT     : D  : vZipcodes = (IFNULL(Zipcodex,Zipcode,(Zipcode + '-' + Zipcodex)))
3: TEXT     : D  : vCityStateZip = City + ', ' + State + '  ' + vZipcodes
 

This seems to work exactly as I wanted, hence I don't understand Javier's reminder to be sure to use a dot (.) in front of the variables? Is this likely to cause me trouble later on?

Reply via email to