473,385 Members | 1,267 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,385 software developers and data experts.

Query Using information from current line of a table

This is my first post here so if you need more information please ask.

What I'm trying to do is build safeties into a database. What I want to do is have a combo box in the table that will only allow certain selections baised on another column in the table.

I can get it to limit if I use a form to get the cirteria, but I want it to grab the cirteria from the curren row of the table that I'm working in. Any ideas or help would be appriciated

Also I'm using Access 2003

Alia
Dec 26 '07 #1
2 1164
jaxjagfan
254 Expert 100+
This is my first post here so if you need more information please ask.

What I'm trying to do is build safeties into a database. What I want to do is have a combo box in the table that will only allow certain selections baised on another column in the table.

I can get it to limit if I use a form to get the cirteria, but I want it to grab the cirteria from the curren row of the table that I'm working in. Any ideas or help would be appriciated

Also I'm using Access 2003

Alia
Are your comboboxes based on tables as their data source? If so is the criteria value a column in the tables? Is one combo limiting/extending choices available in the next? Having a structure based on tables vice values allows you or users to add values and change criteria without changing code.

My end users maintain these tables since they know the business processes. I just have to maintain the application.

On the AfterUpdate property of the TextBox or Combo that is used as criteria you will need to requery the combobox that is being limited or extended.

Expand|Select|Wrap|Line Numbers
  1. Private Sub YourCombo1_AfterUpdate()
  2.  
  3. Me.YourCombo2Name.Requery
  4.  
  5. End Sub
  6.  
Dec 26 '07 #2
The Combo box is baised on a query of another table, but I want the criteria of the query to be the previous column in the same row of the current table.

Basically I have one table that lists all employees and lists what jobs they can do. Then in another table I want to select one of the positions and have the combo box in the next column only list thoes employess that can fill that position.
Dec 26 '07 #3

Sign in to post your reply or Sign up for a free account.

Similar topics

0
by: B. Fongo | last post by:
I learned MySQL last year without putting it into action; that is why I face trouble in formulating my queries. Were it a test, then you would have passed it, because your queries did help me...
3
by: Scott Morford | last post by:
I am developing a weed management database for the preserve I work on. One of the queries I'm working on will allow the user to run a query and see which weed patches have NOT been treated in the...
3
by: Random Person | last post by:
Does anyone know how to use VBA to relink tables between two MS Access databases? We have two databases, one with VBA code and the other with data tables. The tables are referenced by linked...
1
by: Daveyk0 | last post by:
Hello there, I have a front end database that I have recently made very many changes to to allow off-line use. I keep copies of the databases on my hard drive and link to them rather than the...
8
by: Jim in Arizona | last post by:
I've been using an example out of a book to be able to edit the rows in a database. I am getting the following error: ========================================================...
6
by: jjturon | last post by:
Can anyone help me?? I am trying to pass a Select Query variable to a table using Dlookup and return the value to same select query but to another field. Ex. SalesManID ...
9
by: Frawls | last post by:
Hi I Am am having problems with a stored Procedure that i wrote. Basically whats happening is that the Stored procedure Runs fine when i EXECUTE it in SQL Query analyzer. But when i debug...
5
by: jonceramic | last post by:
Hi All, I started developing in Access, and people took notice and so we're starting to migrate into our corporate's bigger Oracle system. I'll still be using my developed Access front ends,...
3
by: jambonjamasb | last post by:
Hi I have two tables: email_tbl Data_table Data table is is used to create a Form Data_form
4
by: zion4ever | last post by:
Hello good people, Please bear with me as this is my first post and I am relative new to ASP. I do have VB6 experience. I have a form which enables users within our company to do an intranet...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...
0
by: ryjfgjl | last post by:
In our work, we often need to import Excel data into databases (such as MySQL, SQL Server, Oracle) for data analysis and processing. Usually, we use database tools like Navicat or the Excel import...
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
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:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...

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.