• clai_shock008 - Thursday, March 8, 2018 3:21 AM

    It might be that we need to format the date to remove the time component?

    To group by date you'll definitely need to remove the time. 
    After reading your question properly, I'm not sure the error you're getting is actually because of the grouping.  Have you declared any parameters to map to '?'?


    On two occasions I have been asked, "Pray, Mr. Babbage, if you put into the machine wrong figures, will the right answers come out?" ... I am not able rightly to apprehend the kind of confusion of ideas that could provoke such a question.
    —Charles Babbage, Passages from the Life of a Philosopher

    How to post a question to get the most help http://www.sqlservercentral.com/articles/Best+Practices/61537