Results 1 to 7 of 7
  1. #1
    4 Star Lounger
    Join Date
    Apr 2001
    Location
    Guatemala City
    Posts
    515
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Update problems with junction table (Win XP Access 2003)

    I have a db with two tables, tblClientes and tblQuejas, joined with Junction in qryClientesFrm. These are used in frmClientesNvo to add new quejas. frmClientesNvo only shows the records from tblClientes if there is a matching record from tblQuejas. I need to be able to add new quejas to records in tblClientes which, at the moment, do not have a queja. A record in tblClientes may have multiple records in tblQuejas.

    In the query, when I changed the property of the relationship between tblClientes and Junction to the second alternative, include all records from tblClientes, the query does not run.

    Help! I am enclosing a copy of the db.
    Attached Files Attached Files

  2. #2
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts

    Re: Update problems with junction table (Win XP Access 2003)

    You should remove Junction and tblQuejas from qryClientesFrm - you only need those for the subform, not for the main form.
    And you should remove tblClientes and tblProyetos from qryClientesFrmSub - you only need those for the main form, not for the subform.
    The main form and subform should be linked on IDCliente only, not on IDCliente and NumForm.

  3. #3
    4 Star Lounger
    Join Date
    Apr 2001
    Location
    Guatemala City
    Posts
    515
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Update problems with junction table (Win XP Access 2003)

    Getting close. When I add a new record, it does not update the Junction table. The record is correct in tblQuejas. Where do I update the Junction table?

  4. #4
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts

    Re: Update problems with junction table (Win XP Access 2003)

    In qryClientesFrmSub, try using the fields IDCliente and perhaps NumForm from Junction instead of from tblQuejas.

  5. #5
    4 Star Lounger
    Join Date
    Apr 2001
    Location
    Guatemala City
    Posts
    515
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Update problems with junction table (Win XP Access 2003)

    The field IDCliente is not available from the Junction table. I am lost.

  6. #6
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts

    Re: Update problems with junction table (Win XP Access 2003)

    See the attached version. I removed the IDCliente field from tblQuejas, and used the IDClienteIden field to link the subform to the main form. Does this do what you want?
    Attached Files Attached Files

  7. #7
    4 Star Lounger
    Join Date
    Apr 2001
    Location
    Guatemala City
    Posts
    515
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Update problems with junction table (Win XP Access 2003)

    OK. We are there. Thanks.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •