Ask a Question
Ask Question Login
Corporate Training
  1. Community
  2. SQL Server
  3. Question
SQL Server

How do I query in SQL for getting the latest record date for each user ?

Asked by Carole Thom Mar 6, 2021 1.1K views 1 answer
Share

About this question

I have a SQL table that is a collection entry as to when a user was logged on.

username, date,      value

--------------------------

brad,     1/2/2010,  1.1

fred,     1/3/2010,  1.0

bob,      8/4/2009,  1.5

brad,     2/2/2010,  1.2

fred,     12/2/2009, 1.3 etc..

How do I trigger a query that would give me the latest date for each user? and, I needed to have a value that goes along with the sql most recent date.

Your answer

1 Answer

More SQL Server discussions

Learn & Explore

Free tutorials and interview questions from industry experts — learn the skill, then get ready to prove it.

Latest SQL Server Blogs

Guides, tips and career advice on SQL Server from JanBask experts.