Relational database Access/Infopath - InfoPath Dev
in

InfoPath Dev

Relational database Access/Infopath

Last post 09-25-2009 07:49 AM by Hilary Stoupa. 5 replies.
Page 1 of 1 (6 items)
Sort Posts: Previous Next
  • 09-18-2009 11:53 AM

    Relational database Access/Infopath

    I have an Access 2003 database linked to Infopath 2003 and I have the following relationship.  Unit tbl has many Employees(EMP tbl). The Unit # is the Primary Key and the EMP tbl has the EMP # as the Primary Key and the Unit # as the Foreign Key. I have both tables linked in the InfoPath form. My question is the following.  I have a repeating table set up and I want to make chances to the Unit for each employee as they move from one department to another. How do I accomplish that? I keep getting this "unable to submit error." Something like "Cannot submit blank row..."  

    Can anyone advice on the best approach to setting up this relational database. I'm so close to just going with a single EMP table and fighting it out with queries at the end of the day.

     

  • 09-20-2009 07:28 AM In reply to

    Re: Relational database Access/Infopath

    So is the Unit to Employee relationship one to many? When you set up the main data connection in your form, are you setting the Unit table to not be repeating?

    Hilary Stoupa

  • 09-21-2009 07:03 AM In reply to

    Re: Relational database Access/Infopath

    It's a one to many relationship(Unit-EMP table). I have both tables linked properly in the form. I just don't know how to set up form so I can update the unit of an employee as he/she moves around units. I believe the EMP table should be repeating since I want to update many records.

  • 09-21-2009 09:04 AM In reply to

    Re: Relational database Access/Infopath

    It sounds like you have it set up correctly. What is the exact error you are getting?

    Hilary Stoupa

  • 09-21-2009 09:22 AM In reply to

    Re: Relational database Access/Infopath

    I'm not getting a particular error per say. I just don't know what is the simplest way to be able to track the changes in the employee table such as when an employee changes office, department, name or unit. Basically I need to track the historical data for the Employee table. So now that I think about it, the EMP table should be the primary table and a historical EMP table (child) would be the repeating table.  

    Hilary, you seem to know InfoPath well :). He's a question: Is there anyway I can have a main EMP table with EMPID (primary key) and have an EMP History table with RecordID (primary key) and EMPID( foreign key) and when I submit a change in the main EMP table a new row is copied in the EMP History table? Is this something I need to do in Access or can I do this in InfoPath?

     

  • 09-25-2009 07:49 AM In reply to

    Re: Relational database Access/Infopath

    I don't think you would be able to do this with out of the box InfoPath functionality. I don't believe that Access has triggers -- SQL Express does, I think, and it is free. You might want to consider moving your DB to SQL. Because, really, a trigger would work nicely for creating a history table.....

    Hilary Stoupa

Page 1 of 1 (6 items)
Copyright © 2003-2019 Qdabra Software. All rights reserved.
View our Terms of Use.