Max Query, Why doesn't this work?

kylem4711

New member
Local time
Today, 08:04
Joined
Mar 24, 2009
Messages
8
Complete: Max(IIf([Job Category]='Manager' And [3L00643 WBT] Is Not Null And [L00641 Mgr] Is Not Null,('L00641 Mgr','3L00643 WBT'),""))

basically, i am trying to say, if a Manager has taken 3L00643 WBT and L00641 Mgr, then show the max of those two dates.

Can anyone help?
 
sorry,
it actually just said there was a syntax error (comma) in query expression. error 3075
But i can not remove any of the commas
 
More info please....

I can't make head nor tail of the code you posted..... is there more?
 
that is actually it,
3L00643 WBT is a course that a manager would take so it only contains dates. The same is for L00641 Mgr.

this works,
Complete: IIf([Job Category]='Manager' And [L00641 Mgr] Is Not Null And [3L00643 WBT] Is Not Null,[L00641 Mgr]," ")



But I wanted to have L00641 Mgr and 3L00643 WBT as a possible output values and be able to get the max of those two classes is they both are complete. does that make a little more sense?
 
I don't understand your code either, but I see an "If"(IIf=If and only if?) statement without a "Then" statement. What should happen when the "If" condition is met?
I'm no expert, but that's what I see. It seems that you need to specify what you want (last completion date?) where neither "Mgr" nor "Wbt" are null.
 
I don't understand your code either, but I see an "If"(IIf=If and only if?) statement without a "Then" statement. What should happen when the "If" condition is met?
I'm no expert, but that's what I see. It seems that you need to specify what you want (last completion date?) where neither "Mgr" nor "Wbt" are null.


sorry i must be terrible at explaining stuff. this is my though process of what im trying to say.

If you are a manager, and you have taken the WBT and Mgr, then show me the last completion date of the two courses (Wbt, Mgr) if not, then leave blank.

when I am trying to create is a completion column, so whatever course the manager completes last whether it be the WBT or Mgr, once they complete the last class, that will be their completion date. It takes taking both the Wbt and Mgr class to be "complete"
 

Users who are viewing this thread

Back
Top Bottom