HELP - BOT - ACTION for deleting a row

Dear friends,

I need a help from this esteemed community for creation of bot and action for it.

I have table called Users and it has a [email id] as one of the column and [user name] is the key column for users table . I have another table called filter dashboard which has [email id] as key.

Note: [Filter id] in the filter dashboard table has email address. so I have mentioned in the above para as [Email]

Need : When a user is deleted from the user table, email id and its entire row should be deleted from filter dashboard table also.

I don’t know how to create an appropriate action and to configure the bot.

Things which I have done and that didn’t work,

Referenced row : select(filter dashboard[FILTER ID],not(in([FILTER ID],users[EMAIL])))

@AleksiAlkio , @Marc_Dillon @Suvrutt_Gurjar @WillowMobileSys @Aurelien @MultiTech

Please try below.

  1. Please hide the 'Delete" system action by enabling “Do not display” option on the Users table. Also make this action’s "Needs confirmation setting off.

  2. Please create a reference action (type : execute an action on a set of rows) called say “Filtered Dashboard User Delete” on the Users table with settings as

A. For a record of this table “Users”

B. Referenced Table" “Filtered Dashboard”

C. Referenced rows expression : SELECT(Filtered Dashboard[Filter ID], [Filter ID]=[_THISROW].[Email ID])

D. Referenced action : 'Delete" ( Select “Delete” system action of the “Filtered Dashboard” table.

3/ Create a grouped action on the Users table called “Master Delete” with suitable prominence as you want.

A. In this group action select “Filtered Dashboard User Delete” created in step 2 above as first action.

B. Select the “Delete” system action on the table Users as second group action.

  1. Now when the user executes the action “Master Delete” created in step 4, first the record from the “Filtered Dashboard” will delete, followed by the record from the Users table.

Sir, thanks… I can understand from your reply… That there is no bot involved. Can we do the same kind of process for adding an user ?

Can you elaborate what you mean by this? If you mean adding a record to the “Filtered Dasboard” table when a user is added to the User’s table, you could try an action type " Add a new row to another table using the values from this row" as an event action in the Users table’ s form save event.

Another way to simplify this could be to have “Filtered Dashboard” record as child record of the User’s table with “Is Part of” setting enabled in the reference column. Then whenever the User deletes the User table record , the child 'Filtered Dashboard" record will also be automatically deleted. In that case all these manually constructed actions are not required.

Another way to evaluate the requirement is , is the “Filtered Dashboard” table really required? Could you have those columns of user choices in the Users table itself? Any specific reason you have those two different tables?

1 Like

This Filter dashboard table is to generate user filtered PDF. This table helps to extract records from another table and it will be fed to PDF Report generation.

Okay, but in general it could be same as Users table, right? Can those choices be not included in the Users table itself?

It is not working sir.

I have done as per your instruction . please guide to achieve this.


I have several tables. User table, Consignment table, Filter dashboard table.

Filter dashboard table has the input for the filter criteria.

There is slice for consignment table with row fill condition ,that works Based on the Filter dashboard values( user input).

Earlier filter dashboard was working commonly for all user that has lead to the malfunction while 2 users use at same time . similar issue posted

So I want to create separate filter id for each user. creation of user is possible but while deleting , it could not be achieved.

User table comes into picture while adding and deleting the rows in the filter dashboard table.

Would it be just easier to use the Bot as in your original post? Then you can set the trigger as Deletes_Only. The Referenced rows could have a formula as LIST([Email ID]). That should be enough to find the correct row.

1 Like

I have doubt … This expression List ([EMAIL]) will delete the rows which is not in the users[email] ?

Do you have any other method, where bot is not involved like suvrutt sir method?

There is nothing wrong with the apporach Suvrutt proposed.

The LIST([Email ID]) reads the value from the record you just deleted and it converts it as a list. Because it only have one value, it finds that row from your other table and then that will be delete as well.

@jaichith : The reference rows expression proposed by Aleksi is a smarter way of getting the referenced rows. In your case there is only 1-1 relationship between two tables. So an expensive SELECT() is unnecessary, even though it sound a familiar format.

1 Like

@Suvrutt_Gurjar , @AleksiAlkio I have tried using both action method and bot with action method. both it did not work.

in automation manager it shows success :frowning:

Please check Audit History log for possible errors.

Success !! :frowning:

You said in the beginning “I have table called Users and it has a [email id] as one of the column”. You need to use that column with this LIST() that contains the value that is possible to find from the other table’s key column. If it’s not, the Bot won’t do anything as it doesn’t find any rows.

1 Like

Firstly, I have tried with the Action method insisted by @Suvrutt_Gurjar . I have changed the select expression with List ([Email]). It didn’t work.

Secondly, I have tried the action by attaching it to the bot. Even that also didn’t work.

Dear @AleksiAlkio and @Suvrutt_Gurjar can you please test this method at your end and convey about the viability to me because I have followed the instructions given by both of you but still efforts didn’t get success.

Hi @jaichith ,

Just to assure you, I always test before suggesting any substantial solution. :slightly_smiling_face: Otherwise those steps cannot be listed so much in detail.

As for Aleksi, please note that he is one of the senior most AppSheet experts and we keep learning many tips from from him. His solutions are always very practical.

Here are the screenshots o my testing before suggesting you. :slightly_smiling_face:

Were you able to test the Audit log history as requested?