I think i have isolated my previous problem wiht the case statment in that for some reason my code dosent know that its a sql pass threw untill after it checks the code for correctness, and obviously access dosent like case statments atleast not in the way that SQL needs to see it. How can I eather force the code to go threw or identify the querydef as a sql pass threw before it evaluates the correctness of the code?