I am trying to do a query that is set up like this:
I have a table with several fields which represents company vehicles. In each field, a persons name is inputed, unless no one is using the vehicle, in which then the field is blank. Each record represents one day, so the date is the primary key.
I am trying to make a query look at each field, and pull out one persons name, and show which vehicles that person will use over a date range. I have a form setup where you put in the date and the name you want ([Forms]![staff printing]![staff name]), and I am trying to tell the query to look at the form field and bring back only the results with that persons name.
Here is an SQL portion:
((Vehicles.[901 Morning])=[Forms]![staff printing]![staff name]) AND ((Vehicles.[901 Afternoon])=[Forms]![staff printing]![staff name]) AND ((Vehicles.[961 Morning])=[Forms]![staff printing]![staff name]) AND ((Vehicles.[961 Afternoon])=[Forms]![staff printing]![staff name]) AND ((Vehicles.[979 Morning])=[Forms]![staff printing]![staff name]) AND ((Vehicles.[979 Afternoon])=[Forms]![staff printing]![staff name])...
The date portion is working fine, which is why you do not see it here... it is only the portion where I try to pull the name for each vehicle that I have a problem.
I tried putting an "OR" where all the "AND"s are, but no luck.
Any thoughts?
(And let me know if I was not clear)
I have to send an Access table consisting entirely of Text fields to another company for automatic list cleansing. My table MUST NOT CONTAIN even a single comma, else the whole procedure will go Iraq-shaped.
Therefore before sending the table, I must apply FIND to each field (column) to search for that one comma that may have slipped in.
So far I know only how to search one column at a time. Is there a way of searching the whole table for commas within Access, rather than first exporting the table to Excel?
i have a form with a control for "repair type" and a subform that has a query that searches a table holding vehicle repair records. on the form the user can enter up to 5 repair types, [repair1], [repair2], etc.. Then the control on the form holds each type of repair to search by. Since the user could use one or all five repair fields and put repair types likes brakes in field one on one record and field 5 on another record, how do i search to just pull out those records that have the specified search criteria?
If i put in [form]![control] in each of the 5 criteria in the query it comes back with no records, because it it looking for that type in every repair field rather than once between the five fields?
I am looking to transfer a number of spreadsheets that I use to track IP Addresses to an Access Database, I have set up the tables and fields, what I would like to do is search for unused IP Addresses from populated table/fields.
I have a basic form which currently displays different information such as name, date, country etc.
At the moment if I type anything into the fields it edits the data (allow edits is on).
Is it possible that if can type in a name and it will find the pieces of work by that named person rather than edit the field? At the same time I might want to search by name and date.
Currently I have a listbox that lists all the names and when selected it requeries that data and lists all records just by that name. I am wanting to also search by the fields.
hi. i'm a novice with Access so any explantions need to be pretty simple. I'm trying to create a query that searches 2 fields when 1 word is entered into a parameter value box..... would any1 hav a sugestion. please post a reply if you don't understant what i'm trying to achieve.
Ok, I used the wizard for the 1st time today to create a web page access to my database. Sure enough the fields I added all appear and can browse up and down the records.
My question is....How do you make it searchable ??? Is there already something there i can add to the page from design ?? or would anyone happen to have a bit of code I can manually add into the HTML to achieve this ??
Thanks for everything and anything.
I originally had this thread in the "queries" forum but had no answers. Maybe nobody knows, or maybe I was in wrong forum. I still might be in wrong forum, in which case apologies. It just sounds like an area I'd like to branch my database out as (I think). If this bit finds an answer my next problem is going to be to make sure that over the web page version I'd need it to be read only.
Hi, Im new to Access and VB so please be patient with me. Do know a little about sql queries though.
I have two tables. The first (clones) has another table (BLAST Nucleotide) which is dependent on it (ie: one clone can have many BLAST records)
I want to create a search where I can search by either clone name or BLAST name, and return the results in a list box, and then select an entry from the list & view
Not sure where to put this, but as I want the information to be shown in form view, I guess this is the bext place to start.
In breif, I have created a database, in which infomation on machinery is held.
The problem I am having (atm), is I have to create a function, which I want to be presented in form form, where by each item can be searched by it's RequestID (unique) or the customer who owns it, so that its current location can be attached (or viewed).
I'm not sure whether i've worded this well, so to sumerise:
I need a form with 3 fields, RequestID, Customer and Location.
Where by I input the RequestID, which brings up the Customer and Location, or input Customer which brings up the RequestID and Location (obviously there will be mulitple results from Customer search).
Again, I hope I haven't confused anyone because it's pretty simple what i'm trying to say, but....
Im trying to set up a combobox on my Customer Contact Information form, where you can enter a phone/fax/cell/pager or any misc number, and it will bring up the appropriate customer.
Is it possible to make a query that will show the different phone number fields as one field?
Thank you so much for your help, and please let me know if I can clarify anything.
I am new to access and am trying to setup a small database with names and phone number in it. I would like to be able to set up something to search the database for the names that I type in and display the records that have the same name. I have entered all the names in a table but cannot find any info on what I should do next. Thanks for any help you can offer.
How can I get a PK in another table, based on searching for it based on 2 values. By searching with 2 values you will always get only 1 record.
READ BELOW FOR SITUATION
My Problem on my form:
The user enters 2 values, after entering the 2nd value a Unbound combo box runs a query, which searches for these 2 values (unique), that appear in a separate table.
These 2 values are unique toegether, but records in this separate table have another field, its Primary Key (AutoNumber), used to identfy the pair.
So back to this Unbound Combo Box that searched for the primary key of the 2 values entered. Now Only the Primary key can be selected from the combo, the value that I'm after.
But since there will only be 1 option (being unique), how can I have the PK value aready stored in an Unbound text box, as opposed to having options in a Combo box?
I have a parent table called patient info. and a child table called fills. The database in the future will become very large, and will be difficult to find a particular patient in the parent table to update fills in the child table. How can I search through the parent table using a form for easy access to a particular patient so that I can update fills? Thanks for those who help!
I have a form that runs a parameter query to search for university name and then displays 2 fields, university name and course name.
I am having difficulty with a search button that i have on the form called search_command; it is supposed to run the exact query as when you enter the form, it does this but displays the result in a dataheet, i want it to repopulate my 2 text label fields as mentioned above.
In addition i want then to be able to go to a specific record, select it and then press a button to append it to another table. i ahve not started this part yet
i am a beginner.. how i can write a code in a afunction that search a record in a table according to some conditions example: i hv table employee that contains Title field which can have one of 3 values:Admin, Rep or Driver i need to search the employee that has his type = admin i can have one or more records that have this type... so how to find first one, last one and all?
I already have many table for each month , JanuaryT-DisemberT. I'm using simple form to key in data inside that table. Inside to that table (JanuaryT-DisemberT) have project number data i want to notice pop up when i try key in if that project number not valid..
example
JanuariT Name -Project Cod- Validation John -2012ABC - Not valid Michel-2013WER-Valid Mike-2014TERG-Valid
FebruariT Name -Project Cod- Validation Ann -2011AAA - Not valid Sam-2012BCB-Valid Tony-2013TEC-Valid
What i want to do is when i want to key in data in MacT using Form with ADD butoon, some notice will come out if .... for example : Daniel-2011AAA or Jony-2012ABC the notice will come out " THIS PROJECT COD NOT VALID, PLEASE CHOOSE ANOTHER COD". it something like notice to tell me that project cod already not valid yet. It look like "automatic searching" data for every table. It Is possible to do like this?
I have a database that I am creating for my work. I have a form that I am trying to get it to search the information from a table to pull the record on the form. I would like to search infomation such as employee id and wanting it to pull that information from the table.
I am currently building a booking and invoicing database for the small business where I work. One aspect of this database allows you to enter an employee name and schedule days off via a form I have already built. To access this information I would like a parameter query where you can enter a date once and then have this date looked up across a number of date fields. Here are my table column headings:
ID Employee Name Date 1 Date 2 Date 3 Date 4 Date 5 Date 6 Date 7 ....etc
So, basically, the parameter query would ask "What date?" which the person would enter, and then search all 12 date fields to see if the date was contained in any one of them. Then it would pull any records which did have the date in one of the fields.
It seems really simple but I have searched and searched and can't seem to find the answer. Tried a multivalue field but does not seem to work.
Thanks very much, any help appreciated! Elspeth :confused:
I have an access form and there is a textbox in which i enter a string and have a search button so I need the onclick event procedure to search a string from my table. so how do i do it in access 2010.
I'm trying to search for a variable (varCod) in a table(SerialNumberCustomer) but I want to only store the returned variable in an array if its shipDate is between 9/30/2001 and 10/1/2012
this is what my code looks like so far:
Set rst = CurrentDb.OpenRecordset( _ "Select * from SerialNumberCustomer WHERE SerialCardId = " & varCod & " AND (ShipDate BETWEEN #09/30/2001# AND #10/01/2012#) ")
The line of code works and it returns all of the values in SerialCardId where it's = to varCode but it doesn't go through with the shipDate requirement. It's instead returning all of the dates with the found value.
Every quarter I run a report that pulls loans that meet specific criteria.I export this report into excel (the loans fall into column A)I add a file number and box number in columns B and C.I import the excel spreadsheet to table 2 (they're linked so I don't need to import, it's automatic)
Now that I have the updated information back into the database (table 2), how can I get this information back into table 1? The excel spreadsheet only contains a few loans that need to be updated in table 1. I have tried creating an update query with both tables linked and use the "update to" field. However, when I tried to run the query, it says I have 0 records updated.
My update query is as follows:
Field: Access Bar Code Table: Table 1 Update To: [Table 2].[Access Bar Code]
Field: Access Box Number Table: Table 1 Update To: [Table 2].[Access Box Number]
Basically I'm trying to have the query update specific fields in table 1 based on the information from table 2.
I don't have any database experience whatsoever so please go easy. I'm guessing this kind of this is extremely simple for all of you.
I'm constructing a database of network resources and devices and I'd like to automatically update the values in one field based on the values of a field in another table.
The first table is called "IP" and the fields are called "Address", "IP Type" and "Device". The second table is called "Devices" and contains the fields "Name", "Description", "Asset Number" and "IP".
Here's an example of the tables: (ignore the "code" tag. i've only used it to align my columns properly)
What I want is for the Device field in the IP table to automatically update it's values based on the values found in the Devices table. In this case, the values that should appear in the Device field in the IP table are "Xserve" and "ProliantX".
I've searched through but haven't found a complete solution, just little pieces which I'm too inexperienced to put together myself.
I created a form in Access that retrieves data from a table. Inside the form, I am able to access/populate data fields with data from the table. I also have data fields, inside the form, that requires key-in data. I have some how lost the ability send all data field information to a second table and clear existing data fields for new entry.
Questions: What settings, code or buttons can I use to send/store data field information to a new table? What settings, code or buttons can I use to automatically clear all data fields from my form once data has been sent to the new table?
I have a totalquery that runs fine and give me the sum for both fields I'm looking for but I can't get the outputs to fill the fields on the form. I have tried the Dcount query in the control source but that just returns an error and locks up access.
Code: SELECT [Tble-wcDelays].Causedby, Sum([Tble-wcDelays].HoursDelay) AS SumOfHoursDelay FROM [Tble-wcDelays] GROUP BY [Tble-wcDelays].Causedby, [Tble-wcDelays].LinkingID HAVING ((([Tble-wcDelays].LinkingID)=[Forms]![Frm-ePlusCent]![cleanID]));
I have a database that will register the emails coming in and what time, also the time, date out and person.
I have a form with the fields to be filled in and a submit button. There are some fields that are automatically filled in and others need manually fill in.
below that part is a sheet (subform in the form of sheet) that should be filled in with the above data. Once it is there, it should empty the fields so they are ready to be filled in again. If I fill new data and press the submit button, it should go to the next available row.