Re: [sqlite] Re: Re: how do i declare and use variables in sqlite?

2007-08-03 Thread John Stanton
Paul Harris wrote: On 03/08/07, Nikola Miljkovic <[EMAIL PROTECTED]> wrote: [In the message "Re: [sqlite] Re: Re: how do i declare and use variables in sqlite?" on Aug 3, 11:47, "Paul Harris" writes:] create temporary table vars (name text, value something); -- in

Re: [sqlite] Re: Re: how do i declare and use variables in sqlite?

2007-08-03 Thread Gerry Snyder
Paul Harris wrote: ok, so a subselect can be used. not bad, but not as powerful as the mysql @ variables, which can then be used in all sorts of scenarios later, without inducing the same query over and over to get the value. SQLite is (mostly) intended to be a library for SQL execution,

Re: [sqlite] Re: Re: how do i declare and use variables in sqlite?

2007-08-02 Thread Paul Harris
On 03/08/07, Nikola Miljkovic <[EMAIL PROTECTED]> wrote: > [In the message "Re: [sqlite] Re: Re: how do i declare and use variables in > sqlite?" on Aug 3, 11:47, "Paul Harris" writes:] > > > >> create temporary table vars (name text, value someth

Re: [sqlite] Re: Re: how do i declare and use variables in sqlite?

2007-08-02 Thread Nikola Miljkovic
[In the message "Re: [sqlite] Re: Re: how do i declare and use variables in sqlite?" on Aug 3, 11:47, "Paul Harris" writes:] > > >> create temporary table vars (name text, value something); > > >> -- > > >> insert into vars set name=&quo

Re: [sqlite] Re: Re: how do i declare and use variables in sqlite?

2007-08-02 Thread Paul Harris
> >> create temporary table vars (name text, value something); > >> -- > >> insert into vars set name="x", value=0; > >> -- > >> ... where something = (select value from vars where name="x")... > >> > > > > I tried doing this, but there doesn't seem to be a way to do the same > > thing with an

[sqlite] Re: Re: how do i declare and use variables in sqlite?

2007-08-02 Thread Igor Tandetnik
Paul Harris <[EMAIL PROTECTED]> wrote: On 03/08/07, Nikola Miljkovic <[EMAIL PROTECTED]> wrote: This is certainly true, but there might be cases where one wants to keep certain results between sql statements and reuse them. While this conceptual solution is certainly not the Variable it sort of

[sqlite] Re: Re: how do i declare and use variables in sqlite?

2007-08-02 Thread Igor Tandetnik
Nikola Miljkovic <[EMAIL PROTECTED]> wrote: create temporary table vars (name text, value something); insert into vars set name="x", value=0; Surely you mean insert into vars(name, value) values('x', 0); Igor Tandetnik