I am doing probably the simplest query, but am on little sleep, can
someone tell me where I am goofing?

Select  
                COUNT (customer_orders.id) as totqty,
                SUM (customer_orders.subtotal) as subtot,
                SUM (customer_orders.shipcost) as cstship,
                SUM (customer_orders.shipquote) as qteship,
                AVG (customer_orders.subtotal) as avgsub,
                AVG (customer_orders.shipcost) as avgship
        FROM customer_orders
        WHERE customer_orders.orderdate BETWEEN #start1a# AND
#DateAdd('D', 1, end1a)#
        AND subtotal < 50

Just want all orders for a date period to give me sums and averages that
was under 50 dollars.  But it seems to be getting from all time.  What
did I miss?

Thanks!

Eric

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Logware (www.logware.us): a new and convenient web-based time tracking 
application. Start tracking and documenting hours spent on a project or with a 
client with Logware today. Try it for free with a 15 day trial account.
http://www.houseoffusion.com/banners/view.cfm?bannerid=67

Message: http://www.houseoffusion.com/lists.cfm/link=i:4:207696
Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4
Subscription: http://www.houseoffusion.com/lists.cfm/link=s:4
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4
Donations & Support: http://www.houseoffusion.com/tiny.cfm/54

Reply via email to