What is wrong with this equation?

  • Thread starter Thread starter Phil Smith
  • Start date Start date
P

Phil Smith

What is wrong with this?

Results:[item]![old_sku] In
("11111654","11111656","11111658","11111659","11111660","11111803","11111881","11111882
")

When I put that as a field in a select query and run it, I get either a
0 or a -1. This is fine. When I use that field as the Column Heading
in a crosstab query, I get each individual item.old_sku. Why don't I
get the same 0 and -1?

I tried to fix it by changing the field to this:

Results:iif( [item]![old_sku] In
("11111654","11111656","11111658","11111659","11111660","11111803","11111881","11111882
") = 0, "no","yes")

But I get "The operator you entered rrequires parenthesis."

What the heck?

Phil
Access 2007
 
Crosstabs are picky about the syntax. They usually puke at the notion of
subqueries so this might be related. I would create a small table and model
this in data. Enter the SKUs in a table and outer join it in your crosstab
so you don't have to use the list.
 
Phil -

Remove the '= 0' - like this:

Results:iif( [item]![old_sku] In
("11111654","11111656","11111658","11111659","11111660","11111803","11111881","11111882
"), "no","yes")
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top