Dear all,
I can't seem to solve this alone and kindly request your help. To easily manage the pdf files generated by automation, I am building an expression for the File Name Prefix that includes the key of the table that the bot queries in the event definition. It is an email address and the column is called [Email] while the table is called "employee". To get the full picture, the pdf creation task of that same bot works against another table, called "expense", which also contains an [Email] column, which is a Ref type to the "employee" table. Here is the formula, plain and simple:
CONCATENATE("NDF-",TEXT(TODAY(),"yyyymmdd"),"-",[Email])
But rather than generating NDF-20230822-xxx.yyy@mycompany.com.pdf (I ticked off the automatic timestamp), I am getting NDF-20230822-xxx yyy.pdf with xxx yyy being the first and last name associated with the email. I have toyed with some workarounds in the expression like "<<[Email]>>" and TEXT([Email]), and also with the position of the Email in the formula, but to no avail.
I initially thought it was due to the [Email] column being marked as PII, but I checked that off in both tables. I also thought that it was caused by the table label, which was indeed a column with first and last name, but I now have both the key and the label attached to the same [Email] column. I have re-generated the tables, deleted the task and created a new one, etc. Oh and I have also tested the expression with the Test feature in the expression window, and I do get the proper output! So I just can't figure out why the key value is replaced by something else.
Thanks a lot for your help!
Cheers
Solved! Go to Solution.
Dear Aleksi,
Hurray, I found my mistake. While I was using the "employee" table as the scheduled event trigger ("What table to query?"), I was using the child "expense" table to run the task of creating a new file ("What entity table does this task work against?"). By selecting "employee" as well for the latter, everything worked!
It's a wonder how everything else worked just fine except for that expression... I don't understand why the same table is automatically selected by default.
Thank you again for your persistence!
Cheers
User | Count |
---|---|
16 | |
15 | |
4 | |
4 | |
3 |