Search Results

Search found 1 results on 1 pages for 'aryans'.

Page 1/1 | 1 

  • SQL Query That Should Return Least two days record

    - by Aryans
    I have a table "abc" where i store timestamp having multiple records let suppose 1334034000 Date:10-April-2012 1334126289 Date:11-April-2012 1334291399 Date:13-April-2012 I want to build a sql query where I can find at first attempt the records having last two day values and so second time the next two days . . . Example: Select *,dayofmonth(FROM_UNIXTIME(i_created)) from notes where dayofmonth(FROM_UNIXTIME(i_created)) > dayofmonth(FROM_UNIXTIME(i_created)) -2 order by dayofmonth(FROM_UNIXTIME(i_created)) this query returns all the records date wise but we need very most two days record. Please suggest accordingly. Thanks in advance

    Read the article

1