problem with connecting query and combo box

  • Thread starter Thread starter eleftheriak
  • Start date Start date
E

eleftheriak

Hello to all,


I m trying to get the job_no from a text field of my form and put the
title of that job in a combo box by doig a select statement .

SELECT Trying.title FROM Trying WHERE
[Trying.job_no]=Forms.qViewJobs.job_no;
But this code just gives me only 1
record. It does seem that select does not work. Any ideas? I put inside

the combo box the select statement is that right?


Thanks in advance


Riri
 
I have a table that has some information about titles of jobs.

that table is

j7001 hhhhh
j7001 kjjkjh
j9809 skjhfj

Ihave the job no on my form and i want to have for the j7001 the combo
box saying the hhhhh and kjkjkjkh titles. That's all.

Thanks in advance

Riri
 
It appears you are trying to get multiple results from a single value.

Try the following:

SELECT job_no, title FROM Trying WHERE [job_no]=Forms.qViewJobs.job_no;

Change the combo to a 2 column combo and set the first column to 0 width.
You will see both entries in the combo. If the combo is bound to a field,
after you choose 1 of the entries and come back to the record later on,
there will only be the first value. That's because the first value resolves
the Where clause.

If you use a subform to display the results in a second table, you'll get
what you want.
--
Arvin Meyer, MCP, MVP
Microsoft Access
Free Access downloads
http://www.datastrat.com
http://www.mvps.org/access
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads

Cascading Dependant combo boxes 0
Combo Box 3
combo box filter 1
Unbound combo box 6
Combo Box and First Record 5
Combo box selection 5
Combo Box Help 7
Combo Box Question 4

Back
Top