A Microsoft Office (Excel, Word) forum. OfficeFrustration

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Go Back   Home » OfficeFrustration forum » Microsoft Access » Running & Setting Up Queries
Site Map Home Register Authors List Search Today's Posts Mark Forums Read  

Text Based Queries



 
 
Thread Tools Display Modes
  #1  
Old July 14th, 2008, 08:08 AM posted to microsoft.public.access.queries
William Foster
external usenet poster
 
Posts: 6
Default Text Based Queries

Good evening all,

I have a query I need to create that can read individual text characters and
return their codes so that I am able to assess whether they are valid or not.
As an example I want to be able to test whether a string conforms to the
standard AAA000. In Microsoft Excel I can do this by using the Mid and Code
functions, however, these do not exist within Microsoft Access (That I can
find anyway).

Any suggestions on how I may be able to address this issue using an
expression within a query would be greatly appreciated.

Yours sincerely,

William Foster
  #2  
Old July 14th, 2008, 08:47 AM posted to microsoft.public.access.queries
bcap[_2_]
external usenet poster
 
Posts: 260
Default Text Based Queries

I assume that what you mean by "the standard AAA000" is that it should be
three alpha characters followed by three numeric characters.

This can easily be done using the LIKE operator with an appropriate pattern:

LIKE "[a-z][a-z][a-z]###"


"William Foster" wrote in message
...
Good evening all,

I have a query I need to create that can read individual text characters
and
return their codes so that I am able to assess whether they are valid or
not.
As an example I want to be able to test whether a string conforms to the
standard AAA000. In Microsoft Excel I can do this by using the Mid and
Code
functions, however, these do not exist within Microsoft Access (That I can
find anyway).

Any suggestions on how I may be able to address this issue using an
expression within a query would be greatly appreciated.

Yours sincerely,

William Foster



  #3  
Old July 14th, 2008, 09:18 AM posted to microsoft.public.access.queries
William Foster
external usenet poster
 
Posts: 6
Default Text Based Queries

BCap

Thank you; that answers the question perfectly!

Yours sincerely,

William Foster

"bcap" wrote:

I assume that what you mean by "the standard AAA000" is that it should be
three alpha characters followed by three numeric characters.

This can easily be done using the LIKE operator with an appropriate pattern:

LIKE "[a-z][a-z][a-z]###"


"William Foster" wrote in message
...
Good evening all,

I have a query I need to create that can read individual text characters
and
return their codes so that I am able to assess whether they are valid or
not.
As an example I want to be able to test whether a string conforms to the
standard AAA000. In Microsoft Excel I can do this by using the Mid and
Code
functions, however, these do not exist within Microsoft Access (That I can
find anyway).

Any suggestions on how I may be able to address this issue using an
expression within a query would be greatly appreciated.

Yours sincerely,

William Foster




 




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Forum Jump


All times are GMT +1. The time now is 05:58 PM.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 OfficeFrustration.
The comments are property of their posters.