Results 1 to 6 of 6
  1. #1
    Join Date
    Jan 2010
    Posts
    4

    Unanswered: Former Filemaker User

    Hi All,

    I have used Filemaker a fair bit and am now starting to learn Access. I need some advise on creating the following:

    I have a table called 'flights' which contains ID and 'flightnumber'

    I have a table called 'passengers' which contains ID and 'passengername'

    I need a form which shows the flight, with a subform showing the passengers on that flight. I need to be able to enter the passengers in the subform and have them allocated to that flight.

    Hope that makes sense.

    Cheers

  2. #2
    Join Date
    Oct 2009
    Posts
    340
    I would rename ID to FltID

    if the passenger table has the FltID & passenger name - - then that is a cross referencing field and it will be really simple...

    make a main form sourced on your flights table; then iinsert a subform into it that is another form sourced on the passenger table - - the wizard will step you thru it...

  3. #3
    Join Date
    Jan 2010
    Posts
    4
    Thank you.

    Earlier I created just as you suggested with a FlightID in the passenger table. Using the Form wizard I created a form based on the flight, with a subform shownig the passengers in a datasheet. The problem was when I enter a new row in passengers it doesn't automatically assign the FlightID and they therefore do not appear in the datasheet.

    In Filemaker, it would be called 'Creating a record in a related table' but I can't work out how Access would achieve this.

    Cheers

  4. #4
    Join Date
    Oct 2009
    Posts
    340
    it should.

    if one inserts a subform into a form; the wizard will prompt for the cross referencing field between the two - and assuming you enter it - then whenever you add a record to the subform the cross referencing value is added automatically...

    doublecheck by trying again.

  5. #5
    Join Date
    Jan 2010
    Posts
    4
    Hey thanks, it is working now.

    How can I set it up so when I delete the parent record it deletes the linked subform records at the same time?

    Don't want to be a pain, just Access has a signifcantly different workflow to Filemaker

  6. #6
    Join Date
    Aug 2009
    Location
    Up Nort' Wi
    Posts
    140
    In the relationship design window, put a check next to "Cascade Delete" under "Enforce Referential Integrity".

    That should do the trick for you.

    Sam
    Good, fast, cheap...Pick 2.

Posting Permissions

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