Help with dynamic commands

I need to put together an informative template for the sales team.

I have a building and within it there are different categories of apartments.

I needed to create a text where if I selected building X, this entire list of apartments would appear and not just one apartment.

My attempt fail:

For monthly properties {=property}, we have the following categories {if: property = "San Fran"}{=name}{endif}.

Hi @Contato_360_Suites Welcome to the forum! :slight_smile:

Can you share the full list of categories and of buildings, and give an example for a specific building?

Example: If the 360 ​​Se property is selected within my snippet, it will pull all categories related to it.

Thanks for the example. Here's an example snippet that you can copy and start using:

Let me know if it works for you.

2 Likes

It worked, but to a certain extent, because in this case I used more than just one column, and when I used the {endrepeat} command, I was duplicating my entries.

Select property: {dbselect: SELECT Propriedade FROM Table; space=0rTsvJIAG84gs6CNXsn8iA; menu=yes}{dbselect: SELECT Categoria, `5% OFF NO CARTÃO - ATÉ 15 DE OUTUBRO`, Propriedade FROM Table WHERE Propriedade = @propriedade; space=0rTsvJIAG84gs6CNXsn8iA; multiple=yes; menu=no}

List of categories is: {repeat: for item in categoria} {repeat: for category in `5% off no cartão - até 15 de outubro`}
{=item} {=category}

{endrepeat}
{endrepeat}

Does something like this work for you?

Select property: {dbselect: SELECT Propriedarde FROM `Community-Properties` GROUP BY Propriedarde ORDER BY Propriedarde ASC; space=id; menu=yes; multiple=yes}

{repeat: for item in propriedarde}
{dbselect: SELECT Categoria FROM `Community-Properties` WHERE Propriedarde = {=item}; space=id; multiple=yes; menu=no}
List of categories for {=item} is: {repeat: for item in categoria}
{=item}
{endrepeat}
{endrepeat}

Not exactly like that, in addition to the category I would also need to determine the price of each of these units.

Can you please share a Data Blaze space with example data and also example for this cost unit?

I'm going to share my spreadsheet with you, I would need something like this:

"The {property} has the following categories:

{category} worth {price}."

However, the "category" and "price" are lists, so I would need to get the entire column.

Hello, please let me know if this works:

You can also use {=join(preco, ", ")} instead of {=join(preco, "BLAZE_AND")} to separate the prices differently if you don't want it to say "2306" and "2306"

1 Like

Thank you Dylan, this format worked for me, but I needed it to only display one line value

Example:
The 360 ​​Sanfran has the following categories:

  • SF Studio 25CF.2Q worth 2306

  • SF Studio 25CG.2Q worth 2308

Hi,

Does something like this work for you:

1 Like

image

It's close, the ideal would be to be able to do it like this:

The 360 Sanfran has the following categories:

  • SF Studio 25CF.2Q worth 2308
  • SF Studio 25CG.2Q worth 2140
  • and follow this sequence

Try this:

Here's a slightly more robust version of Dylan's example:

Thank you guys, you were able to help me with my needs, thank you for everyone's support, attention and dedication!

2 Likes