Rich Shepard <rshep...@appl-ecosys.com> wrote:
> On Sun, 11 Oct 2009, Igor Tandetnik wrote:
>
>> I simply combine (month, day) pair into a single number - the same
>> way you combine two digits of a decimal number by multiplying the
>> first by 10 and adding the second. The multiplier doesn't have to be
>> 100 - any number greater than 31 will do.
>
>   Would it not be easier to use the DATE column and STRFTIME()?

It would be possible. Would it be easier? I'm not sure. Why don't you write an 
equivalent statement using this approach, then 
compare and contrast yours and mine?

> Specifying start and end dates as YYYY-MM-DD removes the need for
> such manipulations

As far as I can tell, the OP wants to only specify start and end month/day, and 
expects data from all years that fall into the 
specified window. E.g., for the span of 1/1 through 1/31, he wants all entries 
from January regardless of the year.

> and will work within a single year as well as over
> multi-year spans.

I don't quite see how you plan to pull that off. Please enlighten me.

>   I ask because that's the way I would approach the solution to the
> question Rick asked. The MONTH and DAY columns seem repetitive to me
> and a potential souce of loss of integrity. If those columns are
> filled by extracting the appropriate portions of the DATE column, why
> not use the latter itself?

Suppose dates where represented in the database as YYYY-MM-DD  - how would that 
help you solve the problem? Again, I suggest you 
show an example.

Igor Tandetnik 


_______________________________________________
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

Reply via email to