[sqlite] System.Data.SQLite version 1.0.105.0 released

2017-04-08 Thread Joe Mistachkin

System.Data.SQLite version 1.0.105.0 (with SQLite 3.18.0) is now available
on the System.Data.SQLite website:

 https://system.data.sqlite.org/

Further information about this release can be seen at:

 https://system.data.sqlite.org/index.html/doc/trunk/www/news.wiki

Please post on the SQLite mailing list (sqlite-users at sqlite.org) if you
encounter any problems with this release.

--
Joe Mistachkin @ https://urn.to/r/mistachkin

___
sqlite-users mailing list
sqlite-users@mailinglists.sqlite.org
http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users


Re: [sqlite] json() number value parsing

2017-04-08 Thread Jens Alfke

> On Apr 7, 2017, at 5:26 PM, Rolf Ade  wrote:
> 
> If I read RFC 7159 (http://www.rfc-editor.org/rfc/rfc7159.txt 
> ) correct
> this should return: "Error: malformed JSON".

In this case I would go with Postel’s Law, paraphrased as “Be strict in what 
you write, but lenient in what you read.” I don’t see a point in disallowing 
something as trivial as redundant leading zeroes.

—Jens
___
sqlite-users mailing list
sqlite-users@mailinglists.sqlite.org
http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users


Re: [sqlite] Selecting from view with System.Data.SQLite throws

2017-04-08 Thread Joseph L. Casale
From: sqlite-users [mailto:sqlite-users-boun...@mailinglists.sqlite.org] On
Behalf Of Joe Mistachkin
Sent: Saturday, April 8, 2017 1:18 PM
To: SQLite mailing list 
Subject: Re: [sqlite] Selecting from view with System.Data.SQLite throws

> What is the declared data type for the column?  Also, what are the raw
> values for the first row?  You may want to use the SQLite command line tool
> to query the database for them.

I was selecting from all columns which were declared as either INT or TEXT.
I resolved it unintentionally by removing an alias as it was a single select on
the one view and did not need any aliasing.

The command text went from:

 SELECT s.Id, s.foo ...
  FROM SomeView s
WHERE s.bar = @bar;

to:

SELECT Id, foo ...
  FROM SomeView
WHERE bar = @bar;

Odd...

Thanks,
jlc
___
sqlite-users mailing list
sqlite-users@mailinglists.sqlite.org
http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users


Re: [sqlite] Selecting from view with System.Data.SQLite throws

2017-04-08 Thread Joe Mistachkin

What is the declared data type for the column?  Also, what are the raw values 
for the first row?  You may want to use the SQLite command line tool to query 
the database for them.

Sent from my iPhone
https://urn.to/r/mistachkin

> On Apr 8, 2017, at 12:55 PM, Joseph L. Casale  
> wrote:
> 
> I am using System.Data.SQLite.Core 1.0.104 in vs2017 with .NET 4.6.2
> and trying to select from a view. The query is valid and does return data
> manually, however the reader throws an index out of range exception
> when accessing the first row result.
> 
> Anything atypical needed when querying a view?
> 
> Thanks,
> jlc
> ___
> sqlite-users mailing list
> sqlite-users@mailinglists.sqlite.org
> http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users
> 

___
sqlite-users mailing list
sqlite-users@mailinglists.sqlite.org
http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users


[sqlite] Selecting from view with System.Data.SQLite throws

2017-04-08 Thread Joseph L. Casale
I am using System.Data.SQLite.Core 1.0.104 in vs2017 with .NET 4.6.2
and trying to select from a view. The query is valid and does return data
manually, however the reader throws an index out of range exception
when accessing the first row result.

Anything atypical needed when querying a view?

Thanks,
jlc
___
sqlite-users mailing list
sqlite-users@mailinglists.sqlite.org
http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users


Re: [sqlite] Sqlite + Dropbox

2017-04-08 Thread Bob Friesenhahn

On Fri, 7 Apr 2017, Warren Young wrote:


None of that solve the core problems you identified which make Dropbox a poor 
choice for sharing a SQLite DB over the Internet.


It seems like there should not be a problem if sqlite's backup 
mechanism is always used to produce the database shared with the 
Internet rather than exposing the live database to Dropbox.  This 
still assumes that the database is only updated at one point or there 
is some way to assure that the database is only updated from one 
computer at a time and the file is backed up to Dropbox before another 
computer accesses it.


Bob
--
Bob Friesenhahn
bfrie...@simple.dallas.tx.us, http://www.simplesystems.org/users/bfriesen/
GraphicsMagick Maintainer,http://www.GraphicsMagick.org/
___
sqlite-users mailing list
sqlite-users@mailinglists.sqlite.org
http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users


Re: [sqlite] Create view from a single table as one to many

2017-04-08 Thread Joseph L. Casale
From: sqlite-users [mailto:sqlite-users-boun...@mailinglists.sqlite.org] On
Behalf Of Clemens Ladisch
Sent: Saturday, April 8, 2017 7:15 AM
To: sqlite-users@mailinglists.sqlite.org
Subject: Re: [sqlite] Create view from a single table as one to many

> Join that table with the table that contains the enum values:
> 
>   SELECT ... FROM t1 JOIN enums ON t1.flags & enums.bit != 0;
> 
> 
> Regards,
> Clemens

Heh,
I can't believe I missed that:) I'll add a table with the enum values.

Thanks Clemens,
jlc

___
sqlite-users mailing list
sqlite-users@mailinglists.sqlite.org
http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users


Re: [sqlite] Create view from a single table as one to many

2017-04-08 Thread Clemens Ladisch
Joseph L. Casale wrote:
> I have a table t1 that I am trying to create a view from where the
> view will produce many rows for each row in t1. The resulting data
> is a set of rows which assign a text string for each bit flag present in
> a column in t1 from an enum I reference.
>
> How does one construct such a view?

Join that table with the table that contains the enum values:

  SELECT ... FROM t1 JOIN enums ON t1.flags & enums.bit != 0;


Regards,
Clemens
___
sqlite-users mailing list
sqlite-users@mailinglists.sqlite.org
http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users


[sqlite] Create view from a single table as one to many

2017-04-08 Thread Joseph L. Casale
I have a table t1 that I am trying to create a view from where the
view will produce many rows for each row in t1. The resulting data
is a set of rows which assign a text string for each bit flag present in
a column in t1 from an enum I reference.

How does one construct such a view?

Thanks,
jlc
___
sqlite-users mailing list
sqlite-users@mailinglists.sqlite.org
http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users


[sqlite] json() number value parsing

2017-04-08 Thread Rolf Ade


> ./sqlite3 
SQLite version 3.19.0 2017-04-07 20:20:08
[...]
sqlite> select json(' { "this" : 000.23 } ');
{"this":000.23}

If I read RFC 7159 (http://www.rfc-editor.org/rfc/rfc7159.txt) correct
this should return: "Error: malformed JSON".

http://sqlite.org/json1.html say, the json1 support "is disabled by
default". If I build from check-out just with ./configure it is
available, I think.

___
sqlite-users mailing list
sqlite-users@mailinglists.sqlite.org
http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users