Re: Is this the most effient to do with php an mysql?

From: Date: Tue, 07 Feb 2006 04:12:11 +0000
Subject: Re: Is this the most effient to do with php an mysql?
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-230024@lists.php.net to get a copy of this message
using mysql is better then using php. SELECT y_id, year FROM Year WHERE year <= year(curdate) ORDER BY year desc; Paul Goepfert wrote:
Hi all, I have a table of years going from 1985 - 2008. These years represent the purchase year. I have created a SQL statement that selects the years that are available for purchase years. For example 2006 -1985. Here is the SQL statement I created to produce that output. SELECT y_id, year FROM Year WHERE year <= extract(year from now()) ORDER BY year desc; Is there a more efficient way to do this using more PHP and less mysql? Thanks Paul
-- life is a game... so have fun.

« previous php.general (#230024) next »