Search results

  1. K

    Using DMax Function in a query

    I am thoroughly confused now. It still has duplicate entries for all employees that have transferred jobs and it has a number in the query that I don't know where it came from.
  2. K

    Using DMax Function in a query

    I had played around with the method on your website but I'm afraid I didn't quite understand it to get it to work correctly. So what you have wrote would go in the critera of EmpInfoID or a separate field?
  3. K

    Using DMax Function in a query

    Ok, after spending more time researching I think I understand. I have played around with the query and get it to pull certain records but I can't get it to do what I want it to do. I am looking for the query to return the largest/highest number for an employee ID. For example, an employee...
  4. K

    Using DMax Function in a query

    Would the string criteria be Me.EmpInfoID? I am having a hard time understanding what the last part is. It is still giving me an error too in the query with the Expr1: column for the DMAX function as well. If I'm understanding correctly (and I'm probably not) is in the criteria of the...
  5. K

    Using DMax Function in a query

    So I need to have 2 queries and then join them. How do I get it to look at an autonumber? The field that I need is set up as an autonumber. I guess I'm confused on what to call it in the syntax. I am still fairly new at writing codes for queries. Thank you!!!
  6. K

    Using DMax Function in a query

    I am having trouble getting DMax Function to work in a query. I am looking to pull the most recent ID for one table. The DMax function will be used in 2 queries. Currently this is what the query looks like without the DMax function: SELECT tblEmp.EmployeeID, tblEmp.EmployeeName...
  7. K

    Issue with Report and Table set up

    Ok. I will give that a try.
  8. K

    Issue with Report and Table set up

    Ok, I am having a tough time figuring this out. I'm not sure how the DMax function would work in here. The table the query is using already has an autonumber for its PK and then looking at the first link from Allen Browne, I see how that would work but not exactly sure how to get it to work...
  9. K

    Issue with Report and Table set up

    Ok, I will play around with this and see if I can't get it to work. I will post if I have more issues! Thank you so much!!
  10. K

    Issue with Report and Table set up

    I did read through the link. I am a little unsure of how to do it as I am still a beginner writing code and such. Do I have to have a field in the actual table to use the DMax() function? How does it know which entry is the most recent?
  11. K

    Issue with Report and Table set up

    For the purposes of the OSHA report and Licensing Log reports/queries I would like to see the current job (when the employee is active) so the most recent entry for the employee. Currently for these reports I have spreadsheets that I use but since I have to run a separate report through our...
  12. K

    Issue with Report and Table set up

    Yes, I have the form set as data entry but it only shows one record at a time, I can't scroll through the records for each EmpID. I think the records are editable as of right now though. I don't want the records to be overwritten. I would like to be able to pull the employee and see the jobs...
  13. K

    Issue with Report and Table set up

    The issue is the query/report qryOSHAJob/rptOSHAJob. It is based tblEmp, tblEmpInfo and tblOSHA. The issue is when tblEmpInfo has more than one entry for an employee it displays both, not the most current entry. I want to be able to see a history of jobs but also only see the most current...
  14. K

    Issue with Report and Table set up

    I have attached the zipped file for my database. I am having an issue with one my reports, qryOSHAJob. If I have an active employee transfer to a new job, it still has a record that shows up where the employee is before. Currently I have the table set up only to collect job information if...
  15. K

    Pop up table

    I have attached the relationships to the tables. I have a code behind that as well: Private Sub EmploymentStatus_AfterUpdate() If Me.EmploymentStatus = "Active" Then Me.tblEmpInfo.Visible = True Else Me.tblEmpInfo.Visible = False End If End Sub Private Sub Form_Current() If...
  16. K

    Pop up table

    Not exactly. This table the records are entered through a pop up form. The form pops up and the data is entered if another field in the main form (based on another table) contains certain information. For example the form is based on the field EmpStatus. If EmpStatus = "Active" then the...
  17. K

    Pop up table

    I have a table that stores records based on a field in another table/form. Because this field changes multiple times I always want the most current entry in the pop up table/form. How would I got about making sure when I run queries/reports that only the most current data is taken from this...
  18. K

    form is overwriting table info

    I figured it out. Allow Data Entry was set to "No". I missed it! I allowed data entry and hopefully it will work. I am attempting entry now.
  19. K

    form is overwriting table info

    Yes, OSHAByJob is a subform. Would I put the same code in for that that you put in below? It is not frmOSHA that is giving me trouble, it is the pop up form that relies on EmployeeStatus = "Active". Thank you!
  20. K

    form is overwriting table info

    It is the form that pops up when the employee status is active. It is form Employee Entry and the pop up form is OSHA by Job. Thank you!
Back
Top Bottom