FR (Retool Database) - Add 'Duplicate Row' to Actions

There's currently no way to duplicate a row from the GUI. To actually achieve this you have to create a new row and copy everything into the popup. This works, unless you have lots of columns since you can't scroll left/right while adding a row (the popup closes).... so the actual workaround, is to write down all the column values (or copy to notepad or whatever) then click 'Add Row' and fill out the popup.

If you convienetnly have a 3rd party IDE connected to your retool db you can run a query like:

INSERT INTO table_name(
  column_name1, column_name2
)
SELECT column_name1, column_name2,
  FROM table_name
    WHERE id=1;

or

INSERT INTO table_name
  SELECT * FROM table_name
    WHERE id = 1

It'd save a lot of time to just add a duplicate row button in this menu:

Hi @bobthebear!

Great request, totally understand and it sounds very reasonable.

So in your mind, a user would specify the row via ID or primary key, and then in a 'duplicate row preview panel' it would either auto increment the pkey/ID or without auto increment, the user would still need to enter in a value that isn't already taken by another row.

I can make a feature request for this now and will let you know if I hear any updates on that thread!

1 Like