Results 1 to 8 of 8

Thread: [RESOLVED] ms access 2000 - query to write info to 2 tables

  1. #1

    Thread Starter
    Addicted Member
    Join Date
    Dec 2004
    Posts
    128

    Resolved [RESOLVED] ms access 2000 - query to write info to 2 tables

    I am trying to do a query and it is not working out right. I have 4 tables. 2 tables hold static data for the user to select from on the form. I want to split this data and instead of it writing to one table which it is now. I want it to write to 2 different tables. 1 from one table and one from the other. So two tables as control source and 2 tables as Row source. I have tried to do this in a query but it's not right. I think I may be doing my Relationships wrong. Can someone help?

  2. #2
    PowerPoster Static's Avatar
    Join Date
    Oct 2000
    Location
    Rochester, NY
    Posts
    9,390

    Re: ms access 2000 - query to write info to 2 tables



    try explaining that one again... im confused
    JPnyc rocks!! (Just ask him!)
    If u have your answer please go to the thread tools and click "Mark Thread Resolved"

  3. #3

    Thread Starter
    Addicted Member
    Join Date
    Dec 2004
    Posts
    128

    Re: ms access 2000 - query to write info to 2 tables

    Here is a portion of the data base.

    I am wanting

    Form write 2 to tables to be able to read from tables TblCabin and TblVendor and write the data that is selected to TblwrCabinName and TblWrVendorName


    Change the file to .mdb to convert it back.
    Attached Files Attached Files

  4. #4
    PowerPoster Static's Avatar
    Join Date
    Oct 2000
    Location
    Rochester, NY
    Posts
    9,390

    Re: ms access 2000 - query to write info to 2 tables

    still confusing.. u want the user to be able to pick 1 from each table.. then

    write the choices to TblWr tables with linkable ID's??
    JPnyc rocks!! (Just ask him!)
    If u have your answer please go to the thread tools and click "Mark Thread Resolved"

  5. #5
    Frenzied Member
    Join Date
    Feb 2003
    Location
    Argentina
    Posts
    1,950

    Re: ms access 2000 - query to write info to 2 tables

    I think what he wants is an INSERT query that inserts data to two different tables.
    Tengo mas preguntas que contestas

  6. #6

    Thread Starter
    Addicted Member
    Join Date
    Dec 2004
    Posts
    128

    Re: ms access 2000 - query to write info to 2 tables

    The id's doesnt matter they are there just to give each a unique identifier.

  7. #7

    Thread Starter
    Addicted Member
    Join Date
    Dec 2004
    Posts
    128

    Re: ms access 2000 - query to write info to 2 tables

    I really dont know any other way to explain what I am needing

  8. #8
    PowerPoster Static's Avatar
    Join Date
    Oct 2000
    Location
    Rochester, NY
    Posts
    9,390

    Re: ms access 2000 - query to write info to 2 tables

    well i think u are making it too complicated...

    Create a form

    ad a combobox.. tell the wizard: look up values, pick the table, pick the field
    Repeat and pick the other table and field...

    Add a command button
    command button code

    Docmd.RunSQL "INSERT INTO TblwrCabinName (Cabinname) VALUES ('" & combobox1.value & "')"
    Docmd.RunSQL "INSERT INTO TblWrvandorname (Vendorname) VALUES ('" & combobox2.value & "')"
    JPnyc rocks!! (Just ask him!)
    If u have your answer please go to the thread tools and click "Mark Thread Resolved"

Posting Permissions

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



Click Here to Expand Forum to Full Width