I am working in mysql. If i want previous month data i write code like this. Dont know whether works in sql
$month=`date --date='1 month ago' +%B`; . . . my $sth = $dbh->prepare("SELECT * from $table where monthname(Date)='$ +month'" ); . . .
In reply to Re^3: Problem passing date to SQL
by ravi45722
in thread Problem passing date to SQL
by JoeTheProgrammer
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |