Forum Academy Marketplace Showcase Pricing Features

Generate a new row when a new user inputs something

I’ve set up a new data type called ‘actions_for_sc’.
I’d like the user to be able to edit a field on it called ‘title’ when they click a button.

I’m able to get it to be edited…

…but it only edits the row that’s already there.

What do I have to do to have a new row appear (and the ‘title’ field to be filled in) when a different user clicks the same button? Sorry for the stupid (probably) question —it’s so much easier when the data type is just the built-in ‘User’, because it automatically creates a new row when a new user signs up.

I’m not completely clear on what you are trying to do but you either need to ‘Create a new actions_for_sc’, add a constraint on your search to modify the correct ‘actions_for_sc’, or make the title a list of texts so it will add a new entry in addition to any already there.

Hi; thanks for your reply.
Imagine my database only consisted of the data type ‘User’. Then I could use “make changes to thing” > “Current user” > “[name_of_field]” and everything would be super easy because any changes to “[name_of_field]” would go into a different row according to the user logged in at the time.

The problem is that I have chosen to make a new data type called ‘Actions_for_sc’. It seems that, now, complexity goes through the roof when trying to do exactly the same thing.

Am I just not seeing something obvious?

Does each User have their own actions_for_sc? Or are you not even using the data type User?

I am using the ‘User’ data type—it’s for information about users.
But I’d like a separate data type for activities that those users can do.
However, some users are administrators, so those users can access a page on bubble to add/modify information about those activities. Maybe that’s where the problem lies, and I should be relying exclusively on the ‘User’ data type?
PS “Does each User have their own actions_for_sc?” The answer is no — I don’t know how to set that up.

No, you just need to add a field to User that links their specific actions_for_sc OR add a field to actions_for_sc to link the User. That way when you say make a changes to thing and select actions_for_sc, you can add a constraint that its user = Current User and then it will only edit theirs. Alternatively if they do not have one then on the same workflow you can say if the search for their actions_for_sc is empty then create a new actions_for_sc.

I understand; thank you. I think for the moment I’m going to simply stick to the User data type even if it ends up having 40+ columns. Thank you very much for your help!

Take a look at my Workflow Button Test is clicked and the Database

That makes sense; thank you very much.