BorlandTalk.com Forum Index BorlandTalk.com
Borland discussion newsgroups
 
Archives   FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Filter problem

 
Post new topic   Reply to topic    BorlandTalk.com Forum Index -> Delphi Databases (Desktop)
View previous topic :: View next topic  
Author Message
Bob Berry
Guest





PostPosted: Sun Jan 30, 2005 3:37 pm    Post subject: Filter problem Reply with quote



D7, Access 2000, ADO...

Filtering a table does not always accept the same syntax as a Where clause
in a query. I need to use the following filter, only negated:

Filter := 'CODICIL LIKE ' + QuotedStr('!%');

I tried NOT LIKE, I tried putting the NOT in front of whole expression in
parentheses, and I tried NOT (LIKE... with the appropriate closing
parenthesis, but in each case I get:

Arguments are of the wrong type, are out of acceptable range, or are in
conflict with one another.

How do I do this?


Back to top
Jackson Gomes - Tools&Com
Guest





PostPosted: Thu Mar 03, 2005 11:48 am    Post subject: Re: Filter problem Reply with quote




Quote:
Filter := 'CODICIL LIKE ' + QuotedStr('!%');

The LIKE keyword will not work in Filter expressions (for TDataset). For
partial comparisons, use *

Filter := 'Lastname = ''Co*''';

Regards


--
Jackson Gomes
Tools&Comps - Security Components for Borland Developers.
Web Site: http://www.toolsandcomps.com
Our Forum: http://groups.yahoo.com/group/toolsandcomps
e-mail: [email]jackson (AT) toolsandcomps (DOT) com[/email]
Phone: 55 27 99602760 / 55 27 33891138



Back to top
Display posts from previous:   
Post new topic   Reply to topic    BorlandTalk.com Forum Index -> Delphi Databases (Desktop) All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2006 phpBB Group
SEO toolkit © 2004-2006 webmedic.