Posted By

assbach on 02/25/07


Tagged

mysql date DateTime currency


Versions (?)

Who likes this?

2 people have marked this snippet as a favorite

vali29
heinz1959


SELECT older than x days


 / Published in: SQL
 

2 things here. currency (euro) with in a 2.00 format and select entries older than 4 weeks = 28 days

  1. SELECT
  2. FORMAT(kontoinfo.betrag,2) AS betrag
  3. FROM konto
  4. WHERE user = '".$uid."'
  5. AND konto.datum >= SUBDATE( NOW(), 28)
  6. ORDER BY konto.datum DESC

Report this snippet  

Comments

RSS Icon Subscribe to comments
Posted By: meme on June 22, 2009

SELECT createddate, email FROM customers WHERE (createddate >= CURDATE() - INTERVAL 1 DAY)

Note: you can change the 1 to any number of days.

You need to login to post a comment.