Slavin
Sent: Wednesday, February 6, 2019 11:30 PM
To: SQLite mailing list
Subject: Re: [sqlite] Multiple SELECTs in one call
On 7 Feb 2019, at 4:21am, Jose Isaias Cabrera wrote:
> want to use the result of (SELECT a from t where e != 1); to run another
> select (SELECT a from t where
Thanks, Keith. Yep, exactly what I was looking for. Gracias.
From: sqlite-users on behalf of
Keith Medcalf
Sent: Wednesday, February 6, 2019 11:37 PM
To: SQLite mailing list
Subject: Re: [sqlite] Multiple SELECTs in one call
You mean something like
select
qlite.org
>Subject: [sqlite] Multiple SELECTs in one call
>
>
>Greetings.
>
>I need some help from you gurus to have multiple selects, but the
>sequence is important. For example,
>
>create table t (a, b, c, d, e);
>insert into t values (1,2,3,4,5);
>insert into t va
On 7 Feb 2019, at 4:21am, Jose Isaias Cabrera wrote:
> want to use the result of (SELECT a from t where e != 1); to run another
> select (SELECT a from t where d > 3); and then, one more select (SELECT a
> from t where c != 1 AND b != 1);
How are these related to each other ?
Do you want
Greetings.
I need some help from you gurus to have multiple selects, but the sequence is
important. For example,
create table t (a, b, c, d, e);
insert into t values (1,2,3,4,5);
insert into t values (2,2,3,4,5);
insert into t values (3,3,3,3,3);
insert into t values (4,1,1,1,1);
insert into
MikeW wrote:
> Andrew Gatt <[EMAIL PROTECTED]> writes:
>
>
>> I'm not sure if i'm missing something, but is there an efficient way of
>> retrieving multiple rows based on different conditions in order. For
>> example i have a table with rows of ids, i want to select multiple rows
>> at a
Andrew Gatt <[EMAIL PROTECTED]> writes:
>
> I'm not sure if i'm missing something, but is there an efficient way of
> retrieving multiple rows based on different conditions in order. For
> example i have a table with rows of ids, i want to select multiple rows
> at a time. At present i am
"Andrew Gatt" <[EMAIL PROTECTED]> wrote in
message news:[EMAIL PROTECTED]
> I'm guessing my SQL is the worst way of doing things so i've been
> trying to find a better method. I stumbled across "SELECT name FROM
> table WHERE id IN (x,y,z) however this doesn't allow me to specify
> the order the
If it's completely arbitrary I think you are stuck with using union
unless it's an order that you might know beforehand.
Then you can add an extra column with the index.
/Jonas
On Sat, Oct 18, 2008 at 7:05 PM, Andrew Gatt <[EMAIL PROTECTED]> wrote:
> Jonas Sandman wrote:
>> Just to point out the
Just to point out the obvious, have you tried ORDER BY?
"SELECT name FROM table ORDER BY name;" will return your list in
alphabetical order.
/Jonas
On Sat, Oct 18, 2008 at 6:53 PM, Andrew Gatt <[EMAIL PROTECTED]> wrote:
> Andrew Gatt wrote:
>> I'm not sure if i'm missing something, but is there
"Igor Tandetnik" <[EMAIL PROTECTED]> wrote:
> [EMAIL PROTECTED] wrote:
> > SELECT count(state='Normal'), count(state='Critical') FROM tbl1;
>
> Wouldn't that just return the number of all rows in tbl1, twice? That
> probably should be
>
> SELECT sum(state='Normal'), sum(state='Critical') FROM
chetana bhargav <[EMAIL PROTECTED]> wrote:
> Actually I am trying to retrieve values in a single step.
>
> My queries need to be something like,
>
> select count(*) from tbl1 where state='Normal';
> select count(*) from tbl1 where state='Critical'
>
> I got to have these two as seperate,
Hi,
Just wanted to know can we have multiple quries in a single prepare statement
seperated by semicolons.Something like,
Select count(*) from tbl where name="foo";select count(*) from tbl1 where name
= "bar"
...
Chetana.
__
Do You Yahoo!?
Many thanks for helping.
While using SQLite dll Version 3.3.4 on Windows
- Multiple threads/processes access SQLite database,
- Each thread does some SELECTs, INSERTs or UPDATEs.
If for some single SELECT (where user input is used in SQL statement, so to
avoid SQL injection),
It depends upon your application. For it to function optimally you
should make each transaction on your application an SQL transaction,
commit it on success or rollback if there is a problem. In that way you
make each transaction atomic and maintain the integrity of your database.
Since
Thanks for clearing doubt.
Now question is...
While using SQLite dll Version 3.3.4 on Windows
- Multiple threads/processes access SQLite database,
- Each thread does some SELECTs, INSERTs or UPDATEs.
Wrapping all read-only SELECEs with BEGIN TRANSACTION
and using BEGIN EXCLUSIVE to wrap
Hi All,
While using SQLite dll Version 3.3.4 on Windows
- Multiple threads/processes access SQLite database,
- Each thread does some SELECTs, INSERTs or UPDATEs.
Scenario 1
If action of some user needs to execute multiple SELECT statements
(read-only, no plan to write), it needs to start
17 matches
Mail list logo