Concatinating numbers

keatk at comcast.net keatk at comcast.net
Tue May 25 15:28:47 CDT 2004


I have a table where the primary key nned combination of several fields VobjectPointer fields and another integer (VByte) value...

I want to create a virtual field via a field method that is composed of all those values and set it to kV_Unique...

What is the best way?

The obvious way is to convert all of them to stings and concatenate the strings... but looking at the VAlentina SQL reference I don't see an SQL function that converts numbers to strings equivalent to the RB. Str function.. Am I just missing it? If so what is it?


Is there a better way to do this?


Also in V4RB  if one uses a baseobject method is there any error mesages if and AddRecord failes because a field is not unique? BaseObject.GetRecID does not *ALWAYS*  return 0 in my tests when one tries to add a duplicate.

- Karen


More information about the Valentina mailing list