2009/7/6 Rick Ratchford <r...@amazingaccuracy.com>:
> Greetings!
>

Hi Rick,

> I'm having trouble with what I thought would be a simple SQL query.
>
>    SQLString = "SELECT strftime('%d', Date) as Day, IsSwingTop1 as Tops,
> IsSwingBtm1 as Btms " & _
>                "FROM TmpTable WHERE Day = 11"
>
> I'm trying to create a recordset where the only records returned are those
> that fall on the 11th of the month.
>
> When I run this without the 'WHERE Day = 11", it returns all the records in
> 3 columns, Day, IsSwingTop1 and IsSwingBtm1. Under the Day column, I can see
> all the days as 01, 02...31.

That's good...

>
> I'm not sure where I'm making my logic error.

...and you think that there is a problem because?

It would really help if you explained what leads you to believe that
there is a logic error.

>
> Thanks.
>
> Rick
>

If you use typeof() around "strftime('%d',date)", it shows type TEXT.
You are comparing this with an INTEGER; never true.

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

Reply via email to