Welcome To The Home Of The Visual FoxPro Experts  
home. signup. forum. archives. search. google. articles. downloads. faq. members. weblogs. file info. rss.
 From: Lucy Alice Pilanga
  Where is Lucy Alice Pilanga?
 Metro Manila
 Philippines
 Lucy Alice Pilanga
 To: ed fabonan
  
 
 
 ed fabonan
 Tags
Subject: RE: delayng withs spaces
Thread ID: 33741 Message ID: 33757 # Views: 2 # Ratings: 0
Version: Visual FoxPro 8 Category: Databases, Tables and SQL Server
Date: Wednesday, December 03, 2003 4:47:53 AM         
   


> > > Hi,
> > > I've a products table who has a id field. I want this field to contain values such as 'ABC1234', but the length of the last four character may change, for example, i could have ab id as 'ABC21'
> > > To do this I'd put a character(7) field the format mask !!!NNNN and this works, but i've a problem when the user has to input a shorter value (such as the second example), because he has also to type the blank spaces, otherwise he can't locate the record....
> > > I tried with the T letter in the format property of the field, but the datatype is "character", not "varchar" like in other databases.... right?
still lead you the the required record.

or you could use alltrim() when locating for the record.

locate for alltrim(field)==altrim(var_id)

-Lucy Alice

ENTIRE THREAD

delayng withs spaces Posted by matiass emanuel @ 12/2/2003 6:02:35 PM
RE: delayng withs spaces Posted by Yuri Rubinov @ 12/2/2003 7:39:15 PM
RE: delayng withs spaces Posted by ed fabonan @ 12/3/2003 1:12:42 AM
RE: delayng withs spaces Posted by lucy alice pilanga @ 12/3/2003 4:47:53 AM
RE: delayng withs spaces Posted by lucy alice pilanga @ 12/3/2003 5:06:07 AM
RE: delayng withs spaces Posted by Pete Sass @ 12/4/2003 8:00:44 PM