Ureader.com  
Microsoft software help and Community
   home   |   control panel login   |   archive   |  
 
Access
3rdpartyusrgrp
access
activexcontrol
adp.sqlserver
commandbarsui
conversion
dataaccess.pages
developers.toolkitode
devtoolkits
externaldata
forms
formscoding
gettingstarted
internet
interopoledde
macros
modulescoding
modulesdaovba
modulesdaovba.ado
multiuser
odbcclientsvr
queries
replication
reports
security
setupconfig
tablesdbdesign
  
 
date: Fri, 4 Jul 2008 07:28:01 -0700,    group: microsoft.public.access.queries        back       


How to look-up ID#   
In my query I use the following to look up a case number which is really the 
Auto Number ID: Like [CASE ID#] & "*"

However, when I look up record 28, it finds all of the 2800s and not 28.

Any suggestions?

Thanks,

John
date: Fri, 4 Jul 2008 07:28:01 -0700   author:   jmuirman

RE: How to look-up ID#   
Take the & "*" off the end

"jmuirman" wrote:

> In my query I use the following to look up a case number which is really the 
> Auto Number ID: Like [CASE ID#] & "*"
> 
> However, when I look up record 28, it finds all of the 2800s and not 28.
> 
> Any suggestions?
> 
> Thanks,
> 
> John
date: Fri, 4 Jul 2008 07:34:01 -0700   author:   Dennis

RE: How to look-up ID#   
Thanks Dennis 

"Dennis" wrote:

> Take the & "*" off the end
> 
> "jmuirman" wrote:
> 
> > In my query I use the following to look up a case number which is really the 
> > Auto Number ID: Like [CASE ID#] & "*"
> > 
> > However, when I look up record 28, it finds all of the 2800s and not 28.
> > 
> > Any suggestions?
> > 
> > Thanks,
> > 
> > John
date: Fri, 4 Jul 2008 08:48:00 -0700   author:   jmuirman

Re: How to look-up ID#   
On Fri, 4 Jul 2008 07:28:01 -0700, jmuirman
 wrote:

>In my query I use the following to look up a case number which is really the 
>Auto Number ID: Like [CASE ID#] & "*"
>
>However, when I look up record 28, it finds all of the 2800s and not 28.
>
>Any suggestions?
>
>Thanks,
>
>John

The LIKE operator accepts wildcards - e.g. * matches any string, ? any single
character, # any numeric digit. If you want to search on an exact value, don't
use LIKE and don't use the wildcard "*". Just

[Case ID#]

would prompt you.

On the other hand, autonumber values are best kept "under the hood" and not
exposed to user view. Will your users actually have case 28, or case 315, or
case 446 memorized? Is there some other field (or fields) which are human
-meaningful? If so consider using a Form with an unbound Combo Box; this would
have the case number as its bound column, but the human-readable text as its
visible column. You could then use a criterion

=[Forms]![nameofform]![nameofcombo]

as a criterion.
-- 

             John W. Vinson [MVP]
date: Fri, 04 Jul 2008 13:42:50 -0600   author:   John W. Vinson

Google
 
Web ureader.com


    COPYRIGHT 2007, YARDI TECHNOLOGY LIMITED, ALL RIGHT RESERVE  |   contact us