Tricky Table Trouble
Feb 3, 2008
Ok, I have a table that contains a number of yes/no fields depending on location.
There are two main parts of my db that use this, one is users (for their departments) and the second is changes (for secondary locations)
I want to have two fields in the table used to reference a set of locations. Meaning i can reference the table and get locations where userID = 3 or alternativly where ChangeNumber = 6
Can somebody help me in making this work. Im currently having issues with duplicate values etc
View Replies
ADVERTISEMENT
Dec 14, 2004
Hello,
I created a sys admin database and the big problem I am having is linking the hostname field in table 1 to the hostname field in table 2. I have tried making both fields primary keys, I have tried creating a relationship to the two fields between the two tables. I have tried adjusting the join types.
Yet, no matter what I try, the hostnames from table 1 will not populate in table 2. I have even tried adding a new hostname to see if it would populate and it won't.
any ideas?
Thanks,
stillabeginr
View 2 Replies
View Related
Nov 19, 2004
I have a training database in which I want to make a text box that data only needs to be entered once for 50 records (not once for each record). But I need to include the information from that box in a form that is already getting its info from another table. When I try to do this with a second table I get this- #Name. And if I include the needed field in my query I'll have to update each record rather than just one time. I have a different database that does this, but I inherited it from someone else, who locked out design view, and I can't contact him to find out how he did it. PLEASE HELP!
Thanks,
Scott
View 5 Replies
View Related
Jul 26, 2005
I do not know if I'm shooting for the moon here (I haven't seen anything like this yet). I have a database that keeps track of different flights for screw conveyors. The part number on these flights are based on many fields in the database, with a couple characters that aren't. I am trying to make a validation rule that checks to make sure the feilds that are a part of the Part Number match up, or if there is a way to have it auto-fill everything except the 2 characters that have to be entered manually. I don't even know if what I'm saying makes sense (Story of my Life).
Thanks to anyone who can help, and those who wish they could.
-Brian
View 1 Replies
View Related
Jun 18, 2007
im creating an error reporting database.
for this the hardware/system items need entering
they will have a unique id
to assist identification i would like the unique id to start with a 3 letter code refering to the type of hardware/system/periferal followed by the number
e.g a printer will ahve the id "ptr 00000" and a computer will have the id "cpu 00000" with the 3 letters automaticaly comeing from a combobox field in the same table (form to the user)
i have allready been able to get autonumbers with 3 letters before when i created the tecnitian id they are "TEC-00000"
any help thanked. im an A2 student so i know all the code stuff.
thanks in advance
Jimmythemadman.
View 14 Replies
View Related
Sep 7, 2006
I have an insurance policy database keeping track of insurance policy details for household and commercial shops and businesses.
Tables I have are tblPolicyHousehold, tblPolicyCommercialS (Shop), tblPolicyCommercialB (Business).
They each contain the following fields (the other fields they contain aren't relevant to this)... SumInsured, extCover1Desc, extCover1SumInsured, extCover2Desc, extCover2SumInsured, extCover2Desc, extCover2SumInsured
I want write a query to list all the policies with the building sum insured. Easy enough... Heres the catch.
In some of the extended cover fields it will say in the description...
"Building of 123 AnyStreet" so I want to get the value of that extended cover item where the description for it contains building...
So I want to get extCover1SumInsured where extCover1Desc LIKE "*Building*" and adding that value to the SumInsured field...
Any ideas?
View 2 Replies
View Related
Oct 2, 2006
I have one query that shows a NAME for each day.
Every day each NAME must have one and just one SITUATION.
So I'm trying to make a query that shows which have NO SITUAITON yet and other that shows which HAVE A SITUATION already.
View 4 Replies
View Related
Feb 19, 2008
Hi All,
I have attached a file which I need a help from, I need the subform to be populated based only on the Employee Code and the Dates where the employee logged-in a Job Order.
I dont have any code on the cmd button for I am lost on what will be the query statement to update the subform datasheet.
Thanks.
View 2 Replies
View Related
Jun 30, 2005
Hi all,
Been pulling my hair out about this for a while, so i hope someone's feeling kind:
http://www.agga.dsl.pipex.com/pics/AWF01.gif
I'm using the BHRefPrefix to build part of a reference number. The Principal and Site exist on a separate form, and i need to use both as criteria in order for the correct BHRefPrefix to be returned.
I sort of get it working using two joins, but it doesn't let me add any new records. I've tried straight queries, queries with DLookup expressions, and i just can't get what i need.
Pete
View 3 Replies
View Related
Nov 5, 2007
In Access 2003 we use an mdw file (unfortunately named system.mdw) that people are joined to (by using Workgroup Administrator) when they become a new user on the system. This works well except that it is time consuming to go through the process for every new user. I am aware that you can create a new mdw file using the user-level security wizard however I have extra problems. This was set up originally when access 97 was in use and the no of users was about 4, there are now 50 plus and growing. We have numerous databases that are all secured through the use of the same mdw file, however as people are only joining this mdw (by using the Workgroup Administrator), when we get someone with a little computer savvy they will figure out that by creating a generic system.mdw file they can escape all security levels that are in existence in the system.mdw file that we want them to use.
Is it possible to somehow get a database to associate itself with an mdw after the mdw has been extensively modified?
I am aware of short cuts that have the mdw file in them but they are easily bypassed. Furthermore as we have numerous probably 100 databases all pointing at the one mdw file is it possible to get them all associated with the same mdw file? I have looked through the forums and various others but have not found an answer that will help me. Can anyone help?
View 5 Replies
View Related
Jan 10, 2008
Hi all,
My boss has asked me if I could take a look at the following problem and whilst I've searched around and tinkered with it myself I'm not making too much progress!
Here is an example:
I have forecast data for working weekdays Mon-Fri. For the weekend I need to replicate data from Friday across the Sat/Sun rows. This is just outside my remit! The data is then exported to Excel where imbalance costs etc. are calculated.
Background: The result will be that management will be able to tell what value *weekend* work will have. At present I already have a set of results for all DF activity. If we take that figure and subtract THIS result we'll be able to see how much benefit working on the weekend has.
Something management are very keen on looking into :)
Any suggestions on where to start would be much appreciated.
Thanks.
View 3 Replies
View Related
Jul 15, 2005
Hello all:
In table 1 I have some document #s
e.g.
320
321
322
170
171
172
151
152
In table 2 I have some document #s e.g.
170
171
151
I would like to create a query, that will look at the document #s starting with 17* and 15* in table 1 and look for it in table 2, if the document #s do not exist, I would like the query to spill out the following:
320
321
322
172
152
Is this possible?
Thanks so much in advance for helping!
View 3 Replies
View Related
Apr 25, 2006
Hi all - I am not sure if this is even possible, but I know if it is someone here will know how to do it. I have a table with a list of dogs names. The dogs run in a team so I have another table with their run record. Currently, the form would have a text box where you select the dog's name and then another text box where you select the position in the team so it looks like this:
name1, position1
name2, position2
and so on. I would like to create the form where the text boxes are aligned to look like the team and the person would just have to select the dog's name that ran that position and the code behind would create a record that looks like the one above. For example, here is what the form would look like:
Position1 Position2
Position3 Position4
Position5 Position6
I would like the person to be able to select the dog's name in the text box labeled Position1 then move on to select the dog's name in Position2 and so on. I am imagining the record will still look like the one above. Meaning,
name1, position1
name2, position2, and so on.
Does anyone know if this is possible? Thanks so much for all your help. This forum has been so helpful in the past, I thought I would just put this out there.
Therese
View 5 Replies
View Related
Jul 6, 2006
Sorry this is so long but I am trying to make it as detailed as possible...
The Setup
My database is similar to the sample "Service Call" db. I have a main table called "tblTT" which has an autonumber primary key. The table also contains several foreign keys such as UserID (not an autonumber) from "tblUser", TechID (also not an autonumber) from "tblTech", etc. I have the relationships setup with "Enforced Referential Integrity" for both updating and deleting records. Each relationship has a RIGHT OUTER JOIN ("Join 3" in access) so that all records from child (tblTT) and only equal from parent (tblUser, tblTech, etc.) will be included. I have a form for nearly every table which serves different purposes but the main function of the DB is to create new Trouble Tickets (TT's), a.k.a. service calls. Therefore the main form used is my "frmTT" form in add mode. The form contains all the fields from my "tblTT" table and contains (directly) no fields from any other table (I guess indirectly it contains fields from all the parent tables...).
The Problem
When I pull up "frmTT" and try to create a new Trouble Ticket for a user that does not yet exist in the table "tblUser" I get the error "You cannot add or change a record bcause a related record is required in table 'tblUser'".
What I want is for my users (the "Techs") to be able to create a new Trouble Ticket without having to worry about populating the "tblUser" table (and other parent tables) first.
My Solution
I was going to (and unless someone can find an answer for me still will) fix this using VB script by setting up a query to check all the parent tables for the values in their corresponding fields in the form. If the query returns no results an "INSERT INTO" statement will run to populate the parents tables so that the form will save itself into the Trouble Ticket table ("tblTT").
I feel that this is a huge work around and not the proper fix. I would prefer to do this the right way both to have a correctly setup DB and for future reference. Can anyone help me with this?
Thanks,
Andy
View 3 Replies
View Related
Dec 7, 2005
Hey I am trying to create a query that selects only certian values within a field in the based table. Easy ehough. HOWEVER, the field in the table that I am trying to select certian values from is a LookupWizard. So in that one field, there is a drop down box with one other value for a total of two values in one field.
So I am at a loss for how to properly select things using the criteria in a query. Ive tried Criteria: Like "value" for both values in the look up wizard,but no luck.
any help is appreciated!
View 3 Replies
View Related
Aug 23, 2005
Hi all,
I have a table that has a long date format for example 05/05/05 02:40:34 AM how can I add an 8 hours to the date and time. Please help if you can because I"m going nuts!!! thanks. I want it to look like 05/05/05 10:40:34 AM
View 11 Replies
View Related
Apr 14, 2006
I'm probably approaching this wrong, as I'm definitely out of my depth - maybe someone can offer some advice
I have 2 spreadsheets. One is a simple parts list with a code and some other info - I've loaded this into Access no problem.
The second sheet is used for ordering - it contains one text field with a company name at the top, followed by a list all in one column of all of the item codes, and another column with a description, and a third column with an x in against each item being ordered.
What I would like to do is set up a new table with the company name, and then each of the item codes which have been selected (there will always be a maximum of 10 ordered so I envisage a field per ordered item code).
I haven't got a clue how to do this - Can anyone help?
I can then link the two tables and print a report - I could probably do this bit.
Thanks for any advice
View 1 Replies
View Related
Feb 13, 2006
Hello Everyone :D :
I have a reporting interface providing users with a multitude of reporting options and capabilities. One aspect involves utilizing the ability to allow users to save their settings on the interface due to the number of options provided. One of the aspects revolves around working with listboxes.
Each listbox is pre-loaded every time with a list of items from a master table pertaining to the listbox. The user selects their desired choices, saves*, etc...Once loading a setting, I'm looking to have the listbox pre-loaded (easy) but then auto highlighting the items selected or rather pulled from the user settings table (each listbox has own table for user saving of options). So, if a user selects items Alpha, Beta, Delta, and Falcon from a list of 100 choices, then those 4 items would be saved under that user setting, within the code table (user specific). When they load the setting back onto the user interface, it should pull the 100 choices and auto highlight the 4 items. Hopefully I've explained that properly.
*A user is able to save, save as, load settings, unload settings, etc...from the reporting interface. When a user saves settings, these settings are saved within the user settings tables. Each table varies depending on the nature of the values within the reporting interface. Listboxes have their own tables connected to the primary settings table.
Any ideas anyone? :rolleyes: :D
View 4 Replies
View Related
Dec 16, 2004
I have what I think is a difficult problem to overcome...
I am designing a form to create an invoice. The user will select a workstream and a date range in form frmInvByHrs. Within this I want two sub-forms, one is frmInvByHrsTsht and the other is frmInvByHrsBill. I want the first one to display all the staff and their hours done, and the second one to be in data entry mode where you can enter the hours you want to bill. Each sub-form is based on a separate query.
Is it possible to do this? ie. to have one sub-form in data entry mode, and the other not? It seems to me that the data entry mode is controlled by the MAIN form regardless of the sub-form settings!
If this is not possible, do you know how I can acheive this?
Thanks
S
View 1 Replies
View Related
Jun 20, 2005
Hello. Recently posted for advice on building an access database on health service training. I had a lot of help but I suppose I haven't really grasped relationships yet. My database looks like this:
tb_staff containing staff_id, first_name, last_name, base, dept_ward, job_title
tb_courses containing course_id and course
tb_training_done containing staff_id, course_id, date_trained, trainer, venue
I have 1:M tb_staff to tb_training_done and the tb_training_done is linked to the tb_courses 1:1 - not sure if this is right but it's the only way access will do it.
Anyway, my idea was to use a form and subform to enter training done but after setting up the lookup it won't allow duplicate courses i.e. same course done each year. Can anyone explain how the lookup works? Where are the details of courses done stored?
Hope that's not too vague?
View 2 Replies
View Related
Aug 6, 2007
im having a bit of trouble generating a field in one of my queries. i think its fairly simple, all i want to do is have the field in my query to show a date, that is just calculated by subtracting 5 days from the current day. i have something that looks like =Now()-5 but that doesnt work obviously. so im just asking whats the imput going to look like if you want to subtract 5 days from a date? oh and im using short dates for the date inputs
View 2 Replies
View Related
Sep 13, 2004
I am trying to build a report that lists all call in's and all tardies on the same sheet. They are two different tables, that I made queries out of because of calculation fields. Do you know how I can include all the needed data in the same report?
What I'm getting when I try is either all call-in's for each name that has tardies or vice versa. I need to see all data on one report
The reason I didn't just put all the data in one table was because we track call-in's by occurence, but we track tardies by pay period. So each call in is logged in the call-in table with the date it happened on, and the tardies are logged in by pay period, so only the total is stored in the field.
Do you have any ideas? I'm really stuck and I've been workin' on it for three days now and I don't think I'm going to find the solution by myself. Sorry. Thanks!
KellyJo
View 5 Replies
View Related
Jul 5, 2005
Gee, I know this is probably so simple...I've never in my life worked with any kind of data base program. I've spent 2 hours trying to make it work and it doesn't. I've tried so many things that I can't even remember what steps I did. I'm trying to create a one column list for phone numbers, no names or anything else...the most important thing is that when I add new phone numbers to this list I want Access to alert me that it is a duplicate and not allow me to add it.....first of all it won't let me add entries with dashes such as 312-5964, I tried selecting "numbers" and also "auto number", both didn't work, what am I doing wrong...can someone give me the steps from the beginning please....I don't have time to figure this out and it's holding me back from finishing a task. I have to get working on my Video Professor Learning CD for Access which I have at home, but right now I'm at work and can't do that...hellllllllp! I'm ready to tear my hair out :eek:
Thanks, Rosey
View 2 Replies
View Related
Mar 13, 2006
I have an Access DB I have to put on numberous laptops. The DB is being transported via a CD. When i try to copy the DB from teh CD to a new folder on the laptop I get messages that the DB may have a virus and it cant be copied, or I need to install a microsoft service bulliten...xxxx ( I am not sure what the number is). The DB does contain VBA code and I am certain it is virus free. Is there some setting in access which enables this file to be copied on laptops which do contain virus or firewall protection or must I disable virus protection on these machines before instlaling the program or is it another issue altogether. Thanks.
View 3 Replies
View Related
Mar 27, 2006
Hi
I have genreated an autonumber in my table, at this is used as key. after importing 135 records it starts to jump 48 records before it creates a new. This means that with every record i import after 135 i have a space of 48 between each. So what sort of thing can cause this? and even better how do i fix it?
Best Regard
Roald
View 2 Replies
View Related
Jul 6, 2006
I have been using the forums for the past month and a half, and they have been extremely beneficial to me. I am working on a database that cross references my companies Steel standards to American standards. I am trying to make it searchable in a couple of different ways. I have borrowed code found on this site to make two different search engines. One works very well but the other I am getting hung up when I try to switch from the previous code to mine. below is an example of my code. It is taken from code placed on here previous called "SampleSearch"
Private Sub cmdSearch_Click()
On Error Resume Next
Dim sSql As String
Dim sCriteria As String
sCriteria = "WHERE 1=1 "
'tblSubject qrySearchCriteriaSub
If Me![Spec] <> "" Then
sCriteria = sCriteria & " AND qrySearchCriteriaSub.Spec = """ & [Spec] & """"
End If
If Me![SteelType] <> "" Then
sCriteria = sCriteria & " AND qrySearchCriteriaSub.SteelType like """ & [SteelType] & "*"""
End If
If Me![Group11] <> "" Then
sCriteria = sCriteria & " AND qrySearchCriteriaSub.Group11 like """ & [Group11] & "*"""
End If
If Me![Group143] <> "" Then
sCriteria = sCriteria & " AND qrySearchCriteriaSub.Group143 like """ & [Group143] & "*"""
End If
If Me![Substitute1, Substitute2, Substitute3, Substitute4, Substitute5, Substitute6, Substitute7, Substitute8, Substitute9] <> "" Then
sCriteria = sCriteria & " AND qrySearchCriteriaSub.Substitute1 = """ & [Substitute1] & """"
End If
sSql = "SELECT DISTINCT [Spec], [SteelType],[Group11],[Group143]from qrySearchCriteriaSub " & sCriteria
Forms![frmSearchCriteriaMain]![frmSearchCriteriaSub].Form.RecordSource = sSql
Forms![frmSearchCriteriaMain]![frmSearchCriteriaSub].Form.Requery
'[Spec], [SteelType],[Group11],[Group143]
'frmSearchCriteriaSub.Requery
End Sub
I apologize also because I do not know how to post this in a scrollable window. If someone could help me with that too.
The problem with the code is that I am using a form to filter a query, this will then display the table of the steels that meet the requirements. However, I have altered all of the fields to my names and the combo boxes have my information, but they do not seem to place any parameters on the query. I attached the original DB that I got this code from any help would be appreciated.
Riley
View 2 Replies
View Related