Trigger after update' ... how to self reference multiple choice and add record to another table...
Hello my Ninox peeps: I have a music database for tracking recordings (see image 1 for schema). I have a processing table which has a multiple choice field (see image 2 for fields). I would like to script an action to create a new record in the repository table from the processing table (no dependence). How do I reference self in the Trigger after update script of the multiple choice?
Also, when I create the new record in the repository table, I need to assign the album Id which I grab from the processing table as:
myAlbumID := number(album);
or
myAlbumID := album;
Which is correct (if either)?
IMAGE 1
IMAGE 2
5 replies
-
Perhaps someone can explain me how to upload the images properly. Thanks!
-
-
Dear Lexi,
That would be a good question for our webinar and it would be nice if you could bring it up there.
Thank you very much.
At our Ninox webinar tips and tricks will be presented in the first 30 minutes, the remaining 90 minutes will be used for a live support where the participants' concerns will be solved.
You can register here for the webinar, which takes place every Tuesday at 18 o'clock CEST: https://zoom.us/webinar/register/WN_zoSk2qyNSz6vLRFF1zlakg
Best regards, Jörg
-
Thanks, Jörg. I will try to make the webinar and ask about this.
//alex (lexi)
-
Until you are able to join the webinar, you might want to try this... In the "Trigger after update" of the processing table you would enter...
let t := this;
create repository;
last(select repository).(AlbumID := t.album)
I'm not sure if you want to assign a text value from your processing table to your repository table, but that is what the code above does.
Content aside
- 5 yrs agoLast active
- 5Replies
- 2939Views