Why do you post this question again? It has been answered (or at least responded to) 9 months ago …
I did not understand your previous answer, or was unable to make it work. I was looking for more information. Sorry.
1 of 1 people found this helpful
There are a couple of different ways to do this.
1) The "brute force" way would be to use an auto-enter / value from last record option:
You would need to script the move to the record you want the value from, enter a field to establish "last visited", then move back to the record you want to insert, then use either an Insert from Last Visited script step (for an existing record) or just create the new record.
2) A more elegant way would be to create a relationship from the table to itself, and sort that relationship based on whatever criteria constitute "prior record" (so that the "prior" record is always the last one referenced in the relational list). You can then simply use the table::field notation and insert the value directly into the field using Set Field.
3) You could also use ExecuteSQL if you really wanted to get fancy and didn't want to mess around with navigating between records or playing with your relationships. If you have a way of determining the "prior" record by some serial number or other sequential value that you could write into a query, just write the query to fetch that value and insert it.
Plenty of options. Just depends on how you want it to work.
I havn't had the time to work on this in 9 months. Again, sorry to bother you.
And now we have reached the blessed state of two threads with answers to the same question …
2) A more elegant way would be to create a relationship from the table to itself …
As has been described in that other post … That approach is of course problematic if you don't know how to create a relationship.
I guess I'm not that advanced.
The first method I don't think will work as the last time used for that axis may be twenty recods back when sorted normally by Console Number, Cue Number, Statement Number (the order in which each move staement appears in a cue).
Your other solutions I don't completey follow.
How do you determine which record is the “last” record? Is there a predictable pattern?
I set up a copy of the table that lists the axis move details. I then sorted that table decending, and defined relationships to the original table. The "lookup" works, but if I change the target position, the start position in the next use of that axis only updates when I select that record. Can I make that live updating somehow, so the change is automatic? Thanks for the help, and sorry if this seems basic or I seem unknowledgable.
Edit: I got it. Thanks for your help.