Jump to content
Claris Engage 2025 - March 25-26 Austin Texas ×

Selection Portal to Create New Related Record


This topic is 6907 days old. Please don't post here. Open a new topic instead.

Recommended Posts

  • Newbies
Posted

I have an orders database that I am attempting to set up. There are three related tables that seem relevant to the problem.

Inventory --- Contains data about all items which can be ordered.

Orders --- Contains data about each specific order. each order can contain multiple items.

OrdersLineStorage --- Acts as a join table between Orders and Inventory.

I'm trying to do the following things...

1) Enter basic information about an order.

2) Select an item or items to add to the order using a portal which shows only items from inventory with the same brand as specified in the basic order data.

3) Add the selected item(s) to the LineStorage table by clicking a button and having a script which would auto populate the fields including Qty, ItemID and OrderID.

When I do this, it creates a new record in LineStorage, but does not transfer all the appropriate fields.

Any ideas on what I am missing?

Thank you in advance,

Korbin

diagram.pdf

orders2.zip

  • 1 month later...
Posted

One problem is that ORDLS_fk_OrderID is not getting set, thus no related records show up for you. Options include (a) setting your ORDLS fields from the Orders layout, which allows creation of related records, or (: setting that field as part of your script. If you choose (:, recognize that changing layouts in a script also causes FileMaker to change found sets -- it will not 'remember' the INV_pk_LineID you chose when you were on the Orders layout. So to set a field with that value after changing layouts you either need to pass it as a script parameter, or store it in a global.

I strongly recommend investing time finding example order/inventory files on this site and others, and examining their internal workings, so as to gain more familiarity with FileMaker.

This topic is 6907 days old. Please don't post here. Open a new topic instead.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.