Jump to content

Selecting a mysql record's based on the month it was created.

- - - - -

  • Please log in to reply
1 reply to this topic

#1
iamchristill

iamchristill

    Newbie

  • Members
  • PipPip
  • 13 posts
Basicailly. The table is populated from a form on the front end and in the back end i need to show the total of the "Price" field based on month. Kinda like a profit and loss sheet.

The table has a datetime field and I need to know how to isolate the month and then display the records based on that.

Thanks

#2
WingedPanther

WingedPanther

    A spammer's worst nightmare

  • Moderators
  • 16,831 posts
  • Location:Upstate, South Carolina
  • Programming Language:C, C++, PL/SQL, Delphi/Object Pascal, Pascal, Transact-SQL, Others
  • Learning:Java, C#, PHP, JavaScript, Lisp, Fortran, Haskell, Others
Why can't you select all the records "where date between '2011-08-01' and '2011-08-30'"?
Programming is a branch of mathematics.
My CodeCall Blog | My Personal Blog




1 user(s) are reading this topic

0 members, 1 guests, 0 anonymous users