Re: [sqlite] How to use function in binding parameters ?
Hello Marten, do this: insert into persons(name, birthday) values( ?, date(?)) And bind the string '1964-04-01' Martin Marten Feldtmann schrieb: I'm not sure how to use a function call in a prepared statement: insert into persons(name, birthday) values( ?,?) how to I bind the value of date('1964-04-01') to one of the parameters ? I want to store not the string, but the value of the internal date-function-call into that column ? Somehow I do not get it how I could do that using the API !? Thanks, Marten ___ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users ___ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users
[sqlite] How to use function in binding parameters ?
I'm not sure how to use a function call in a prepared statement: insert into persons(name, birthday) values( ?,?) how to I bind the value of date('1964-04-01') to one of the parameters ? I want to store not the string, but the value of the internal date-function-call into that column ? Somehow I do not get it how I could do that using the API !? Thanks, Marten ___ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users
Re: [sqlite] How to use function in binding parameters ?
Marten Feldtmann [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] I'm not sure how to use a function call in a prepared statement: insert into persons(name, birthday) values( ?,?) how to I bind the value of date('1964-04-01') to one of the parameters ? It's not clear why you would want to, considering that date('1964-04-01') = '1964-04-01'. date() function produces a string in -MM-DD format (the same format you are starting with). For more details, see http://www.sqlite.org/cvstrac/wiki?p=DateAndTimeFunctions Igor Tandetnik ___ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users
Re: [sqlite] How to use function in binding parameters ?
Igor Tandetnik wrote: It's not clear why you would want to, considering that date('1964-04-01') = '1964-04-01'. date() function produces a string in -MM-DD format (the same format you are starting with). Due to a totally misunderstanding of these functions ... forget my question I thought, that these function convert it to float internally - but I was totally wrong Sorry ! Marten ___ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users
Re: [sqlite] How to use function in binding parameters ?
Marten Feldtmann [EMAIL PROTECTED] wrote: Igor Tandetnik wrote: It's not clear why you would want to, considering that date('1964-04-01') = '1964-04-01'. date() function produces a string in -MM-DD format (the same format you are starting with). Due to a totally misunderstanding of these functions ... forget my question I thought, that these function convert it to float internally - but I was totally wrong julianday() function does. Perhaps this is the one you want to use. Igor Tandetnik ___ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users