访问查询阈值和日期范围 [英] Access Query threshold and date range

查看:66
本文介绍了访问查询阈值和日期范围的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我构建基本查询来为工作项目提取数据。  我没有很多访问经验或知识。  我通常会观看视频并了解如何构建查询。  我试图弄清楚如何根据特定的阈值或标准构建一个返回结果
的查询。  假设我有一家公司,想要查看60天的特定日期范围,并确定客户是否在60天内购买了三件以上的商品。  使用当前日期和
返回60天。  报告将显示名称字段的结果,该字段具有相同的名称,在60天的时间范围内出现三次。  我如何为这些字段创建查询语句?    

I build basic queries to pull data for work projects.  I don't have a lot of experience or knowledge with access.  I normally watch videos and learn how to build queries.  I am trying to figure out how to build a query that will return results based on specific thresholds or a criteria.  Let's say I had a business and wanted to look at a specific date range say 60 days and determine if a customer purchased more than three items within the 60 day time period.  Using the current date and going back 60 days.  The report would display results of the name field had the same name appear three times within the 60 day time frame.  How would I create a query statement for those fields?    

推荐答案

在"总计"查询中添加这些内容并关闭SHOW -

Add these in a 'Totals' query and turn off the SHOW --

YourDateField 和使用标准  在Date()和Date()之间 - 60 

YourDateField and use criteria  Between Date() AND Date()-60 

YourNameField 设置为COUNT并使用条件 > = 3

YourNameField set to COUNT and use criteria >= 3


这篇关于访问查询阈值和日期范围的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆