Understanding backend functions

Hello. I'm having a lot of trouble understanding what each function in Bankend does. I'm used to other frameworks having documentation called 'Help' where we can see what each function does, its return values, and even examples.

I'd like to know two things initially:

  1. Does this documentation exist?

  2. If it doesn't exist, can someone tell me what these functions called 'Data Transformations' do? (Note: I tried testing after a server action (select) but unfortunately nothing made sense.)

You can find the docs about data transformation actions here, in the docs category:

1 Like

I apologize for seeming like I didn't search, but I did and couldn't find it, which is why I opened the help section. The language barrier is hindering me quite a bit when using a translator.

I think I found my problem; I was trying to directly manipulate a Database Select, and from what I saw, it only works with array return types!

Would that be it?


Sorry i don't understand what you mean here?
Maybe explain what you are trying to achieve?

This was just a test.

But the result I'm looking for is to be able to manipulate this result (select) in the backend before sending it to the frontend. For example, I'd like to filter the items in a specific field from this return and then manipulate it.

In this case, the test I sent was to understand the function's process, but it had no effect on a Database return, as shown in the image I sent.

These actions don't affect the database query itself. They manipulate the query results. So they take the array returned by the database query and manipulate it. You can see the results they return AFTER the query step, when you enable output for them.
It's all explained step by step in the docs i sent you.

I think I understand the mistake I made...sorry.

The function doesn't have an output checkbox, and I didn't realize I can exit by clicking above.

The confusion was mine! I'll get used to having the checkbox to mark it as output. Thank you.

Now getting to what I need.

In the 'add columns' action, can I perform a validation by retrieving the index of the iterated array?

I'll be more specific.

The database query returns...

{
"query_lista_recorrencia": [
{
"cliente_nome": "THIAGO TONELI",
"cliente_cpfcnpj": "21963044843",
"produto_descricao": "TAJPDV PDV+",
"valor": 169,
"dta_inicio": "2026-01-04",
"dta_primeiro_fatu": "2025-12-16"
},
{
"cliente_nome": "ANA PAULA PARRA TONELI",
"cliente_cpfcnpj": "35898652884",
"produto_descricao": "LINK PRO",
"valor": 250,
"dta_inicio": "2026-01-04",
"dta_primeiro_fatu": "2026-01-16"
}

I would like to add a column called 'proportional' validating the value of 'query_lista_recorrencia.dta_primeiro_fatu' == '2026-01-16'

if it is true, return 'ok', otherwise return empty.

To do this, in the 'Add Columns' function I put 'Collection' and 'query_lista_recorrencia', in 'Name' I put 'proporcional' and in 'Value' I put this ternary statement ''query_lista_recorrencia[$index].dta_primeiro_fatu=='2026-01-16'?'ok':'' in order for it to validate the index of each array, but it didn't (I'm not saying it should, I was testing it).

I did another test pasting this sentence into 'Value': ''query_lista_recorrencia[0].dta_primeiro_fatu=='2026-01-16'?'ok':'' and ''query_lista_recorrencia[1].dta_primeiro_fatu=='2026-01-16'?'ok':''

The ''query_lista_recorrencia[0].dta_primeiro_fatu=='2026-01-16'?'ok':''


returned

"set": [
{
"cliente_nome": "THIAGO TONELI",
"cliente_cpfcnpj": "21963044843",
"produto_descricao": "TAJPDV PDV+",
"valor": 169,
"dta_inicio": "2026-01-04",
"dta_primeiro_fatu": "2025-12-16",
"proporcional": ""
},
{
"cliente_nome": "ANA PAULA PARRA TONELI",
"cliente_cpfcnpj": "35898652884",
"produto_descricao": "LINK PRO",
"valor": 250,
"dta_inicio": "2026-01-04",
"dta_primeiro_fatu": "2026-01-16",
"proporcional": ""
}

and when I used ''query_lista_recorrencia[1].dta_primeiro_fatu=='2026-01-16'?'ok':''


returned

"set": [
{
"cliente_nome": "THIAGO TONELI",
"cliente_cpfcnpj": "21963044843",
"produto_descricao": "TAJPDV PDV+",
"valor": 169,
"dta_inicio": "2026-01-04",
"dta_primeiro_fatu": "2025-12-16",
"proporcional": "ok"
},
{
"cliente_nome": "ANA PAULA PARRA TONELI",
"cliente_cpfcnpj": "35898652884",
"produto_descricao": "LINK PRO",
"valor": 250,
"dta_inicio": "2026-01-04",
"dta_primeiro_fatu": "2026-01-16",
"proporcional": "ok"
}

that is, it validates the index in the ternary condition, but I don't know if it's possible to dynamically retrieve the index from the routine.

Did you understand?


I got the expected result using this method.

thanks