Re: [sqlite] probably recursive?

2018-05-01 Thread Roman Fleysher
nX is a number, the smallest allowed count. There are two conditions, count of dots along horizontal line and count of dots along verticals. Sent from my T-Mobile 4G LTE Device Original message From: Barry Smith Date: 5/1/18 7:40 PM (GMT-05:00) To:

Re: [sqlite] probably recursive?

2018-05-01 Thread Barry Smith
Ah my bad, I misunderstood the initial condition. nX is a function of X. My statements were only true if nX=X. Well, sorry about the noise. > On 2 May 2018, at 8:20 am, Roman Fleysher > wrote: > > Dear Barry, > > The statement about the square is not obvious

Re: [sqlite] probably recursive?

2018-05-01 Thread Barry Smith
In you initial email, what is n? Some real number between zero and one? > On 2 May 2018, at 8:37 am, Abroży Nieprzełoży > wrote: > > I think Barry mean that you can represent the (x,y) pair as a single > number like (max(X)-min(X))*(Y-min(Y))+X-min(X) or so,

Re: [sqlite] probably recursive?

2018-05-01 Thread Abroży Nieprzełoży
I think Barry mean that you can represent the (x,y) pair as a single number like (max(X)-min(X))*(Y-min(Y))+X-min(X) or so, but I don't see how it would be helpful. 2018-05-02 0:20 GMT+02:00, Roman Fleysher: > Dear Barry, > > The statement about the square is not obvious to me. The requirements

Re: [sqlite] probably recursive?

2018-05-01 Thread Roman Fleysher
Dear Barry, The statement about the square is not obvious to me. The requirements on counts in x and y are different. I also imagine answer could be two or several non-overlapping "rectangles". "Rectangles" will not be densely filled with dots, they might have empty spots either because the

Re: [sqlite] probably recursive?

2018-05-01 Thread Barry Smith
Well those constraints simplify your problem. In the resultant dataset, the largest X and Y values will be equal, and the largest X will have and entry for every coordinate from (X, 1) to (X, X). Likewise the largest Y will have an entry for every coordinate from (1, Y) to (Y, Y). Basically

Re: [sqlite] probably recursive?

2018-05-01 Thread Roman Fleysher
Pairs (x,y) do not repeat. Actual x and y are positive integers, but I do not see how being positive can be relevant. Integer is important for sorting/comparison. Roman From: sqlite-users [sqlite-users-boun...@mailinglists.sqlite.org] on behalf of

Re: [sqlite] probably recursive?

2018-05-01 Thread Barry Smith
Is there a uniqueness constraint on your initial data? Can the same coordinate be listed multiple times? Is there a requirement that X > 0 and Y > 0? > On 2 May 2018, at 3:35 am, Simon Slavin wrote: > >> On 1 May 2018, at 6:28pm, Simon Slavin

[sqlite] Bug in transitive closure extension?

2018-05-01 Thread Charles Leifer
Hi all, I'm noticing a bug in the transitive closure extension in the latest version of SQLite. Reproducing requires the closure extension, which I compiled: gcc -g -fPIC -shared -lsqlite3 closure.c -o closure.so SQL to populate db: .load closure -- create category table with self-referential

Re: [sqlite] Configuring csv extension to use '; ' as column delimiter instead of ',' ?

2018-05-01 Thread David Burgess
For those of you who use SQLite to prepare CSV for import/open into Excel beware of this problem: "Text","Next bit is a reference id","A001" "text","same again","0009" On Windows, In the second row, 3rd column Excel will remove the leading zeroes, if the file has an extension of .csv The same

Re: [sqlite] Configuring csv extension to use '; ' as column delimiter instead of ',' ?

2018-05-01 Thread Peter Da Silva
On 5/1/18, 1:42 PM, "sqlite-users on behalf of R Smith" wrote: My point is that CSV was not necessarily "meant" to be what you say. Who exactly "meant" for it to be that? Because the official stuff

Re: [sqlite] Configuring csv extension to use '; ' as column delimiter instead of ',' ?

2018-05-01 Thread R Smith
On 2018/05/01 8:21 PM, Peter Da Silva wrote: On 5/1/18, 1:15 PM, "sqlite-users on behalf of R Smith" wrote: On 1 May 2018, at 6:43pm, Peter Da Silva wrote: > CSV

Re: [sqlite] Configuring csv extension to use '; ' as column delimiter instead of ',' ?

2018-05-01 Thread Peter Da Silva
On 5/1/18, 1:15 PM, "sqlite-users on behalf of R Smith" wrote: On 1 May 2018, at 6:43pm, Peter Da Silva wrote: > CSV is an interchange format, it's for software to

Re: [sqlite] Configuring csv extension to use '; ' as column delimiter instead of ',' ?

2018-05-01 Thread R Smith
On 1 May 2018, at 6:43pm, Peter Da Silva wrote: CSV is an interchange format, it's for software to communicate with other software, so the syntax needs to be independent of the locale since you don't know if the sender and recipient are in the same locale.

Re: [sqlite] Configuring csv extension to use '; ' as column delimiter instead of ',' ?

2018-05-01 Thread Simon Slavin
On 1 May 2018, at 6:43pm, Peter Da Silva wrote: > CSV is an interchange format, it's for software to communicate with other > software, so the syntax needs to be independent of the locale since you don't > know if the sender and recipient are in the same locale.

Re: [sqlite] Configuring csv extension to use '; ' as column delimiter instead of ',' ?

2018-05-01 Thread Peter Da Silva
To another post hating on Excel - Excel has many flaws, but this is not one of them, it's a fault of the list-separator setting in the Windows OS on which the Excel runs. CSV is an interchange format, it's for software to communicate with other software, so the syntax needs to be

Re: [sqlite] probably recursive?

2018-05-01 Thread Simon Slavin
On 1 May 2018, at 6:28pm, Simon Slavin wrote: > I just realised that That was intended to be personal email. Apologies, everyone. Simon. ___ sqlite-users mailing list sqlite-users@mailinglists.sqlite.org

Re: [sqlite] probably recursive?

2018-05-01 Thread Simon Slavin
On 1 May 2018, at 1:45am, Roman Fleysher wrote: > If x=10 has less than nX dots, all dots with x=10 are deleted. Because of > deletion, y=3 which previously had more than nY dots no longer passes the > threshold and thus y=3 must be deleted too. This could cause

Re: [sqlite] probably recursive?

2018-05-01 Thread Roman Fleysher
Agree. Thank you. Roman From: sqlite-users [sqlite-users-boun...@mailinglists.sqlite.org] on behalf of Simon Slavin [slav...@bigfraud.org] Sent: Tuesday, May 01, 2018 12:50 PM To: SQLite mailing list Subject: Re: [sqlite] probably recursive? On 1 May

Re: [sqlite] Configuring csv extension to use '; ' as column delimiter instead of ',' ?

2018-05-01 Thread R Smith
On 2018/05/01 4:20 PM, Simon Slavin wrote: On 1 May 2018, at 3:01pm, Olivier Mascia wrote: My question was more generic, even though it didn't look that way: the well-known and (maybe too) much-used software tool named Excel tend to encourage people to export "CSV" files

Re: [sqlite] probably recursive?

2018-05-01 Thread Simon Slavin
On 1 May 2018, at 5:34pm, Roman Fleysher wrote: > With recursive route, I am thinking I need to build deleteList(x,y). Rather than actually delete rows, if you can, insert a new column in the table of all points. It starts with every row set to TRUE. When you

Re: [sqlite] Configuring csv extension to use '; ' as column delimiter instead of ',' ?

2018-05-01 Thread Luuk
On 1-5-2018 16:20, Simon Slavin wrote: > On 1 May 2018, at 3:01pm, Olivier Mascia wrote: > >> My question was more generic, even though it didn't look that way: the >> well-known and (maybe too) much-used software tool named Excel tend to >> encourage people to export "CSV"

Re: [sqlite] probably recursive?

2018-05-01 Thread Roman Fleysher
With recursive route, I am thinking I need to build deleteList(x,y). But I can not come up with a way to use deleteList only once in the FROM after UNION and not in subqueries , as required by WITH RECURSIVE. Assuming pairsTable(x,y) is the input table: WITH RECURSIVE deleteList(x, y) AS (

Re: [sqlite] How to Handle BigInt

2018-05-01 Thread Paul Sanderson
Perhaps, but that is only part of the story, and all of that is hidden from the user and is only relevant in terms of how the number is stored on disk. You can define a column as int, smallint, largeint, bigint, etc and, irrespective of which you use, SQLite will save the data to disk

Re: [sqlite] How to Handle BigInt

2018-05-01 Thread Gerry Snyder
From the docs: *INTEGER*. The value is a signed integer, stored in 1, 2, 3, 4, 6, or 8 bytes depending on the magnitude of the value. So perhaps you should have said " SQLite integers are all up to 64 bit." Gerry On Tue, May 1, 2018 at 8:56 AM, Paul Sanderson

Re: [sqlite] How to Handle BigInt

2018-05-01 Thread Paul Sanderson
SQLite integers are all 64 bit - I don't about postgress, so unless postgress allows integers bigger than 64 bit, and you use them, you should be OK with your table definitions above. Paul www.sandersonforensics.com skype: r3scue193 twitter: @sandersonforens Tel +44 (0)1326 572786

[sqlite] How to Handle BigInt

2018-05-01 Thread dmp
Hello, Given a conversion from a database table that contains BigInt, long, field from PostgreSQL to a SQLite similar table. CREATE TABLE postgresqltypes ( data_type_id serial, bigInt_type bigint) CREATE TABLE sqlitetypes ( data_type_id INTEGER PRIMARY KEY AUTOINCREMENT, int_type

Re: [sqlite] Configuring csv extension to use '; ' as column delimiter instead of ',' ?

2018-05-01 Thread Peter Da Silva
Having tried to write a generic clean HANDLES ALL CSV reader for speedtables, I kind of want to burn Excel with nuclear fire, but that's a side issue. :) ___ sqlite-users mailing list sqlite-users@mailinglists.sqlite.org

Re: [sqlite] Configuring csv extension to use '; ' as column delimiter instead of ',' ?

2018-05-01 Thread dave
> From: sqlite-users > [mailto:sqlite-users-boun...@mailinglists.sqlite.org] On > Behalf Of Olivier Mascia > > Considering: > > CREATE VIRTUAL TABLE temp.t1 USING csv(filename='thefile.csv'); > > Is there any way to teach the csv extension to use ';' > instead of ',' as the column delimiter,

Re: [sqlite] probably recursive?

2018-05-01 Thread David Raymond
My initial thought on this would be recursive on delete triggers. You're limited then to SQLITE_MAX_TRIGGER_DEPTH (defaults to 1,000) though, so really big cascades wouldn't fully complete. You can raise the limit, but mathematically speaking there's still going to be a limit then. Will have

Re: [sqlite] Configuring csv extension to use '; ' as column delimiter instead of ',' ?

2018-05-01 Thread Simon Slavin
On 1 May 2018, at 3:01pm, Olivier Mascia wrote: > My question was more generic, even though it didn't look that way: the > well-known and (maybe too) much-used software tool named Excel tend to > encourage people to export "CSV" files which are actually "SCSV" files >

Re: [sqlite] Configuring csv extension to use '; ' as column delimiter instead of ',' ?

2018-05-01 Thread Olivier Mascia
> Le 1 mai 2018 à 14:00, Simon Slavin a écrit : > >> CREATE VIRTUAL TABLE temp.t1 USING csv(filename='thefile.csv'); >> >> Is there any way to teach the csv extension to use ';' instead of ',' as the >> column delimiter, getting away from the strict RFC4180 definition? >

Re: [sqlite] probably recursive?

2018-05-01 Thread R Smith
That depends on what you mean by "Could this be achieved in SQLite?". There is no query (in any SQL engine) that can depend on a sub-query that is itself dependent on the outcome of the main query. This is what makes recursion beautiful, but then there is also no CTE (or other query in any

Re: [sqlite] Configuring csv extension to use '; ' as column delimiter instead of ',' ?

2018-05-01 Thread Simon Slavin
On 1 May 2018, at 11:11am, Olivier Mascia wrote: > CREATE VIRTUAL TABLE temp.t1 USING csv(filename='thefile.csv'); > > Is there any way to teach the csv extension to use ';' instead of ',' as the > column delimiter, getting away from the strict RFC4180 definition? The source

[sqlite] Configuring csv extension to use '; ' as column delimiter instead of ',' ?

2018-05-01 Thread Olivier Mascia
Considering: CREATE VIRTUAL TABLE temp.t1 USING csv(filename='thefile.csv'); Is there any way to teach the csv extension to use ';' instead of ',' as the column delimiter, getting away from the strict RFC4180 definition? -- Best Regards, Meilleures salutations, Met vriendelijke groeten,

Re: [sqlite] unknown type name 'sqlite_int64'

2018-05-01 Thread jungle boogie
Thus said Igor Korot on Mon, 30 Apr 2018 20:28:54 -0500 Why did you need configure? Turns out I needed to disable editline and readline, but it eventually builds! thanks for the input. And yes, I am ignoring you awareessi555 AT safenmeet.xyz Just do make. Thank you.