Thore
June 9, 2024, 1:12pm
1
Hi
I want to create a form where user can registered multiple items and upload attachments.
form as a table:
example:
Is this possible in retool?
Or user upload attachments for all rows.
button to add empty rows.
If user start typing in name and nickname retool show posible names registered. same as google search field:
Is this possible and are there any one that can help a new Retool user with minimal coding knowledge and no javaScript experience.
I would greatly appreciate it if someone will help me with this request form.
Paulo
June 25, 2024, 9:55pm
2
Hi @Thore , this should be possible with Retool. Let's start with the column with a dropdown:
If we use the "Tag" column format:
And then make the column editable:
We can set the Options we would like:
They can be manually entered:
Or set to the output of a query. For example, all the names of the users in a database table:
This is how that would look once the users edits it:
Should work like the example you shared:
To add rows, we can edit the Toolbar options:
Enable Add Rows:
That will add the +
button to add rows to the table. Keep in mind that we will need to make all columns editable in order to use this feature:
This is all at the component level, the rest would be creating the queries to save your data on a database. We highly recommend using RetoolDB, specially if you would like to use the UI instead of writing raw SQL code.
Here are a few resources to work on your queries:
I am trying to Bulk insert records from a table but the column names from the table need to be inserted into columns in my MySQL db with names which are different.
The logic is below:
INSERT INTO Tbl_samples (Sample_ID, Date_Sampled, Easting_m, Northing_m, Elevation_m)
SELECT
item.Wpt_SampleID AS Sample_ID,
item.Date_taken AS Date_Sampled,
item.Easting AS Easting_m,
item.Northing AS Northing_m,
item.Elevation_m AS Elevation_m,
FROM
(SELECT * FROM {{table1.data}}) AS …
Happy building!