开发者

How to limit date?

I'd like to select all entries from a table where date is the last one and only those ones.

For example: today is May 16th, the last entries I have from my table is dated from May 15th, but I have older ones (May 14th, May13th, etc). I'd like to select only the dated from May 15th, but it's not this specific date, I need to select every entry dated from the last date I have in my database.

开发者_如何学PythonHow to?

Thx in advance


SELECT [list]
FROM MyTable MT1
WHERE MT1.date = (
     SELECT MAX(MT2.date)
     FROM MyTable MT2
  )
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜