JESUSCRUZ
2 years agoQrew Member
Can I store an if evaluation in a variable?
Hello community,
What I am trying to do is the following:
I have a main table that I use to build reports using queries within quickbase, in this scenario what I need to do is to evaluate if my project manager (let's say) Joe Black who has a Principal title appears in my query at least once, that way I can identify if Joe is indeed Principal and has one or more projects or the opposite.
The part of the code that is not working is the evaluation part, and specifically because I can't store the logical result into a variable. I have verified and evaluated step by step the counting from my query and their conditions and it works perfectly except for this part:
var number PrincipalJoeBlack=
ToNumber(
If(
$CountPrincipalJoeBlack>=1, 1
));
Which result for the variable PrincipalJoeBlack is 0 (although the condition is true)
Don't know if there is a better way to do this kind of lookup with very specific conditions and cases without using if, I know there is no formula to identify unique values in QuickBase at the moment and that's why I am building an iterator.
PS: I also tested the if condition without ToNumber function and same happens.
Hope you can help me and thank you in advance.
------------------------------
JESUS CRUZ
------------------------------
What I am trying to do is the following:
I have a main table that I use to build reports using queries within quickbase, in this scenario what I need to do is to evaluate if my project manager (let's say) Joe Black who has a Principal title appears in my query at least once, that way I can identify if Joe is indeed Principal and has one or more projects or the opposite.
The part of the code that is not working is the evaluation part, and specifically because I can't store the logical result into a variable. I have verified and evaluated step by step the counting from my query and their conditions and it works perfectly except for this part:
var number PrincipalJoeBlack=
ToNumber(
If(
$CountPrincipalJoeBlack>=1, 1
));
Which result for the variable PrincipalJoeBlack is 0 (although the condition is true)
Don't know if there is a better way to do this kind of lookup with very specific conditions and cases without using if, I know there is no formula to identify unique values in QuickBase at the moment and that's why I am building an iterator.
PS: I also tested the if condition without ToNumber function and same happens.
Hope you can help me and thank you in advance.
------------------------------
JESUS CRUZ
------------------------------