Forum Academy Marketplace Showcase Pricing Features

Field value that is a combination of other fields values

Hello, bubblers.
Let’s imagine that we have a Thing called “User” with two fields: Name and Surname (both with type “Text)”.
Now I want to make a third field called “Name+Surname” (I need it for Search Box element).

Example:

Name = “Andy”
Surname = “Warhol”
Name+Surname = “Andy Warhol”

Is it possible to realise? Can’t find any operations like “+” or “join”…

Hey @artemzheg :slight_smile: To accomplish this for the search box element, I think you would need to create a new field under the User for the Name + Surname value in order for that to be the Field to Search.

Alternatively, you can have an input and a repeating group beneath which looks + functions similarly to the searchbox element. This would allow you to Do a Search for Users in the repeating group with the constraint “Any field contains Input’s value”. If a User typed in Andy or Warhol, Andy Warhol would be shown in the repeating group (along with any other dynamic data you place in the cell). If Users have a biography text field, and someone typed in ‘artist’, Andy Warhol would be displayed since that would be in his biography text field.

Hi, @fayewatson. This is exactly what I would like to do. But I can’t find any operation for this (like “+”, ""join or “concatenation”):

I would create a new field such as “Full Name” (type: text, list: no) and then the value would be:

Full Name = Input Name’s value Input Surname’s value

(Making sure there’s a space between Input Name’s value and Input Surname’s value). That should do it! :slight_smile:

1 Like

There’s another “hack” specifically for the cases when you need to format the input, but the standard inputs fields do not give you that option.

There is a function of conditional formatting of inputs in Bubble that you can use for this purpose.
First, you need to find a condition that will always be = true.

Then you need to select "formatted as text:

And then, since the condition will always be True, you can use the proper multi-line input to concatenate values, and do much more.

Hope it helps!

Vlad.

GM at Bubblewits - Bubble Certified Partner


http://bubblestore.io – a place to buy Bubble templates for landing pages, e-commerce, workflows, APIs etc.
http://iambubble.com - one page Bubble demo
http://builtonbubble.com - Collection of apps built on Bubble

5 Likes

Oh, I use such variant to display data from several fields in one element, but I didn’t think it will work for saving data in DB. Thank you :slight_smile:

@vladlarin, thank you very much for this “bubble hack”, I’m sure I’ll use it for my apps!

3 Likes