Results 1 to 6 of 6
  1. #1
    slimjen is offline Expert
    Windows XP Access 2007
    Join Date
    Mar 2010
    Posts
    727

    table design

    all. using access 2003. I created a database with 3 tables ive been struggling with. I also created a form with 2 subforms. The main table consist of the invoice id(pk) and invoicenum(text field no dups). The second table consist of tracking id(pk), trackingnum (text field no dups) invoicenum(not indexed)(from invoice table 1:many). Third table AcctID(pk), trackingnum(from tracking table 1:1) Cost field, AccountCode.
    For every invoice you can have many trackingnum.
    For every trackingnum you can have 1 acctid.
    The main form conisist of a combo box with Invoicenum. ; i've created a tracking subform so When users select the invoicenum all the cooresponding tracking numbers are listed in datasheet. So far everything was working until I tried to add the accounting info. It needs to show in the 2nd subform one tracking number to one acct info. I can only get info in datasheet form with multiple tracking numbers. it doesnt cooresponding to a single record. I ve seen it done in ex. use cust, order and product tables but I cannot get it. Please help!

  2. #2
    June7's Avatar
    June7 is online now VIP
    Windows XP Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    53,640
    Probably the query jointype needs to be changed. Can you provide the project for analysis? Make copy, remove confidential data, compact & repair, zip if still large.
    How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.

  3. #3
    slimjen is offline Expert
    Windows XP Access 2007
    Join Date
    Mar 2010
    Posts
    727
    Sorry; thought I attached a database. I am think the accounting table info needs to be combined with the shiptment table because the accounting table only provides additionas detail info. Can I exclude the accounting info from the subform and have it on the same form referenced back to the subform somehow? Please take a look and let me know.
    Thanks

  4. #4
    June7's Avatar
    June7 is online now VIP
    Windows XP Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    53,640
    When opening frmSMALLPACKAGEFORM, got parameter prompt. Found it in the OrderBy property of Shipment subform and removed the SQL statement.

    The jointype in Relationships for tbl_SP_SHIPMENT and tbl_SP_ACCOUNTING is 'Only...', in the qrySHIPACCT it is 'Show all from tbl_SP_SHIPMENT...' but that's probably not an issue.

    Do you want the Accounting subform to show record that relates to the selected tracking number record in the Shipment subform?
    How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.

  5. #5
    slimjen is offline Expert
    Windows XP Access 2007
    Join Date
    Mar 2010
    Posts
    727
    yes. This is my issue. the accounting subform is not displaying the record that relates to the tracking number record. when I select the tracking number it tells me it will duplicate record. not trying to create recrd.thks

  6. #6
    June7's Avatar
    June7 is online now VIP
    Windows XP Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    53,640
    Then Accounting subform is dependent on the Shipment subform record, linking on the tracking number. I know how to do a form/subform/subsubform arrangement. Getting a subform to link sideways to another subform is not easy. Only seen it once. Can't find it now and not having luck on my own. Here is possible solution to sideways link http://www.access-programmers.co.uk/...ad.php?t=45857 and http://www.fmsinc.com/microsoftacces...edsubforms.asp
    Also, these subforms do not need to include table joins. Just set the RecordSources to the tables, use the OrderBy property
    How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.

Please reply to this thread with any new information or opinions.

Similar Threads

  1. please help to design a table
    By oas in forum Database Design
    Replies: 3
    Last Post: 02-11-2012, 08:54 AM
  2. Table design
    By eacollie in forum Database Design
    Replies: 5
    Last Post: 06-21-2011, 03:33 PM
  3. Need some help on table design
    By stryk9 in forum Database Design
    Replies: 1
    Last Post: 03-07-2011, 06:35 AM
  4. Table design and relationships
    By CoachBarker in forum Database Design
    Replies: 1
    Last Post: 10-01-2010, 11:22 AM
  5. table design: one big table vs. multiple small tables
    By lstairs in forum Database Design
    Replies: 3
    Last Post: 12-31-2009, 08:46 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Other Forums: Microsoft Office Forums