Re: storing months in mysql 4
- From: "NC" <nc@xxxxxxxxx>
- Date: 29 Apr 2005 08:12:50 -0700
laredotorn...@xxxxxxxxxxx wrote:
>
> I'm using PHP 4 and MySQL 4. I want to store the month and
> year as a single row but I am having difficulty figuring out
> the best data type to use.
The best for WHAT? How do you intend to use the data? What
typical computations will be performed on it? What will it
be routinely compared to?
> I suppose I could use 'DATE' and then always have the day
> value be equal fto 1, but I figure there's a more elegant
> approach.
Again, depends on how you are going to use the data. Maybe
for your purposes it makes more sense to set the date to the
last day of the month...
Cheers,
NC
.
- References:
- storing months in mysql 4
- From: laredotornado
- storing months in mysql 4
- Prev by Date: Re: Excluding records from repeat region in PHP
- Next by Date: Re: Where is my mind ?
- Previous by thread: storing months in mysql 4
- Next by thread: Where is my mind ?
- Index(es):
Relevant Pages
|