473,396 Members | 1,933 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,396 software developers and data experts.

Can you fill a query parameter from a list ?

I have a DB with details of about 60 countries. I have a query that
selects part of the details for a given country based on a parameter I
type in when the qury runs. These details are then printed from a
report.

Rather than having to type in the individual name of the country I
need the details from I would like to be able to select it from a list
or combo box or similar. The names are historical can can be easy to
miss-spell.

Any Thoughts

BTW Access 2002 / 2003 (home and work)

John
Nov 13 '05 #1
2 1259
create a form with a combobox - use the table containing the 60 country
names as the rowsource.
Say your form is called frmGatherCriteria and your combobox is
cboCountry

Then your query would look something like

SELECT somefield
FROM sometable
WHERE Country=[Forms]![frmGatherCriteria]![cboCountry]

Nov 13 '05 #2
On 18 Aug 2005 15:20:15 -0700, pi********@hotmail.com wrote:
create a form with a combobox - use the table containing the 60 country
names as the rowsource.
Say your form is called frmGatherCriteria and your combobox is
cboCountry

Then your query would look something like

SELECT somefield
FROM sometable
WHERE Country=[Forms]![frmGatherCriteria]![cboCountry]


Sorry perhaps I did not make myself clear enough. When I ope the
repot the query behind it runs and that pous up the parameter box. It
is then I would like to have a drop down with a list oc country names

Nov 13 '05 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

9
by: Megan | last post by:
Hi- I'm creating a database of music bands with their cds and songs. I'm trying to program an SQL statement so that I can enter a string of text in a textbox, press the 'Enter' key, and have...
6
by: JeffB | last post by:
I have tried several different methods of getting a datagrid to fill with information. Below is the code I'm now using. When viewed in the browser and the text box filled with a parameter value...
4
by: Dave Edwards | last post by:
I understand that I can fill a datagrid with multiple queries, but I cannot figure out how to fill a dataset with the same query but run against multiple SQL servers, the query , table structure...
2
by: pwh777 | last post by:
I need help in understanding the DataAdapter Fill method and how it relates to the binding to controls on a form. I have a table called tbl_CID_XRef on SQL Server. I have written as a test the...
3
by: doncee | last post by:
Not an expert but have a paramater query that would like to open as a list box on an existing form. I have a button which opens the query from the form right now but would like to have it open as...
2
by: zazu | last post by:
We have a query which is used as a mail merge source in Word. No problem. However we made it a parameter query and when trying to establish the link between the query and the word document in the...
3
by: altafur | last post by:
hi, i am using java with hibernate . i want to run a hibernate order by query thru java. i have written the query in hibernate.hbm.xml file. the query is as follows: query: SELECT distinct...
1
by: limperger | last post by:
Hello everyone: First and foremost: I find this case below difficult to explain so let me hereby present my apologies if someone's willing to help but does not understand what is all this thing...
7
by: limperger | last post by:
Hello everyone! Just in case anyone has any wonder about this... I have a parameter query that searchs for records that have the particular word provided by the user in a memo field (using the...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.