æ¥ä»é¢æ°ã®ä½¿ç¨ä¾ã§ãã次ã®ã¯ã¨ãªã¼ã¯ãã¹ã¦ã®è¡ããéå» 30 æ¥ä»¥å ã® date_col ã§é¸æãã¾ã : mysql> SELECT something FROM tbl_name -> WHERE DATE_SUB(CURDATE(),INTERVAL 30 DAY) <= date_col; ã¾ããã®ã¯ã¨ãªã¼ã¯ãå°æ¥ã®æ¥ä»ã®è¡ãé¸æãã¾ãã æ¥ä»å¤ãåãå ¥ããé¢æ°ã¯é常ãæ¥ä»æå»å¤ãåãå ¥ããæå»ã®é¨åãç¡è¦ãã¾ããããã¦æå»å¤ãåãå ¥ããé¢æ°ã¯é常ãæ¥ä»æå»å¤ãåãå ¥ããæ¥ä»ã®é¨åãç¡è¦ãã¾ãã ç¾å¨ã®æ¥ä»ã¾ãã¯æå»ãããããæ»ãé¢æ°ã¯ãã¯ã¨ãªã¼å®è¡ã®éå§æç¹ã§ãåã¯ã¨ãªã¼ã«ã¤ãä¸åº¦ã ãè©ä¾¡ããã¾ããã¤ã¾ããNOW() ãªã©ã®é¢æ°ãåä¸ã¯ã¨ãªã¼å ã§è¤æ°ååç §ããã¦ããå ´åãã©ã®åç §ã§ã常ã«åãçµæãçæããã¾ãã(ããã§è¨ãåä¸ã¯ã¨ãªã¼ã«ã¯ãã¹ãã¢ãããã°ã©ã (ã¹ãã¢ãã«ã¼ãã³
{{#tags}}- {{label}}
{{/tags}}