MS Access 2003-创建仪表板-将值返回到表单吗? [英] MS Access 2003 - Creating a Dashboard - Return Values to a form?

查看:64
本文介绍了MS Access 2003-创建仪表板-将值返回到表单吗?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

所以这是我从未尝试过的事情,但是我想我想在MS Access数据库中创建一个Metrics Dashboard.所以我认为我要问的第一个问题是

So this is something that I have never tried, but I think I want to create a Metrics Dashboard in my MS Access database. So I think the first question that I need to ask is

如何将值返回到表单?如果我汇总的销售总额排名前10位,我该如何不仅指定我希望获得最高结果的查询,还要指定最高/第一条记录"(按降序排列?)文本框?

how can I return a value to a form? If I ave aggregate queries that are top 10 total sales, how can I specify not only the query that I want the top result to come from, but also the "top/first record" (listing in descending order? should i use a single text box?

我认为使用数据表视图创建子窗体将显示给定查询的整个结果,但是我也想只列出几个查询的最高值...

i figure that making a subform with a datasheet view will display the entire result of a given query, however I am also wanting to just list the top values of several queries...

谢谢,我敢肯定,这只会引起更多的问题!

thanks, i am sure this will just lead to more questions to follow!

推荐答案

您可以使用子窗体或列表框.可以在运行时设置列表框的ControlSource属性和子窗体的RecordSource属性.可以设置要在Jet SQL中返回的最高值的数量.请注意,Top返回索引中所有匹配的值,因此,如果存在 n 个相等的值,则Top 1将返回 n 个记录.

You could use a subform or listbox. The ControlSource property of the listbox and the RecordSource property of the subform can be set at runtime. It is possible to set the number of top values to be returned in Jet SQL. Be aware that Top returns all matching values from the index, so if there are n equal values, Top 1, say, will return n records.

SELECT TOP 10 Field1, Field2 FROM tblTable ORDER BY Field1

SELECT TOP 10% Field1, Field2 FROM tblTable ORDER BY Field1

这篇关于MS Access 2003-创建仪表板-将值返回到表单吗?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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