+ Reply to Thread
Results 1 to 3 of 3
  1. #1
    Registered User
    Join Date
    02-26-2009
    Location
    U.S
    MS-Off Ver
    Excel 2003
    Posts
    42

    Show first 50 records using VBA

    Hi all,



    I have a query that selects all staff. I would like to change it to 3 or 4 separate queries.....one that shows the 1st through the 50th record, the next that selects the 51st through the 100th record, etc.

    Is this possible?

  2. #2
    Forum Moderator ConneXionLost's Avatar
    Join Date
    03-11-2009
    Location
    Victoria, Canada
    MS-Off Ver
    2003 & 2010
    Posts
    1,791

    Re: Show first 50 records using VBA

    Hi LilyMarie,

    Not a complete answer for you. Switch your query to SQL view and change it from:

    SELECT ...

    to:

    SELECT TOP 50 ...

    This will give you the first 50 records.

    - - - -

    Beyond that you'll need to select the staff by their IDs or build a sort column in the staff table.

    Cheers,
    Docendo discimus.

    Please consider:
    • Thanking those who helped you. Click the reputation icon in the contributor's post and add Reputation.
    • Cleaning up when you're done. Mark your thread [SOLVED] if you received your answer.

  3. #3
    Registered User
    Join Date
    02-26-2009
    Location
    U.S
    MS-Off Ver
    Excel 2003
    Posts
    42

    Re: Show first 50 records using VBA

    Thanks for your reply but i need the programmatic solution.So that i can solve my problem.

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.2.0