By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
424,504 Members | 1,448 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 424,504 IT Pros & Developers. It's quick & easy.

Query Querstion

P: n/a
Hi All,

I need a query that allows users to enter the first three letters of a field, and list all records that match.

Thanks, Chuck
Nov 13 '05 #1
Share this Question
Share on Google+
4 Replies


P: n/a
Add this to your SQL statement:

WHERE Left([theField],3) = [Enter the first three letters]

Or, in the design grid, start a new column, enter the expression

left(theField,3)

and put in the criteria row

[Enter the first three letters]

If you want to enter the three letters from code, or from a form, you
need a slight change. But you didn't mention the user interface.

Chuck Insight wrote:
Hi All,

I need a query that allows users to enter the first three letters of a
field, and list all records that match.

Thanks, Chuck


--
Bas Cost Budde, Holland
http://www.heuveltop.nl/BasCB/msac_index.html
For human replies, replace the queue with a tea

Nov 13 '05 #2

P: n/a
in the criteria box for your field, put:

Like [forms]![yourform].[controlname]

for example if it were a last name it might look like this:

like forms!mainform.txtName
"Chuck Insight" <j.*******@insightbb.com> wrote in message
news:Judxe.108399$_o.53670@attbi_s71...
Hi All,

I need a query that allows users to enter the first three letters of a
field, and list all records that match.

Thanks, Chuck
Nov 13 '05 #3

P: n/a
This is the syntax I needed.

Thanks a 1,000,000
Chuck

*** Sent via Developersdex http://www.developersdex.com ***
Nov 13 '05 #4

P: n/a
Like, and no '*'? Does that work?

John Welch wrote:
in the criteria box for your field, put:

Like [forms]![yourform].[controlname]


--
Bas Cost Budde, Holland
http://www.heuveltop.nl/BasCB/msac_index.html
For human replies, replace the queue with a tea

Nov 13 '05 #5

This discussion thread is closed

Replies have been disabled for this discussion.