By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
434,587 Members | 1,070 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 434,587 IT Pros & Developers. It's quick & easy.

Problem with query

manoj9849967222
P: 48
Hi All

I have a problem with query.

I have designed a simple query which sould give me itemwise total qty sales during a given period.

the fields in the query are
startdate, modelno,model,qty.

I have also designed a form where the user will give the period for example 1/1/2007 to 1/10/2007

My query looks like this..

SELECT Outwardmaster.startdate, Outwardmaster.Modelno, Outwardmaster.Model, Sum(Outwardmaster.Qty) AS SumOfQty
FROM Outwardmaster
GROUP BY Outwardmaster.startdate, Outwardmaster.Modelno, Outwardmaster.Model
HAVING (((Outwardmaster.startdate) Between [forms]![ICproductreport]![txtstartdate] And [forms]![ICproductreport]![txtenddate]));

but now when i run the query it doesnot gives me itemwise total qty sales during a given period.

Please suggest if there are any mistake in my query.


Regards
Manoj
Oct 7 '07 #1
Share this Question
Share on Google+
2 Replies


nico5038
Expert 2.5K+
P: 3,072
Hmm, looks to me you're using European dates and the query requires the mm/dd/yyyy US date format.
The easiest solution is to change the form date field's format into a date with month description (see options when selecting the dateformat in the properties window when you have the form in designmode).
Your formdate will look like: 1-nov-2007

Nic;o)
Oct 7 '07 #2

manoj9849967222
P: 48
Hi Nico

I am using the US date format only i.e mm/dd/yy. I have tried using your format also. still i am not able to come out of this.

Regards
Manoj
Oct 7 '07 #3

Post your reply

Sign in to post your reply or Sign up for a free account.