Ok.. I have been racking my brain for hours trying to figure out how to do this. Maybe someone here can help me figure this out.
I have 2 tables. "AR94" & "RPIN"
I need a query to look at the "Provider_PIN" field of both tables in order to find duplicates between that field in both separate tables at which point I need it to say If a duplicate provider_pin exists in the AR94 table & the RPIN table Then remove that provider_pin from the "RPIN" table.
The final result should be that the only records showing in the "RPIN" table would be those provider_pins' that were NOT found in both tables.
I've been playing around with a new database design and ran into a possible 'error' that I would like to avoid.
It's going to be a payroll database to store time codes for hours spent working on specific projects. I have been struggling on how to put this together to fit with what we've been doing for years and I think I hit a few breakthroughs this morning.
However I want to avoid this error of possible duplication of entry.
Simple table set up - primary key is just a running integer; Employee ID; and Week Ending Date.
I can have multiple week ending dates for a specific employee; but I want to avoid having the same employee with the same week ending date. I cannot set up either field as being unique.
I have a form where someone enters a 'Job' to be done which in turn creates a record in a table with all this information
On the form I have a field called 'Repeat Frequency' where the user can choose how often they would like this 'Job' to repeat. e.g. Monthly
Then, on another form someone else can check what 'Jobs' should be done on that day
I have managed to get this to work fine using the DatePart function and it displays all jobs to be done that fall on the current day (e.g. if they choose to repeat it weekly, it will look for all entries where the datePart "d" [DateToBeDone] = Date()-7, -14, -21 and -28)
The problem is that i have been limited to the options of 'repeatability'
What i would like to do is change the options from 'Weekly', 'monthly' etc and instead have a field makrked "Repeat every so many days"
Is there a criteria i can use in a query where i can show records every so many days? i.e. if there is a job in the system that should repeat every 7 days and the [DateToBeDone] is set to 31/10/13, it would return this record on 07/11/13, 14/11/13, 21/11/13 and so on?
I Have tried DatePart ("d", [DateToBeDone]=DatePart ("d", (Date()-[RepeatDays] but what happens is it only shows it if the day is that many number of days in the past and not multiples as i said above.
I have a table with a field that shows the number of pieces that a parcel contains. It looks like this: ParcelID, Pieces, Description
Data example: 1001, 5, Jackets 1002, 10, shoes etc
I need to print labels for each piece that shows to which parcel it belongs. The report will look like: 1001, Total pieces = 5, 1 of 5 pieces, Jackets 1001, Total pieces = 5, 2 of 5 pieces, Jackets 1001, Total pieces = 5, 3 of 5 pieces, Jackets 1001, Total pieces = 5, 4 of 5 pieces, Jackets 1001, Total pieces = 5, 5 of 5 pieces, Jackets
and 1002, Total pieces = 10, 1 of 10 pieces, shoes 1002, Total pieces = 10, 2 of 10 pieces, shoes 1002, Total pieces = 10, 3 of 10 pieces, shoes 1002, Total pieces = 10, 4 of 10 pieces, shoes 1002, Total pieces = 10, 5 of 10 pieces, shoes
If I could populate a table where the number of records equal the value of the pieces column then it's a pretty simple report but I can't figure this out.
I have a query showing lots of records of equipment that is in different rooms. I would like to have a form where the user can bash in a room number and all the records from the query that have that room number in it pop up.
I have the below code to reset my subform after I have filtered it using some combo boxes. One of my fields in the underlying table had a calculated field so I'd get an error when clicking the reset button. I edited the query to update the 'type' field and deleted the calculated field in the table but now get another error. The exact error is 'Run-Time error '3327' Field 'Type' is based on an expression and cannot be edited.' It appears it will not reset my form and show all records as long as this field is based on an expression.
Code: Private Sub cmdReset_Click() 'Purpose: Clear all the search boxes in the Form Header, and show all records again. Dim ctl As Control 'Clear all the controls in the Form Header section. For Each ctl In Me.Section(acHeader).Controls Select Case ctl.ControlType
I have an append query that appends records to a table, and I have a form based on that table.
Users will click a button that will run the append query and then open a form for users to fill in remaining empty cells. How can I filter the form to show only the newly appended records?
I am trying to have a query sort out my invoices by year but also to have the possibility to show all invoices.
I have one table "INVOICE" where I have a column "YEAR" calculated with DatePart function from the invoice date.
On my form "INVOICE LISTING", I want to have a combox "Combo957" selecting the year. I have forced the "ALL" selection to the combox using a UnionQuery.
My problem, I cannot get the query to work. I have tried many ways, the closest I can get is :
Boy, I thought this would be easy! It's simple to show common records, but I can't seem to be able to withdraw uncommon records. They are the ones I want. I can do it the long way by bouncing one record against all the records of the other with an Iif statement, then creating another query that groups all those results (thousands) and eliminates the erroneous data by using a min or max statement as a filter. This results in very, very long calculation times. There has to be an easier way. Please help, because I'm goining to have to do this several levels deep, and it's bad at the first level already. Thanks in advance.
I have a query joining two tables. TableInvoice in the query is Product number and Date purchased. TablePrices contains the same fields and contains prices (quarterly) over the past five years.
Joined by PONumber, I want the query to find the price charged for that date. Right now, if the Product number (TableInvoice) is not listed in TablePrices, it won't show. So, 100 Records might return only 80 if TablePrices does not have all of the Product numbers.
Is there a better way to return all 100 records in TableInvoice and show (Blank) price data if the item is not in TablePrices?
Year EventNumber CorrectiveActionNumber ResponsibleGroup Committment
Each event will have multiple corrective actions. For each corrective action assigned to a group, the "committment" is also assigned to them, but I also have to assigned a committment to our group (SRG). So this makes the query results show two records for each corrective action, one with the group assigned committment and one for my groups committment. I need a query that will show corrective actions that have the group committment assigned but not a corresponding SRG committment assigned. However since my query results in two separate records, I am unsure how to do this.
I have a two part problem right now. I have a Table Labeled "MAIN" where I have three fields that I would like to pull from, lets call them solution, version and testcasename.
Solution and the application name in which there will be some duplicating and also the version also when it pertains to the testcasename for example:
I created a query(SplashSort) to pull just the information stated above.
Under Solution I am trying to apply the string;
Select (Main.ID), (Main.solution) FROM (Main) GROUP BY (Solution) ORDER BY (Solution) Select (Main.ID), (Main.Version) FROM (Main) Group BY (Version) ORDER BY (Version) Select (Main.ID), (Main.TestCaseName) FROM (Main) Group BY (TestCaseName) ORDER BY (TestCaseName)
I have duplicate data in a cell, I want to hide duplicate data and display only non-duplicate data.. I changed the property sheet to only show unique values, but it keeps showing data I don't want to see...
I would like to do a search for my records based on 2 different criterias. If found, the function should just return a boolean value so that I can act further based on the boolean value.
The reason I'm doing this is that I have 2 similar tables that contains EventID and AttendeeID and these 2 tables cannot have the same EventID and AttendeeID. So before I can allow a record to be inserted in the 1st table, it must check that there is no record in the 2nd table that has the same EventID and AttendeID. If there is, then i cannot allow the record to be inserted in the 1st table.
The same thing applies when I want to insert a record in the 2nd table. It must now check the first table.
Recordset.find seems to be only catering to 1 criteria, not 2.
I have a table with an empty column called ActionID. I need to generate a numerical number that begins with 5000 and goes up by 1 number on each saved record. I have a basic form that links all of my other field to the table except the one I need to generate (ActionID) but will need that number saved to the table once its created.
I'm able to import new data from excel just fine, but I can't import updated data from excel due to duplicates not being allowed for a particular field. Is there a way to keep from importing duplicate records based on one field, but still import data from other fields where the information is different from the excel file?
I have a form (form1) that will populate with records (table1) based on key fields of "Project Number" and at time-points we will update part of the record, and then we create a word document detailing the updates with a couple of other bits of information not in original record.
Basically I want it to go from the original form (form1) into another form (form2) (via a command button) taking the key field of "Project Number" where it will ask the bits of information that we don't need have already and the contact person.
I have got this to store in a different table (table2) using a key field of just "ID" from the original records (table1). A list of contact people are in a separate table (table3) using a key field of "contact name" which will include other details for them such as address and phone number.
So from "form2" I would like to produce a report that contains information form "table1" based on the "Project Number" and "table2" based on "ID" as just been generated and "table 3" which is based on "contact name".
So I want to pull information form the records based on the certain key fields but struggling for it to pull it successfully...
Got relationships between: "contact name" fields in both "table2" and "table3" "project number" fields in both "table1" and table2"
In a query for the report I have all the appropriate fields, but only have the "contact name" and "project number" from "table2" is this right? or do I need both in?
Or would it be easier to draw all this information into "form2" but don't really want to select that many drop down boxes or would it be able to pull it from the "contact name" and "project number" boxes????
I have a form (MemberDetails) and I want it to check if the member I'm adding has already been added, or at least give me a warning that the member might be a duplicate. I have a FName field and LName field that I would like checked (together). I know it's possible because I've seen it done on the Address Book template, but they have it set up to where the First & Last name are saved as one field in another table.
want my query to count only records that are not duplicated based on a set of criteria.I have a table with customer IDs and Call dates and the employee ID. I want a count of the call dates for each customer ID for each employee. However I only want to count as one occurrence if multiple calls happened on the same day. For example
I want to amend my query so that all duplicate records don't appear. For example when the query is run the information generated includes: Day the audit took place Room the audit took place in Faculty the activity belongs to Staff lecturer(s) who takes the class Activity that was going on when audit took place Start time of Activity Finish time of Activity Counted number of people in the room
Therefore, if there is an activity going on for a faculty but there is more than 1 staff name against it, I just want 1 record to appear against that faculty. Whereas what is happening for example is that there is a activity which takes place from 3pm to 4pm and the activity belongs to the Faculty of Computing and Engineering, and as the class was taken by 3 different lecturers, 3 separate records appear. I am concerned about this because the information is then used in a summary report for each Faculty for the year, so in this case the summary report will calculate 3 activities when it was just 1 activity.
It would be great if its something I could just amend in the query, and not in the source table.
I have a query that will pull records, and append them to the table. The only problem is that not only will it pull all the "new" records, but also all the "old" records. I just want to append the records that are not already in the table. Any ideas? I have tried using the primary key, but then it dosnt import any records. There will be say 1850 records. And out of the 1850, 1 would be a new record.
I have created a database which holds architectural drawings for my company. The drawings have a number (dwgNumber), a name (dwgTitle) and a revision (dwgRevision). Each number should only have one title but cannot be unique as they can have several revisions. I am looking for a way to allow the users of the database to only enter a drawing title for a drawing number once. This is because if more than one person is accessing the front end at a time, they may use the same drawing number for different drawings.
For Example:
----THIS IS FINE Number: A001 Title: Drawing 1 Revision: P1 Number: A001 Title: Drawing 1 Revision: P2
----THIS IS NOT OK Number: A001 Title: Drawing 1 Revision: P1 Number: A001 Title: Drawing 2 Revision: C1
Basically, each number can only have one title assigned to it.
I have a report to run that gathers info from three tables. If I make individual queries to get the information I need the three queries gather the correct information. If I make one query it makes duplicates. If I combine the three queries that work the main query mixes up the information and duplicates it. How do you make a query that gets information from three tables and not have it be garbled?
I need to count records based on multiple criteria from two different tables. I have two tables (i.e. "tblTasks" and "tblTaskHistory"). The tables have a one-to-many relationship based on the "TaskID" field. "tblTasks" has a field called "AssignedTo" and "tblTaskHistory" has a field called "TaskStatus". I need to know how many tasks have been "reopened", the "reopened" status is located in the "TaskStatus" field in "tblTaskHistory". I need this count against a unique listing of employees which can be found in the "AssignedTo" field in "tblTasks".
I have imported a large number of emails into a table tbl_requests.
I had intended to have unique file tbl_requests.date_opened unique, but have ended up with a lot of duplicate records (i.e. tbl_requests.date_opened is not unique !). How to delete any duplicates? I have 15,000 records...