Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 417751
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 12, 20262026-05-12T18:36:40+00:00 2026-05-12T18:36:40+00:00

When I will group by details column and look for the date 2009-08-05 I

  • 0

When I will group by details column and look for the date “2009-08-05” I want the earlier one day id as well.

select id,  details, abc_date from test order by details limit 10;
+------------+------------------+------------+
| id         | details          | abc_date   |
+------------+------------------+------------+
|       2224 | 10025            | 2009-08-11 | 
|       4575 | 10025            | 2009-09-02 | 
|       1617 | 10025            | 2009-08-05 | 
|       3614 | 10025            | 2009-08-24 | 
|       1811 | 10025            | 2009-08-07 | 
|        969 | 10025            | 2009-07-29 | 
|       1441 | 10025            | 2009-08-03 | 
|       4345 | 10025            | 2009-08-31 | 
|       3330 | 10025            | 2009-08-21 | 
|        799 | 10025            | 2009-07-27 | 
+------------+------------------+------------+
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-12T18:36:40+00:00Added an answer on May 12, 2026 at 6:36 pm
    SELECT  details,
            (
            SELECT  id
            FROM    test ti
            WHERE   ti.details = to.details
            ORDER BY
                    date
            LIMIT 1
            ) AS first_id
    FROM    test to
    GROUP BY
            details
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

select lastname, firstname from person group by lastname, firstname having 50 >= (select count(p.personid)
I am storing user details and group names in seperate table. I want to
My group and I have an application that will work with protected content files
I'm making a settings screen at the moment that will have a radiobutton group
I am building a utility that will copy users and groups from an Oracle
I need to group a set of rows based on the Category column, and
I want to terminate a process group by sending SIGTERM to processes within it.
I am trying to create a query that will show the details for each
I want the contents of a group box to be selected by value, so
I need to parse an xml File in C#...The File will look some thing

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.