i have some difficulties with an expression on appsheet: IF({[PRODUCT]=“539-10”},{CONCATENATE([MACHINE],"-",YEAR([DATUM]),"-",UNIQUEID())},{[MACHINE].[BATCH]})
it keeps giving the error: LIST has elements of mismatched types while the types of the columns are text.
is there someone with a solution?
Cheers, Valiant
@Valiant_Beekes why do you need the curly brackets in your expression? And where do you place this expression?
@Levent_KULACOGLU i assumed that it would me neccecery because there are multiple different elements in the expressions. the expression will be used in a form. if the product is 539-10 > a new batchnumber will be generated. else> the current batchnumber will be imported via the machine tab.
i just tried in Initial value. then the BATCH entry is visible. but the formula does not work (no initial values)
@Levent_KULACOGLU i’ve tried the new one. sadly does not work either.
@Valiant_Beekes it’s hard to say more without seeing your app and your gSheet structure
May be @Aleksi_Alkio might say more on this
@Levent_KULACOGLU thank you for the support. hopefully Aleksi Alkio can help me further
What happens if you try just [MACHINE].[BATCH] as an initial value?
Hi Val, you show curly brace brackets in your formula {
} .
Are you actually using these brace brackets?
IFS( [PRODUCT]=“539-10”,CONCATENATE([MACHINE],"-",YEAR([DATUM]),"-",UNIQUEID()) TRUE,[MACHINE].[BATCH] ) expression should do the trick
@Levent_KULACOGLU thanks for your input! unfortunately the trick does not work… i get the error: IFS function is used incorrectly:Inputs to IFS() must be one or more condition-value pairs.
Do apologize, forgot a comma : Now try it please…
IFS( [PRODUCT]=“539-10”,CONCATENATE([MACHINE],"-",YEAR([DATUM]),"-",UNIQUEID()), TRUE,[MACHINE].[BATCH] )
@Levent_KULACOGLU hi! thanks the expression! the error is gone. but the expression does not fill the cell and is not visible in the form… im sorry for the troubles
@Levent_KULACOGLU when i test the expression in the expression builder. the result is always “-”
@Valiant_Beekes can you tell me where explicitly you are trying to construct this expression? Initial value? AppFormula?
@Levent_KULACOGLU App Formula
Can you try this one?
IFS( [_THISROW].[PRODUCT]=“539-10”,CONCATENATE([_THISROW].[MACHINE],"-",YEAR([_THISROW].[DATUM]),"-",UNIQUEID()), TRUE,[MACHINE].[BATCH] )
User | Count |
---|---|
41 | |
28 | |
28 | |
23 | |
13 |