D
Donna
Hello,
I've seen it done, but have forgotten how to write it out... I have an
action query (Make Table qry), based on a single table, I have a field named
ExpenseElement. It is a number field, integer. I have set the criteria to
look for 3 expense elements: 111 or 120 or 900. I want to assign a new
number to all the records found, meeting this criteria. For instance: create
a new expense element from 111 to 112; from 120 to 121, and from 900 to 901.
I created a new field in the query, named it NewEE:IIF [this is where I want
to put the nested Iif statements]. I used the operator "OR" between the 3
IIF statements, but the results I got were a True value of -1. It did not
replace the EE numbers as I wanted. (I don't know how to write SQL from
scratch) I wrote something similar to this: iif ([EE]=111,112) OR IIF
([EE]=120, 121) OR IIF ([EE]=900, 901). As I mentioned, it returned a True
value for each of the records, but it did not assign the new numbers I
wanted it to. What am I doing wrong?
Thanks for your advice, Donna
I've seen it done, but have forgotten how to write it out... I have an
action query (Make Table qry), based on a single table, I have a field named
ExpenseElement. It is a number field, integer. I have set the criteria to
look for 3 expense elements: 111 or 120 or 900. I want to assign a new
number to all the records found, meeting this criteria. For instance: create
a new expense element from 111 to 112; from 120 to 121, and from 900 to 901.
I created a new field in the query, named it NewEE:IIF [this is where I want
to put the nested Iif statements]. I used the operator "OR" between the 3
IIF statements, but the results I got were a True value of -1. It did not
replace the EE numbers as I wanted. (I don't know how to write SQL from
scratch) I wrote something similar to this: iif ([EE]=111,112) OR IIF
([EE]=120, 121) OR IIF ([EE]=900, 901). As I mentioned, it returned a True
value for each of the records, but it did not assign the new numbers I
wanted it to. What am I doing wrong?
Thanks for your advice, Donna