Charles, Use the following syntax.
CREATE TABLE tablename (colname TEXT (18) DEFAULT USER) You can then control changes to this value by TRIGGER or a FORM. Possible DEFAULT values are: USER NULL (value) Default USER: Specifies the default value to be the user identifier. Default NULL: Specifies the default value to be null. Default (value): Specifies the default to be the indicated value. -- Charles Parks <[EMAIL PROTECTED]> wrote: > When I load the table with previously unloaded data the > computed column becomes what the value currently is instead of > what the value was before the unload. Is there a way around > this? > > I would prefer the column's value be the current user upon > creation of the row but have custom say when the value should > be changed. As well as being able to unload and reload a > table and keep the originial value instead of it being changed > to the user that is reloading the table. > > -----Original Message----- > From: [email protected] [mailto:[EMAIL PROTECTED] On Behalf > Of John Minyo II > Posted At: Thursday, March 20, 2008 1:11 PM > Posted To: RB7-L > Conversation: [RBASE-L] - Re: Setting default for a column to > the current user > Subject: [RBASE-L] - Re: Setting default for a column to the > current user > > > At 11:51 AM 3/20/2008, you wrote: > >What is the correct syntax to set a column's default to the > current user? > > > >When I try something like this > >CREATE TABLE `Test` (`Editor` TEXT (3) DEFAULT > '(CVAL('user'))') > > > >I get this > >-ERROR- Default length must be no longer than 60 chars (2791) > > Charlie, > > Use a computed column rather than using a computed value as a > column default. > > And, "Editor" is a RESERVED WORD. > > Try something like: > > CREATE TABLE `Test1` (`TblEdtr`= (CVAL('USER')) TEXT (50), > TextCol TEXT (6)) > > Do you want the R:BASE user or the network user? For the > network user, use (CVAL('NETUSER')). > > John > > > Jim Bentley American Celiac Society [EMAIL PROTECTED] tel: 1-504-737-3293 ____________________________________________________________________________________ Looking for last minute shopping deals? Find them fast with Yahoo! Search. http://tools.search.yahoo.com/newsearch/category.php?category=shopping

