Still celebrating National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

MS Access Query--Display only first (top) record set

Posted on 2014-09-14
2
Medium Priority
?
639 Views
Last Modified: 2014-09-14
Experts:

I have an Access Query ("Querry1").  Record-sets within this Query are automatically sorted by the 'Last Field that was Modified' so the Record-set containing the last field that was updated will always appear first (at the top) in my Query.
I only want the Query to display this first (top) Record-set (I do not want any other Record-sets to be displayed).  Does anyone have an idea how to do this?

I'm not great with Access, so if you could walk me though each step it would be most appreciated.

Thanks.
0
Comment
Question by:mdstalla
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 25

Accepted Solution

by:
chaau earned 2000 total points
ID: 40322227
You need to use TOP 1 clause in the query. Let's assume your query has this syntax:
SELECT column1, column2, LastModifiedDate
FROM Table1
ORDER BY LastModifiedDate DESC

Open in new window

When you add the TOP 1 clause the query will look like:
SELECT TOP 1 column1, column2, LastModifiedDate
FROM Table1
ORDER BY LastModifiedDate DESC

Open in new window

0
 

Author Closing Comment

by:mdstalla
ID: 40322401
Ha!  How easy was that!

Thanks for your help C!
0

Featured Post

Migrating Your Company's PCs

To keep pace with competitors, businesses must keep employees productive, and that means providing them with the latest technology. This document provides the tips and tricks you need to help you migrate an outdated PC fleet to new desktops, laptops, and tablets.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

In Part II of this series, I will discuss how to identify all open instances of Excel and enumerate the workbooks, spreadsheets, and named ranges within each of those instances.
We live in a world of interfaces like the one in the title picture. VBA also allows to use interfaces which offers a lot of possibilities. This article describes how to use interfaces in VBA and how to work around their bugs.
Basics of query design. Shows you how to construct a simple query by adding tables, perform joins, defining output columns, perform sorting, and apply criteria.
In Microsoft Access, learn how to “cascade” or have the displayed data of one combo control depend upon what’s entered in another. Base the dependent combo on a query for its row source: Add a reference to the first combo on the form as criteria i…

721 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question