Re: [sqlite] Not SQLite related, but, SQLite Mailing List related

2014-08-12 Thread Simon Slavin

On 13 Aug 2014, at 3:22am, Scott Robison  wrote:

> I'm pretty sure vi vs emacs was the first browser war. Or IBM vs MAC. Or
> FORTRAN vs COBOL. One of those, anyway.

EBCDIC vs. SIXBIT.

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


Re: [sqlite] Not SQLite related, but, SQLite Mailing List related

2014-08-12 Thread Scott Robison
On Tue, Aug 12, 2014 at 8:16 PM, jose isaias cabrera <
jic...@cinops.xerox.com> wrote:

> "Stephen Chrzanowski" wrote...
>
>  *thinks back to IE1 and Netscape*
>>
>> Its just starting??
>>
>
> True. (WebCrawler anyone?)
>

I'm pretty sure vi vs emacs was the first browser war. Or IBM vs MAC. Or
FORTRAN vs COBOL. One of those, anyway.

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


Re: [sqlite] Not SQLite related, but, SQLite Mailing List related

2014-08-12 Thread jose isaias cabrera

"Stephen Chrzanowski" wrote...


*thinks back to IE1 and Netscape*

Its just starting??


True. (WebCrawler anyone?)



On Tue, Aug 12, 2014 at 7:15 PM, jose isaias cabrera <
jic...@cinops.xerox.com> wrote:


"Stephen Chrzanowski" wrote...

 Thanks Jose, this looks to be like a browser issue.  Tried with Chrome 
and

the buttons are there and working.  Wonder if Google is trying to say
something? {smirk}



Google is trying to say something, very clear.  The browser wars is just
starting.

josé
___
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-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users


Re: [sqlite] Not SQLite related, but, SQLite Mailing List related

2014-08-12 Thread Stephen Chrzanowski
*thinks back to IE1 and Netscape*

Its just starting??


On Tue, Aug 12, 2014 at 7:15 PM, jose isaias cabrera <
jic...@cinops.xerox.com> wrote:

> "Stephen Chrzanowski" wrote...
>
>  Thanks Jose, this looks to be like a browser issue.  Tried with Chrome and
>> the buttons are there and working.  Wonder if Google is trying to say
>> something? {smirk}
>>
>
> Google is trying to say something, very clear.  The browser wars is just
> starting.
>
> josé
> ___
> 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


Re: [sqlite] SQLite relative dates and join query help

2014-08-12 Thread Keith Medcalf

I don't think you want max() around collections.book_in_date.  You want the 
max(collection_date) but the book_in_date from that row.  Since the 
collection_date is unique, the book_in_date can only come from one record.

>-Original Message-
>From: sqlite-users-boun...@sqlite.org [mailto:sqlite-users-
>boun...@sqlite.org] On Behalf Of Petite Abeille
>Sent: Tuesday, 12 August, 2014 12:15
>To: General Discussion of SQLite Database
>Subject: Re: [sqlite] SQLite relative dates and join query help
>
>
>On Aug 12, 2014, at 7:38 PM, Ben  wrote:
>
>> The result I'm after is:
>>
>> id, prod_code, creation_date, last_book_in_date, last_collection_date
>>
>> Where the final two columns are from the collection which is the
>farthest in the future, but still within the 50-day period from creation.
>
>Perhaps something along these lines:
>
>selectitems.id,
>  items.prod_code,
>  items.creation_date,
>  max( collections.book_in_date ) as last_book_in_date,
>  max( collection_date ) as last_collection_date
>from  items
>
>join  collections
>oncollections.id = items.collection_id
>
>where collections.book_in_date between items.creation_date and
>items.creation_date + 50
>and   collections.collection_date between items.creation_date and
>items.creation_date + 50
>
>group by  items.id,
>  items.prod_code,
>  items.creation_date
>
>N.B.
>
>There is no 'date' type in SQLite. Will assume something else, say, a
>Julian number for ease of date manipulation.
>
>> Should I instead be processing this in the application rather than
>database?
>
>No. A database is the perfect place to process data.
>
>___
>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


Re: [sqlite] Crash in sqlite3_mutex_try [Was: SQLite 3.8.6 beta]

2014-08-12 Thread jose isaias cabrera

"Richard Hipp" wrote...



On Tue, Aug 12, 2014 at 6:50 PM, jose isaias cabrera <
jic...@cinops.xerox.com> wrote:



"Klaas V" wrote...



Jan wrote: " ** can manually set this value to 1 to emulate Win98
behavior.
*/"

Can anyone give me one good reason apart from nostalgia to support a MS
system not supported by MS?



There are 1000's of reason$ why, but if some win98 machines are doing 
jobs

that are working perfectly without any need to upgrade, why upgrade them?
If things are working correctly, why break it?  I am one of those that do
not upgrade just because.



So if your old win98 machine is working perfectly, why do you need the
latest version of SQLite?  Won't an older version of SQLite that *does*
support win98 and that has been working perfectly for all these years
suffice?


I don't have any win98 machine. I was just responding to the question,


Can anyone give me one good reason apart from nostalgia to support a MS
system not supported by MS?


But, I don't have any issues with win98. :-)

josé

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


Re: [sqlite] Not SQLite related, but, SQLite Mailing List related

2014-08-12 Thread jose isaias cabrera

"Stephen Chrzanowski" wrote...

Thanks Jose, this looks to be like a browser issue.  Tried with Chrome and
the buttons are there and working.  Wonder if Google is trying to say
something? {smirk}


Google is trying to say something, very clear.  The browser wars is just 
starting.


josé 


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


Re: [sqlite] Crash in sqlite3_mutex_try [Was: SQLite 3.8.6 beta]

2014-08-12 Thread Richard Hipp
On Tue, Aug 12, 2014 at 6:50 PM, jose isaias cabrera <
jic...@cinops.xerox.com> wrote:

>
> "Klaas V" wrote...
>
>
>> Jan wrote: " ** can manually set this value to 1 to emulate Win98
>> behavior.
>> */"
>>
>> Can anyone give me one good reason apart from nostalgia to support a MS
>> system not supported by MS?
>>
>
> There are 1000's of reason$ why, but if some win98 machines are doing jobs
> that are working perfectly without any need to upgrade, why upgrade them?
> If things are working correctly, why break it?  I am one of those that do
> not upgrade just because.
>

So if your old win98 machine is working perfectly, why do you need the
latest version of SQLite?  Won't an older version of SQLite that *does*
support win98 and that has been working perfectly for all these years
suffice?

-- 
D. Richard Hipp
d...@sqlite.org
___
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users


Re: [sqlite] Crash in sqlite3_mutex_try [Was: SQLite 3.8.6 beta]

2014-08-12 Thread jose isaias cabrera


"Klaas V" wrote...


Jan wrote: " ** can manually set this value to 1 to emulate Win98 
behavior.

*/"

Can anyone give me one good reason apart from nostalgia to support a MS 
system not supported by MS?


There are 1000's of reason$ why, but if some win98 machines are doing jobs 
that are working perfectly without any need to upgrade, why upgrade them? 
If things are working correctly, why break it?  I am one of those that do 
not upgrade just because.


josé 


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


Re: [sqlite] HELP sqlite3 used in vxworks has someproblem?

2014-08-12 Thread Andy Ling
OK, thanks.

It isn't limited to 8+3. The dosFs name refers to the FAT nature of the file 
system, not any filename limitations. In fact files don't have to have a 
.extension.

Regards

Andy Ling


From: sqlite-users-boun...@sqlite.org [sqlite-users-boun...@sqlite.org] on 
behalf of Richard Hipp [d...@sqlite.org]
Sent: 12 August 2014 20:59
To: General Discussion of SQLite Database
Subject: Re: [sqlite]   HELP sqlite3 used in vxworks has someproblem?

On Tue, Aug 12, 2014 at 3:54 PM, Andy Ling  wrote:

>
> I did wonder if SQLite was making any assumptions about current
> directories or the makeup of a file name.
>

No.  Any filename will do.

You have to specify -DSQLITE_ENABLE_8_3_NAMES if your filesystem is limited
to 8+3 filenames, however.

--
D. Richard Hipp
d...@sqlite.org
___
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] 2nd Call For Papers, 21th Annual Tcl/Tk Conference 2014

2014-08-12 Thread Andreas Kupries
21'th Annual Tcl/Tk Conference (Tcl'2014)
http://www.tcl.tk/community/tcl2014/

[ It is 4 weeks to the deadline for Abstracts and proposals ... ]

November 10 - 14, 2014
Embassy Suites Downtown
Portland, Oregon, USA

Important Dates:

Abstracts and proposals due Sep  8, 2014
Notification to authors Sep 22, 2014
Author materials dueOct 20, 2014
Tutorials start Nov 10, 2014
Conference starts   Nov 12, 2014

[[ 
Registration is open.
]]

Email Contact:tclconfere...@googlegroups.com

Submission of Summaries

Tcl/Tk 2014 will be held in Portland, Oregon, USA from November
10 - 14, 2014. The program committee is asking for papers and
presentation proposals from anyone using or developing with Tcl/Tk
(and extensions). Past conferences have seen submissions covering a
wide variety of topics including:

* Scientific and engineering applications
* Industrial controls
* Distributed applications and Network Managment
* Object oriented extensions to Tcl/Tk
* New widgets for Tk
* Simulation and application steering with Tcl/Tk
* Tcl/Tk-centric operating environments
* Tcl/Tk on small and embedded devices
* Medical applications and visualization
* Use of different programming paradigms in Tcl/Tk and proposals for new
  directions.
* New areas of exploration for the Tcl/Tk language

Submissions should consist of an abstract of about 100 words and a
summary of not more than two pages, and should be sent as plain text
to  no later than August 5,
2014. Authors of accepted abstracts will have until September 2, 2014
to submit their final paper for the inclusion in the conference
proceedings. The proceedings will be made available on digital media,
so extra materials such as presentation slides, code examples, code
for extensions etc. are encouraged.

Printed proceedings will be produced as an on-demand book at lulu.com

The authors will have 25 minutes to present their paper at the
conference.

The program committee will review and evaluate papers according to the
following criteria:

* Quantity and quality of novel content
* Relevance and interest to the Tcl/Tk community
* Suitability of content for presentation at the conference

Proposals may report on commercial or non-commercial systems, but
those with only blatant marketing content will not be accepted.

Application and experience papers need to strike a balance between
background on the application domain and the relevance of Tcl/Tk to
the application. Application and experience papers should clearly
explain how the application or experience illustrates a novel use of
Tcl/Tk, and what lessons the Tcl/Tk community can derive from the
application or experience to apply to their own development efforts.

Papers accompanied by non-disclosure agreements will be returned to
the author(s) unread. All submissions are held in the highest
confidentiality prior to publication in the Proceedings, both as a
matter of policy and in accord with the U. S. Copyright Act of 1976.

The primary author for each accepted paper will receive registration
to the Technical Sessions portion of the conference at a reduced rate.

Other Forms of Participation

The program committee also welcomes proposals for panel discussions of
up to 90 minutes. Proposals should include a list of confirmed
panelists, a title and format, and a panel description with position
statements from each panelist. Panels should have no more than four
speakers, including the panel moderator, and should allow time for
substantial interaction with attendees. Panels are not presentations
of related research papers.

Slots for Works-in-Progress (WIP) presentations and Birds-of-a-Feather
sessions (BOFs) are available on a first-come, first-served basis.
WIP slots can be reserved like any paper proposal. BOF slots will be
managed on-site. All attendees with an interesting work in progress
should consider reserving a WIP slot.

Registration Information

More information on the conference is available the conference Web
site (http://www.tcl.tk/community/tcl2014/) and will be published on
various Tcl/Tk-related information channels.

Registration is open.

To keep in touch with news regarding the conference and Tcl events in
general, subscribe to the tcl-announce list. See:
http://code.activestate.com/lists/tcl-announce to subscribe to the
tcl-announce mailing list.


Conference Committee

Clif Flynt  Noumena Corp   General Chair, Website 
Admin
Andreas Kupries ActiveState Software Inc.  Program Chair
Brian Griffin   Mentor GraphicsSite/Facilities Chair
Arjen MarkusDeltares
Cyndy Lilagan   Nat. Museum of Health & Medicine, Chicago
Donal Fellows   University of Manchester
Gerald Lester   KnG Consulting, LLC
Jeffrey Hobbs   ActiveState Software Inc.
Kevin Kenny GE Global Research Center
Larry Virden
Mike Doyle  National 

Re: [sqlite] HELP sqlite3 used in vxworks has someproblem?

2014-08-12 Thread Richard Hipp
On Tue, Aug 12, 2014 at 3:54 PM, Andy Ling  wrote:

>
> I did wonder if SQLite was making any assumptions about current
> directories or the makeup of a file name.
>

No.  Any filename will do.

You have to specify -DSQLITE_ENABLE_8_3_NAMES if your filesystem is limited
to 8+3 filenames, however.

-- 
D. Richard Hipp
d...@sqlite.org
___
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users


Re: [sqlite] HELP sqlite3 used in vxworks has someproblem?

2014-08-12 Thread Andy Ling
Our code is already creating lots of files in /ata0:3 without any problem. This 
is quite a mature product that is working well and is exercising the hardware 
and drivers extensively. The database is a new feature to initially provide 
persistence of some data. So I am confident there is nothing wrong with the 
disk or its drivers.

I did wonder if SQLite was making any assumptions about current directories or 
the makeup of a file name. /ata0:3 is an unusual format for a directory name.

Anyway, a simple printf in unixDelete tomorrow will reveal all.

Regards

Andy Ling


From: sqlite-users-boun...@sqlite.org [sqlite-users-boun...@sqlite.org] on 
behalf of Simon Slavin [slav...@bigfraud.org]
Sent: 12 August 2014 20:16
To: General Discussion of SQLite Database
Subject: Re: [sqlite] HELP sqlite3 used in vxworks has someproblem?

On 12 Aug 2014, at 7:46pm, Andy Ling  wrote:

> I can tell you the name of the database file is /ata0:3/testdb.sql and it 
> gets created.

Can you add some commands to one of your apps using the library which create 
and delete a file in '/ata0:3/' and see they work ?  In other words, duplicate 
what SQLite is trying to do in your own code and see if your code has the same 
problem.

Simon.
___
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


Re: [sqlite] HELP sqlite3 used in vxworks has someproblem?

2014-08-12 Thread Simon Slavin

On 12 Aug 2014, at 7:46pm, Andy Ling  wrote:

> I can tell you the name of the database file is /ata0:3/testdb.sql and it 
> gets created.

Can you add some commands to one of your apps using the library which create 
and delete a file in '/ata0:3/' and see they work ?  In other words, duplicate 
what SQLite is trying to do in your own code and see if your code has the same 
problem.

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


Re: [sqlite] HELP sqlite3 used in vxworks has someproblem?

2014-08-12 Thread Richard Hipp
On Tue, Aug 12, 2014 at 2:46 PM, Andy Ling  wrote:

>  I don't know. The standard debug doesn't print the name, so I will have
> to add something tomorrow.
>
> I can tell you the name of the database file is /ata0:3/testdb.sql and it
> gets created.
>
> It is possible things are working. It is just that the sqlite3_exec is not
> returning SQLITE_OK, so I give up and print an error.
>
> I wonder if before the check was added to unixDelete all unlink errors
> were ignored.
>

No.  The situation is that SQLite very rarely tries to unlink a file that
does not exist.  Very, very rarely.  So the error never came up for the
first eight years.

If your build is frequently trying to unlink a file that does not exist,
then something is wrong.  We need to figure out what that is and fix it.




> So it would have worked just fine and you wouldn't have known it was
> trying to delete files that didn't exist.
>
> I will investigate further tomorrow and let you know the file names.
>
> Regards
>
> Andy Ling
>
>  --
> *From:* drhsql...@gmail.com [drhsql...@gmail.com] on behalf of Richard
> Hipp [d...@sqlite.org]
> *Sent:* 12 August 2014 19:15
>
> *To:* Andy Ling
> *Cc:* General Discussion of SQLite Database; 王庆刚
> *Subject:* Re: [sqlite] HELP sqlite3 used in vxworks has someproblem?
>
>   What is the name of the file that SQLite is trying to delete but which
> does not exist?  And what is the name of the corresponding database file?
> The name of the file that fails unlink() will give us a big clue about what
> is going wrong.
>
>
> On Tue, Aug 12, 2014 at 2:13 PM, Richard Hipp  wrote:
>
>>
>>
>>
>> On Tue, Aug 12, 2014 at 2:00 PM, Andy Ling  wrote:
>>
>>> Because the file doesn't exist. I assume because this is a brand new
>>> database the file hasn't been created yet.
>>>
>>> I did debug this originally, but I don't remember the file it is trying
>>> to delete. It definitely didn't exist though.
>>>
>>> To some extent it doesn't really matter. The unixDelete function on
>>> vxWorks with dosFs is broken for files that don't exist, so some change is
>>> needed.
>>>
>>
>>  That check to ignore the error when trying to delete a file that does
>> not exist - that check was only added less than 2 years ago, 2012-11-10.
>> So for the first 8 years of its history, billions of instances of SQLite3
>> got along fine without that check.  This is not surprising since an attempt
>> to delete a file that does not exist should only come up in very rare
>> circumstances.
>>
>> So we can update the unixDelete routine for that.
>>
>>  But, the fact that your build of SQLite does not work *at all* without
>> such a change suggests that there are other problems - problems that are
>> being masked, but not resolved, by the unixDelete change.  I'm trying
>> figure out what those other problems are.
>>
>>
>>
>> --
>> D. Richard Hipp
>> d...@sqlite.org
>>
>
>
>
> --
> D. Richard Hipp
> d...@sqlite.org
>



-- 
D. Richard Hipp
d...@sqlite.org
___
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users


Re: [sqlite] HELP sqlite3 used in vxworks has someproblem?

2014-08-12 Thread Andy Ling
I don't know. The standard debug doesn't print the name, so I will have to add 
something tomorrow.

I can tell you the name of the database file is /ata0:3/testdb.sql and it gets 
created.

It is possible things are working. It is just that the sqlite3_exec is not 
returning SQLITE_OK, so I give up and print an error.

I wonder if before the check was added to unixDelete all unlink errors were 
ignored. So it would have worked just fine and you wouldn't have known it was 
trying to delete files that didn't exist.

I will investigate further tomorrow and let you know the file names.

Regards

Andy Ling


From: drhsql...@gmail.com [drhsql...@gmail.com] on behalf of Richard Hipp 
[d...@sqlite.org]
Sent: 12 August 2014 19:15
To: Andy Ling
Cc: General Discussion of SQLite Database; 王庆刚
Subject: Re: [sqlite] HELP sqlite3 used in vxworks has someproblem?

What is the name of the file that SQLite is trying to delete but which does not 
exist?  And what is the name of the corresponding database file?  The name of 
the file that fails unlink() will give us a big clue about what is going wrong.


On Tue, Aug 12, 2014 at 2:13 PM, Richard Hipp 
> wrote:



On Tue, Aug 12, 2014 at 2:00 PM, Andy Ling 
> wrote:
Because the file doesn't exist. I assume because this is a brand new database 
the file hasn't been created yet.

I did debug this originally, but I don't remember the file it is trying to 
delete. It definitely didn't exist though.

To some extent it doesn't really matter. The unixDelete function on vxWorks 
with dosFs is broken for files that don't exist, so some change is needed.

That check to ignore the error when trying to delete a file that does not exist 
- that check was only added less than 2 years ago, 2012-11-10.  So for the 
first 8 years of its history, billions of instances of SQLite3 got along fine 
without that check.  This is not surprising since an attempt to delete a file 
that does not exist should only come up in very rare circumstances.

So we can update the unixDelete routine for that.

But, the fact that your build of SQLite does not work *at all* without such a 
change suggests that there are other problems - problems that are being masked, 
but not resolved, by the unixDelete change.  I'm trying figure out what those 
other problems are.



--
D. Richard Hipp
d...@sqlite.org



--
D. Richard Hipp
d...@sqlite.org
___
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users


Re: [sqlite] HELP sqlite3 used in vxworks has someproblem?

2014-08-12 Thread Richard Hipp
What is the name of the file that SQLite is trying to delete but which does
not exist?  And what is the name of the corresponding database file?  The
name of the file that fails unlink() will give us a big clue about what is
going wrong.


On Tue, Aug 12, 2014 at 2:13 PM, Richard Hipp  wrote:

>
>
>
> On Tue, Aug 12, 2014 at 2:00 PM, Andy Ling  wrote:
>
>> Because the file doesn't exist. I assume because this is a brand new
>> database the file hasn't been created yet.
>>
>> I did debug this originally, but I don't remember the file it is trying
>> to delete. It definitely didn't exist though.
>>
>> To some extent it doesn't really matter. The unixDelete function on
>> vxWorks with dosFs is broken for files that don't exist, so some change is
>> needed.
>>
>
> That check to ignore the error when trying to delete a file that does not
> exist - that check was only added less than 2 years ago, 2012-11-10.  So
> for the first 8 years of its history, billions of instances of SQLite3 got
> along fine without that check.  This is not surprising since an attempt to
> delete a file that does not exist should only come up in very rare
> circumstances.
>
> So we can update the unixDelete routine for that.
>
> But, the fact that your build of SQLite does not work *at all* without
> such a change suggests that there are other problems - problems that are
> being masked, but not resolved, by the unixDelete change.  I'm trying
> figure out what those other problems are.
>
>
>
> --
> D. Richard Hipp
> d...@sqlite.org
>



-- 
D. Richard Hipp
d...@sqlite.org
___
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users


Re: [sqlite] SQLite relative dates and join query help

2014-08-12 Thread Petite Abeille

On Aug 12, 2014, at 7:38 PM, Ben  wrote:

> The result I'm after is:
> 
> id, prod_code, creation_date, last_book_in_date, last_collection_date
> 
> Where the final two columns are from the collection which is the farthest in 
> the future, but still within the 50-day period from creation.

Perhaps something along these lines:

selectitems.id,
  items.prod_code,
  items.creation_date,
  max( collections.book_in_date ) as last_book_in_date,
  max( collection_date ) as last_collection_date
from  items

join  collections
oncollections.id = items.collection_id

where collections.book_in_date between items.creation_date and 
items.creation_date + 50
and   collections.collection_date between items.creation_date and 
items.creation_date + 50

group by  items.id,
  items.prod_code,
  items.creation_date

N.B.

There is no ‘date’ type in SQLite. Will assume something else, say, a Julian 
number for ease of date manipulation.

> Should I instead be processing this in the application rather than database?

No. A database is the perfect place to process data.

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


Re: [sqlite] HELP sqlite3 used in vxworks has someproblem?

2014-08-12 Thread Richard Hipp
On Tue, Aug 12, 2014 at 2:00 PM, Andy Ling  wrote:

> Because the file doesn't exist. I assume because this is a brand new
> database the file hasn't been created yet.
>
> I did debug this originally, but I don't remember the file it is trying to
> delete. It definitely didn't exist though.
>
> To some extent it doesn't really matter. The unixDelete function on
> vxWorks with dosFs is broken for files that don't exist, so some change is
> needed.
>

That check to ignore the error when trying to delete a file that does not
exist - that check was only added less than 2 years ago, 2012-11-10.  So
for the first 8 years of its history, billions of instances of SQLite3 got
along fine without that check.  This is not surprising since an attempt to
delete a file that does not exist should only come up in very rare
circumstances.

So we can update the unixDelete routine for that.

But, the fact that your build of SQLite does not work *at all* without such
a change suggests that there are other problems - problems that are being
masked, but not resolved, by the unixDelete change.  I'm trying figure out
what those other problems are.



-- 
D. Richard Hipp
d...@sqlite.org
___
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users


Re: [sqlite] SQLite relative dates and join query help

2014-08-12 Thread Luuk

On 12-8-2014 19:38, Ben wrote:

I'm trying to solve the following problem in SQLite:

Items are being produced with a short, fixed shelf life. Say 50 days.
Item can be collected every two weeks, where each item must be registered a 
week before.

I am trying to create a query where I can list current items and the latest day 
they can be registered/collected.

Given the tables:

CREATE TABLE "items" (
"id" INTEGER PRIMARY KEY,
"prod_code" TEXT UNIQUE,
"creation_date" DATE,
"collection_id" INTEGER REFERENCES "collections"("id"), -- for when it's been 
booked for collection
)
CREATE TABLE "collections" (
"id" INTEGER PRIMARY KEY,
"book_in_date" DATE,
"collection_date" DATE UNIQUE
)

The result I'm after is:

id, prod_code, creation_date, last_book_in_date, last_collection_date

Where the final two columns are from the collection which is the farthest in 
the future, but still within the 50-day period from creation.


I think this sort of problem would require a subquery, but I can't seem to pass 
the creation_date of an item to a subquery for collections. Should I instead be 
processing this in the application rather than database?

Can anyone point me in the right direction for how to approach this kind of 
problem?

Thank you,

Ben



untested:
SELECT i.id, prod_code, creation_date,
max(c1.book_in_date) last_book_in_date,
max(c2.collection_date) last_collection_date
FROM items i
INNER JOIN collections c1 ON c1.id=i.id
INNER JOIN collections c2 ON c2.id=i.id
GROUP BY i.id, prod_code, creation_date

to finish you homework, you have to add the 50 day period yourself ;)


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


Re: [sqlite] HELP sqlite3 used in vxworks has someproblem?

2014-08-12 Thread Andy Ling
Because the file doesn't exist. I assume because this is a brand new database 
the file hasn't been created yet. 

I did debug this originally, but I don't remember the file it is trying to 
delete. It definitely didn't exist though. 

To some extent it doesn't really matter. The unixDelete function on vxWorks 
with dosFs is broken for files that don't exist, so some change is needed. The 
patch I sent is what Jan and I came up with. 

Regards 
 
Andy Ling  

From: drhsql...@gmail.com [drhsql...@gmail.com] on behalf of Richard Hipp 
[d...@sqlite.org]
Sent: 12 August 2014 18:01
To: Andy Ling
Cc: General Discussion of SQLite Database; 王庆刚
Subject: Re: [sqlite] HELP sqlite3 used in vxworks has someproblem?

On Tue, Aug 12, 2014 at 12:45 PM, Andy Ling 
> wrote:
Doing a create table generates a disk I/O error

I open / create a new database with sqlite3_open_v2

  int err = sqlite3_open_v2 (file, , SQLITE_OPEN_READWRITE | 
SQLITE_OPEN_CREATE, "unix-namedsem") ;

Then call sqlite3_exec with “CREATE TABLE t (id INTEGER PRIMARY KEY ASC)”

This generates a disk I/O error. I assume it is trying to remove a temporary 
file.


It might be trying to unlink the rollback journal to commit the transaction.  
But why is that generating an error?  The file exists, so it shouldn't be 
generating a FILE_NOT_FOUND error...


--
D. Richard Hipp
d...@sqlite.org
___
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users


[sqlite] SQLite relative dates and join query help

2014-08-12 Thread Ben
I'm trying to solve the following problem in SQLite:

Items are being produced with a short, fixed shelf life. Say 50 days. 
Item can be collected every two weeks, where each item must be registered a 
week before.

I am trying to create a query where I can list current items and the latest day 
they can be registered/collected.

Given the tables:

CREATE TABLE "items" (
"id" INTEGER PRIMARY KEY,
"prod_code" TEXT UNIQUE,
"creation_date" DATE,
"collection_id" INTEGER REFERENCES "collections"("id"), -- for when it's been 
booked for collection
)
CREATE TABLE "collections" (
"id" INTEGER PRIMARY KEY,
"book_in_date" DATE,
"collection_date" DATE UNIQUE
)

The result I'm after is:

id, prod_code, creation_date, last_book_in_date, last_collection_date

Where the final two columns are from the collection which is the farthest in 
the future, but still within the 50-day period from creation.


I think this sort of problem would require a subquery, but I can't seem to pass 
the creation_date of an item to a subquery for collections. Should I instead be 
processing this in the application rather than database?

Can anyone point me in the right direction for how to approach this kind of 
problem? 

Thank you,

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


Re: [sqlite] HELP sqlite3 used in vxworks has someproblem?

2014-08-12 Thread Richard Hipp
On Tue, Aug 12, 2014 at 12:45 PM, Andy Ling  wrote:

>  Doing a create table generates a disk I/O error
>
>
>
> I open / create a new database with sqlite3_open_v2
>
>
>
>   *int* err = sqlite3_open_v2 (file, , SQLITE_OPEN_READWRITE |
> SQLITE_OPEN_CREATE, "unix-namedsem") ;
>
>
>
> Then call sqlite3_exec with “CREATE TABLE t (id INTEGER PRIMARY KEY ASC)”
>
>
>
> This generates a disk I/O error. I assume it is trying to remove a
> temporary file.
>
>
>
It might be trying to unlink the rollback journal to commit the
transaction.  But why is that generating an error?  The file exists, so it
shouldn't be generating a FILE_NOT_FOUND error...


-- 
D. Richard Hipp
d...@sqlite.org
___
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users


Re: [sqlite] HELP sqlite3 used in vxworks has someproblem?

2014-08-12 Thread Andy Ling
Doing a create table generates a disk I/O error

I open / create a new database with sqlite3_open_v2

  int err = sqlite3_open_v2 (file, , SQLITE_OPEN_READWRITE | 
SQLITE_OPEN_CREATE, "unix-namedsem") ;

Then call sqlite3_exec with “CREATE TABLE t (id INTEGER PRIMARY KEY ASC)”

This generates a disk I/O error. I assume it is trying to remove a temporary 
file.

Regards

Andy Ling


From: drhsql...@gmail.com [mailto:drhsql...@gmail.com] On Behalf Of Richard Hipp
Sent: 12 August 2014 17:24
To: Andy Ling
Cc: General Discussion of SQLite Database; 王庆刚
Subject: Re: [sqlite] HELP sqlite3 used in vxworks has someproblem?



On Tue, Aug 12, 2014 at 11:40 AM, Andy Ling 
> wrote:
> From: drhsql...@gmail.com 
> [mailto:drhsql...@gmail.com] On Behalf Of Richard 
> Hipp
> Sent: 12 August 2014 15:46

> I put a new snapshot on the download page.  Please try it, *without* 
> SQLITE_ENABLE_LOCKING_MODE.
OK, it builds, but doesn't run.

What are you doing that is causing an unlink() call to fail?  That should be a 
very obscure and infrequent occurrence.  How is this preventing you from 
running simple tests?  What problems does it display?




It is missing the patch to unixDelete. Whilst vxWorks is POSIX compliant, for 
file I/O it is only
compliant if the underlying file system is. We are using dosFs, which isn't. 
This means the error
codes don't match. So we added the following.

static int unixDelete(
  sqlite3_vfs *NotUsed, /* VFS containing this as the xDelete method */
  const char *zPath,/* Name of file to be deleted */
  int dirSync   /* If true, fsync() directory after deleting file */
){
  int rc = SQLITE_OK;
  UNUSED_PARAMETER(NotUsed);
  SimulateIOError(return SQLITE_IOERR_DELETE);
  if( osUnlink(zPath)==(-1) ){
if( errno==ENOENT ){
  rc = SQLITE_IOERR_DELETE_NOENT;
#if OS_VXWORKS
}else if( errno==0x380003 ){ /* == S_dosFsLib_FILE_NOT_FOUND */
  rc = SQLITE_IOERR_DELETE_NOENT;
#endif
}else{
  rc = unixLogError(SQLITE_IOERR_DELETE, "unlink", zPath);
}
With this patch I have run a few simple commands. Created a table, added a few 
rows and listed them.

The compile options I'm using are -DHAVE_UTIME -DSQLITE_OMIT_LOAD_EXTENSION

Regards

Andy Ling


--
D. Richard Hipp
d...@sqlite.org



--
D. Richard Hipp
d...@sqlite.org
___
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users


Re: [sqlite] HELP sqlite3 used in vxworks has someproblem?

2014-08-12 Thread Richard Hipp
On Tue, Aug 12, 2014 at 11:40 AM, Andy Ling  wrote:

> > From: drhsql...@gmail.com [mailto:drhsql...@gmail.com] On Behalf Of
> Richard Hipp
> > Sent: 12 August 2014 15:46
>
> > I put a new snapshot on the download page.  Please try it, *without*
> SQLITE_ENABLE_LOCKING_MODE.
>
> OK, it builds, but doesn't run.
>

What are you doing that is causing an unlink() call to fail?  That should
be a very obscure and infrequent occurrence.  How is this preventing you
from running simple tests?  What problems does it display?




>
> It is missing the patch to unixDelete. Whilst vxWorks is POSIX compliant,
> for file I/O it is only
> compliant if the underlying file system is. We are using dosFs, which
> isn't. This means the error
> codes don't match. So we added the following.
>
> static int unixDelete(
>   sqlite3_vfs *NotUsed, /* VFS containing this as the xDelete method */
>   const char *zPath,/* Name of file to be deleted */
>   int dirSync   /* If true, fsync() directory after deleting
> file */
> ){
>   int rc = SQLITE_OK;
>   UNUSED_PARAMETER(NotUsed);
>   SimulateIOError(return SQLITE_IOERR_DELETE);
>   if( osUnlink(zPath)==(-1) ){
> if( errno==ENOENT ){
>   rc = SQLITE_IOERR_DELETE_NOENT;
> #if OS_VXWORKS
> }else if( errno==0x380003 ){ /* == S_dosFsLib_FILE_NOT_FOUND */
>   rc = SQLITE_IOERR_DELETE_NOENT;
> #endif
> }else{
>   rc = unixLogError(SQLITE_IOERR_DELETE, "unlink", zPath);
> }
>
> With this patch I have run a few simple commands. Created a table, added a
> few rows and listed them.
>
> The compile options I'm using are -DHAVE_UTIME -DSQLITE_OMIT_LOAD_EXTENSION
>
> Regards
>
> Andy Ling
>
>
> --
> D. Richard Hipp
> d...@sqlite.org
>



-- 
D. Richard Hipp
d...@sqlite.org
___
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users


Re: [sqlite] UEFA EURO 2012 Football Championship problem - SOLVED!!!

2014-08-12 Thread Errol Emden






Thanks Petite...You, like Keith Medcalf, are a great mentor, helping me to 
develop my burgeoning skills in SQL. I appreciate the reason for the cause of 
each of the problems I encountered and how to correct them. 

'Granularity' is a new term for me and I now know why multiple entries 
occurred. Keith earlier introduced single 'scalar' result of correlated 
sub-queries. Also, I am now more aware of the type of join that should be used 
to include desired rows. Be well.

> From: petite.abei...@gmail.com
> Date: Mon, 11 Aug 2014 21:39:29 +0200
> To: sqlite-users@sqlite.org
> Subject: Re: [sqlite] UEFA EURO 2012 Football Championship problem
> 
> 
> On Aug 11, 2014, at 8:39 PM, Errol Emden  wrote:
> 
> > 1. Matches in which neither team scored is not being displayed.
> 
> Because you have an inner join to goal. If there no goal, then no entry will 
> match.
> 
> > 2. Scores for the same matchid where both teams scored are appearing on 
> > separate lines instead of in a single line.
> 
> Because you have a join to goal, which has a granularity of one entry per 
> goal, per match. So, if multiple goal, multiple entries. You try to 
> compensate by grouping per match and team, so you end up with two entries if 
> both team have scored.
> 
> > What do I need to do to correct these issues?
> 
> Get you granularity in order.
> _
> 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


Re: [sqlite] HELP sqlite3 used in vxworks has someproblem?

2014-08-12 Thread Andy Ling
> From: drhsql...@gmail.com [mailto:drhsql...@gmail.com] On Behalf Of Richard 
> Hipp
> Sent: 12 August 2014 15:46

> I put a new snapshot on the download page.  Please try it, *without* 
> SQLITE_ENABLE_LOCKING_MODE.

OK, it builds, but doesn't run.

It is missing the patch to unixDelete. Whilst vxWorks is POSIX compliant, for 
file I/O it is only
compliant if the underlying file system is. We are using dosFs, which isn't. 
This means the error
codes don't match. So we added the following.

static int unixDelete(
  sqlite3_vfs *NotUsed, /* VFS containing this as the xDelete method */
  const char *zPath,/* Name of file to be deleted */
  int dirSync   /* If true, fsync() directory after deleting file */
){
  int rc = SQLITE_OK;
  UNUSED_PARAMETER(NotUsed);
  SimulateIOError(return SQLITE_IOERR_DELETE);
  if( osUnlink(zPath)==(-1) ){
if( errno==ENOENT ){
  rc = SQLITE_IOERR_DELETE_NOENT;
#if OS_VXWORKS
}else if( errno==0x380003 ){ /* == S_dosFsLib_FILE_NOT_FOUND */
  rc = SQLITE_IOERR_DELETE_NOENT;
#endif
}else{
  rc = unixLogError(SQLITE_IOERR_DELETE, "unlink", zPath);
}

With this patch I have run a few simple commands. Created a table, added a few 
rows and listed them.

The compile options I'm using are -DHAVE_UTIME -DSQLITE_OMIT_LOAD_EXTENSION

Regards

Andy Ling


-- 
D. Richard Hipp
d...@sqlite.org 
___
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users


Re: [sqlite] HELP sqlite3 used in vxworks has someproblem?

2014-08-12 Thread Richard Hipp
On Tue, Aug 12, 2014 at 10:38 AM, Andy Ling  wrote:

> 've just downloaded the latest pre-release
> sqlite-amalgamation-201408081749.zip
> a
>

I put a new snapshot on the download page.  Please try it, *without*
SQLITE_ENABLE_LOCKING_MODE.

-- 
D. Richard Hipp
d...@sqlite.org
___
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users


Re: [sqlite] Cross-Platform ADO wrapper for iOS, Android and Win 8.1 WP 8.1?

2014-08-12 Thread Eric Sink
Short answer: no.

Longer answer:

Microsoft does not (yet?) support ADO on WinRT or WP8, much less on Xamarin
platforms.

But it looks like the future holds a glimmer of hope.  Their vNext project
seems to be heading toward portable ADO, and also includes SQLite support:

https://github.com/aspnet/DataCommon.SQLite

--
E


On Monday, August 11, 2014, Ken Wenyon  wrote:

> Is there ADO Support for SQLite using Windows 8.1 and Windows Phone 8.1?
>  I am looking for a Cross-Platform ADO wrapper for iOS, Android and Win 8.1
> WP 8.1?
>
>
> Ken Wenyon
> ___
> 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


Re: [sqlite] HELP sqlite3 used in vxworks has someproblem?

2014-08-12 Thread Andy Ling
> From: drhsql...@gmail.com [mailto:drhsql...@gmail.com] On Behalf Of Richard 
> Hipp
> Sent: 12 August 2014 14:28
> To: Andy Ling
> On Tue, Aug 12, 2014 at 9:23 AM, Andy Ling  wrote:


>> I have been testing
>> the changes Jan has made and at the moment I am happy.


> But we cannot use Jan's changes directly because he lives in a jurisdiction 
> that does not
> recognize the ability of an author to contribute their work into the public 
> domain.  We can
> only use Jan's changes as a guideline for implementing our own changes.
> Do you have any issues with the current code on the tip of trunk?

The patches I applied to 3.8.5 are working OK.
I've lost track a bit of what code I'm running and what I need to download.
So I've just downloaded the latest pre-release 
sqlite-amalgamation-201408081749.zip
and applied the patches below. This builds, but I haven't had a chance to do any
testing yet. Hopefully this matches the changes Jan suggested.

Regards

Andy Ling


*** sqlite3.c   2014-08-08 13:50:06.0 +0100
--- sqlite3vxw.c2014-08-12 15:21:22.0 +0100
***
*** 24161,24167 
  #endif


! #if SQLITE_ENABLE_LOCKING_STYLE
  # include 
  # if OS_VXWORKS
  #  include 
--- 24161,24167 
  #endif


! #if SQLITE_ENABLE_LOCKING_STYLE || OS_VXWORKS
  # include 
  # if OS_VXWORKS
  #  include 
***
*** 24589,24595 
--- 24589,24599 
  ** we are not running as root.
  */
  static int posixFchown(int fd, uid_t uid, gid_t gid){
+ #if OS_VXWORKS
+   return 0;
+ #else
return geteuid() ? 0 : fchown(fd,uid,gid);
+ #endif
  }

  /* Forward reference */
***
*** 24645,24651 
{ "read", (sqlite3_syscall_ptr)read,   0  },
  #define osRead  ((ssize_t(*)(int,void*,size_t))aSyscall[8].pCurrent)

! #if defined(USE_PREAD) || SQLITE_ENABLE_LOCKING_STYLE
{ "pread",(sqlite3_syscall_ptr)pread,  0  },
  #else
{ "pread",(sqlite3_syscall_ptr)0,  0  },
--- 24649,24655 
{ "read", (sqlite3_syscall_ptr)read,   0  },
  #define osRead  ((ssize_t(*)(int,void*,size_t))aSyscall[8].pCurrent)

! #if defined(USE_PREAD) || (SQLITE_ENABLE_LOCKING_STYLE && !OS_VXWORKS)
{ "pread",(sqlite3_syscall_ptr)pread,  0  },
  #else
{ "pread",(sqlite3_syscall_ptr)0,  0  },
***
*** 24662,24668 
{ "write",(sqlite3_syscall_ptr)write,  0  },
  #define osWrite ((ssize_t(*)(int,const 
void*,size_t))aSyscall[11].pCurrent)

! #if defined(USE_PREAD) || SQLITE_ENABLE_LOCKING_STYLE
{ "pwrite",   (sqlite3_syscall_ptr)pwrite, 0  },
  #else
{ "pwrite",   (sqlite3_syscall_ptr)0,  0  },
--- 24666,24672 
{ "write",(sqlite3_syscall_ptr)write,  0  },
  #define osWrite ((ssize_t(*)(int,const 
void*,size_t))aSyscall[11].pCurrent)

! #if defined(USE_PREAD) || (SQLITE_ENABLE_LOCKING_STYLE && !OS_VXWORKS)
{ "pwrite",   (sqlite3_syscall_ptr)pwrite, 0  },
  #else
{ "pwrite",   (sqlite3_syscall_ptr)0,  0  },
***
*** 25564,25572 
--- 25568,25582 
  ** Return TRUE if pFile has been renamed or unlinked since it was first 
opened.
  */
  static int fileHasMoved(unixFile *pFile){
+ #if OS_VXWORKS
+   return pFile->pInode!=0 &&
+
+  pFile->pId!=pFile->pInode->fileId.pId;
+ #else
struct stat buf;
return pFile->pInode!=0 &&
   (osStat(pFile->zPath, )!=0 || 
buf.st_ino!=pFile->pInode->fileId.ino);
+ #endif
  }


***
*** 26709,26715 
/* Otherwise see if some other process holds it. */
if( !reserved ){
  sem_t *pSem = pFile->pInode->pSem;
- struct stat statBuf;

  if( sem_trywait(pSem)==-1 ){
int tErrno = errno;
--- 26719,26724 
***
*** 26762,26768 
  */
  static int semLock(sqlite3_file *id, int eFileLock) {
unixFile *pFile = (unixFile*)id;
-   int fd;
sem_t *pSem = pFile->pInode->pSem;
int rc = SQLITE_OK;

--- 26771,26776 
***
*** 29893,29902 
int isCreate = (flags & SQLITE_OPEN_CREATE);
int isReadonly   = (flags & SQLITE_OPEN_READONLY);
int isReadWrite  = (flags & SQLITE_OPEN_READWRITE);
! #if SQLITE_ENABLE_LOCKING_STYLE
int isAutoProxy  = (flags & SQLITE_OPEN_AUTOPROXY);
  #endif
! #if defined(__APPLE__) || SQLITE_ENABLE_LOCKING_STYLE
struct statfs fsInfo;
  #endif

--- 29901,29910 
int isCreate = (flags & SQLITE_OPEN_CREATE);
int isReadonly   = (flags & SQLITE_OPEN_READONLY);
int isReadWrite  = (flags & SQLITE_OPEN_READWRITE);
! #if SQLITE_ENABLE_LOCKING_STYLE && !OS_VXWORKS
int isAutoProxy  = (flags & SQLITE_OPEN_AUTOPROXY);
  #endif
! #if defined(__APPLE__) || (SQLITE_ENABLE_LOCKING_STYLE && !OS_VXWORKS)
struct statfs fsInfo;
  #endif

***
*** 30062,30068 
noLock = eType!=SQLITE_OPEN_MAIN_DB;


! #if defined(__APPLE__) || SQLITE_ENABLE_LOCKING_STYLE
if( 

Re: [sqlite] Not SQLite related, but, SQLite Mailing List related

2014-08-12 Thread Stephen Chrzanowski
Thanks Jose, this looks to be like a browser issue.  Tried with Chrome and
the buttons are there and working.  Wonder if Google is trying to say
something? {smirk}

I'll check to see if JS is giving off errors or something.

I've tried using a mail client before, and have installed ThunderBird and
even gone with Outlook, but after a few UI decisions on their end, decided
to just stick with the browser.  I loath ribbons.


On Mon, Aug 11, 2014 at 4:40 PM, jose isaias cabrera <
jic...@cinops.xerox.com> wrote:

> "Stephen Chrzanowski" wrote...
>
>
>  Ok, this IS NOT about SQLite itself in ANY regard, but specifically about
>> this particular mailing list and how GMail is handling itself.
>>
>> When I joined this mailing list years ago, I put anything that goes
>> through
>> here into its own label via the same means that I've got for other email I
>> regularly receive.  When I go through my PHP Classes emails, my regular in
>> box, etc, those "Newer" and "Older" buttons are enabled.  However, in THIS
>> mailing list, when I click on any email, I don't get the option to go to
>> OLDER messages, but I do get to go to NEWER messages.  That OLDER button
>> doesn't activate when I go to a NEWER message when hitting the NEWER
>> button, but this functionality seemingly works everywhere else (I admit I
>> didn't try EVERY label)
>>
>> Anyone have an idea why?
>>
>
> Can you try another browser, if you are using a browser, to see if it
> display correctly in another browser?
> ___
> 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


Re: [sqlite] HELP sqlite3 used in vxworks has someproblem?

2014-08-12 Thread Richard Hipp
On Tue, Aug 12, 2014 at 9:37 AM, Jan Nijtmans 
wrote:

> 2014-08-12 15:27 GMT+02:00 Richard Hipp :
>
> > But we cannot use Jan's changes directly because he lives in a
> jurisdiction
> > that does not recognize the ability of an author to contribute their work
> > into the public domain.  We can only use Jan's changes as a guideline for
> > implementing our own changes.
> >
>
> At least that's what the famous Lawyer Lawrence Rosen believes.
>
> For another opinion, see:
> 
>
> Unfortunately, I'm not a lawyer :-(
>

Right.  Opinions vary.  Pending clarification of the issue and in view of
the huge number of users that might be impacted if the issue gets resolved
the wrong way, I think it is better to play it safe and not accept patches
from people in non-British-common-law countries for the time being.

-- 
D. Richard Hipp
d...@sqlite.org
___
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users


Re: [sqlite] HELP sqlite3 used in vxworks has someproblem?

2014-08-12 Thread Jan Nijtmans
2014-08-12 15:27 GMT+02:00 Richard Hipp :

> But we cannot use Jan's changes directly because he lives in a jurisdiction
> that does not recognize the ability of an author to contribute their work
> into the public domain.  We can only use Jan's changes as a guideline for
> implementing our own changes.
>

At least that's what the famous Lawyer Lawrence Rosen believes.

For another opinion, see:


Unfortunately, I'm not a lawyer :-(

Regards,
Jan Nijtmans
___
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users


Re: [sqlite] Crash in sqlite3_mutex_try [Was: SQLite 3.8.6 beta]

2014-08-12 Thread Adam Devita
1a) Somebody is paying you to do it.
1b) Incremental cost (or risk) of supporting it is small compared to the
cost (or risk) of porting /upgrading

Adam


On Tue, Aug 12, 2014 at 2:46 AM, Klaas V  wrote:

>
>
>  Jan wrote: " ** can manually set this value to 1 to emulate Win98
> behavior.
> */"
>
> Can anyone give me one good reason apart from nostalgia to support a MS
> system not supported by MS?
>
>
> Kind regards | Cordiali saluti | Vriendelijke groeten | Freundliche Grüsse,
> Klaas `Z4us` V  - OrcID -0001-7190-2544
> ___
> 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


Re: [sqlite] HELP sqlite3 used in vxworks has someproblem?

2014-08-12 Thread Richard Hipp
On Tue, Aug 12, 2014 at 9:23 AM, Andy Ling  wrote:

>
>
>  I have been testing
> the changes Jan has made and at the moment I am happy.
>


But we cannot use Jan's changes directly because he lives in a jurisdiction
that does not recognize the ability of an author to contribute their work
into the public domain.  We can only use Jan's changes as a guideline for
implementing our own changes.

Do you have any issues with the current code on the tip of trunk?



-- 
D. Richard Hipp
d...@sqlite.org
___
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users


Re: [sqlite] HELP sqlite3 used in vxworks has someproblem?

2014-08-12 Thread Andy Ling


From: drhsql...@gmail.com [mailto:drhsql...@gmail.com] On Behalf Of Richard Hipp
Sent: 12 August 2014 13:27

> This is very awkward working through a proxy.  If Mr. Ling (or anybody else 
> with access
>  to a VxWorks development system) wants VxWorks support in SQLite, he can 
> come to
>  this mailing list himself and submit suggestions here, where we can ask 
> questions. 
>  No more VxWorks changes without direct communication with actual VxWorks 
> developers.

I am on the list and that was where I made my first requests. As vxWorks has a 
fairly limited
audience, Jan suggested we take it off-list to finalise the required patches. I 
have been testing
the changes Jan has made and at the moment I am happy.

> The first question I have:  Why do VxWorks developers think they also need
>  SQLITE_ENABLE_LOCKING_STYLE support?

I don't. At some point I think someone suggested turning it on to see if it 
helped fix my
compilation problems (one of the errors I had related to semaphores). So I 
reported the
errors I got with it turned on.

If I have any more problems I'll be sure to ask on the list, although responses 
to vxWorks
issues are pretty small :^)

Thanks for all the help so far

Regards

Andy Ling


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


Re: [sqlite] HELP sqlite3 used in vxworks has someproblem?

2014-08-12 Thread Jan Nijtmans
2014-08-12 14:26 GMT+02:00 Richard Hipp :

> This is very awkward working through a proxy.  If Mr. Ling (or anybody else
> with access to a VxWorks development system) wants VxWorks support in
> SQLite, he can come to this mailing list himself and submit suggestions
> here, where we can ask questions.  No more VxWorks changes without direct
> communication with actual VxWorks developers.
>

Original discussion can be found here:



Regards,
   Jan Nijtmans
___
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users


Re: [sqlite] HELP sqlite3 used in vxworks has someproblem?

2014-08-12 Thread Richard Hipp
On Tue, Aug 12, 2014 at 8:10 AM, Jan Nijtmans 
wrote:

> New attempt here, base on current SQLite trunk:
>   
>

I fixed the obvious errors in the fileHasMoved() routine.  But as for the
other patches, I don't understand their purpose and so I'm unwilling to
implement them at this time.

This is very awkward working through a proxy.  If Mr. Ling (or anybody else
with access to a VxWorks development system) wants VxWorks support in
SQLite, he can come to this mailing list himself and submit suggestions
here, where we can ask questions.  No more VxWorks changes without direct
communication with actual VxWorks developers.

The first question I have:  Why do VxWorks developers think they also need
SQLITE_ENABLE_LOCKING_STYLE support?  The SQLITE_ENABLE_LOCKING_STYLE macro
is normally only used by Apple on Macs.  Nobody else uses it, as far as I
am aware.

-- 
D. Richard Hipp
d...@sqlite.org
___
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users


Re: [sqlite] CREATE INDEX Placement

2014-08-12 Thread Markus Schaber
Hi,

Von: Drago, William @ MWG - NARDAEAST

> Does it matter if I group all of my CREATE INDEX statements at the end of
> my .sql file or should they appear right after each CREATE TABLE statement?
> Does SQLITE care one way or another?

Semantically, it's equivalent (apart from the fact that you get different 
artifacts when one of the intermediate operation fails for whatever reason).

But the performance may be different - if a single table and its indices fit 
into RAM (os disk caches), but the whole database does not, performing the 
CREATE INDEX statements right after the corresponding CREATE TABLE statements 
may be faster, depending on your I/O system, as it can fetch the table contents 
from RAM during index creation.



Best regards

Markus Schaber

CODESYS(r) a trademark of 3S-Smart Software Solutions GmbH

Inspiring Automation Solutions

3S-Smart Software Solutions GmbH
Dipl.-Inf. Markus Schaber | Product Development Core Technology
Memminger Str. 151 | 87439 Kempten | Germany
Tel. +49-831-54031-979 | Fax +49-831-54031-50

E-Mail: m.scha...@codesys.com | Web: http://www.codesys.com | CODESYS store: 
http://store.codesys.com
CODESYS forum: http://forum.codesys.com

Managing Directors: Dipl.Inf. Dieter Hess, Dipl.Inf. Manfred Werner | Trade 
register: Kempten HRB 6186 | Tax ID No.: DE 167014915

This e-mail may contain confidential and/or privileged information. If you are 
not the intended recipient (or have received
this e-mail in error) please notify the sender immediately and destroy this 
e-mail. Any unauthorised copying, disclosure
or distribution of the material in this e-mail is strictly forbidden.

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


Re: [sqlite] HELP sqlite3 used in vxworks has someproblem?

2014-08-12 Thread Jan Nijtmans
2014-08-03 9:56 GMT+02:00 Jan Nijtmans :

> 2014-08-02 16:00 GMT+02:00 王庆刚 <2004wqg2...@163.com>:
> > hi , Can Sqlite3.c and sqlite.h be compiled in Workbench3.2 for
> Vxworks6.8 ?
> > When I  compile them , there have so many problems .
>
> You can find the necessary changes here:
> <
> http://fossil-scm.org/index.html/vpatch?from=dd5743a8239d1ce9=b68f65bb69a098a1
> >
> thanks to Andy Ling.
>
> Still has to be reviewed by the SQLite developers for inclusion in 3.8.6
> (not tested yet on other platforms than vxworks, win32/64 and Linux,
> there it works fine)
>

New attempt here, base on current SQLite trunk:
  

Regards,
  Jan Nijtmans
___
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users


Re: [sqlite] Crash in sqlite3_mutex_try [Was: SQLite 3.8.6 beta]

2014-08-12 Thread Jan Nijtmans
2014-08-11 13:12 GMT+02:00 Jan Nijtmans :

> And below is a minimal patch which fixes this problem.
>

Unfortunately, latest SQLite trunk, which fixes the
SQLITE_WIN32_GETVERSIONEX problem brought
back the SQLITE_WIN32_NO_ANSI problem
I reported earlier   -(

$ i686-w64-mingw32-gcc -c -DSQLITE_WIN32_NO_ANSI sqlite3.c
sqlite3.c: In function ‘sqlite3_win32_is_nt’:
sqlite3.c:33312:10: error: ‘sInfo’ undeclared (first use in this function)
 (sInfo.dwPlatformId == VER_PLATFORM_WIN32_NT) ? 2 : 1, 0);
  ^
sqlite3.c:33312:10: note: each undeclared identifier is reported only once
for each function it appears in

I could deliver a patch, but there are two fundementally
different (but both correct) approaches to handle this.

Regards,
  Jan Nijtmans
___
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users


Re: [sqlite] Crash in sqlite3_mutex_try [Was: SQLite 3.8.6 beta]

2014-08-12 Thread Klaas V


 Jan wrote: " ** can manually set this value to 1 to emulate Win98 behavior.
*/"

Can anyone give me one good reason apart from nostalgia to support a MS system 
not supported by MS?


Kind regards | Cordiali saluti | Vriendelijke groeten | Freundliche Grüsse,
Klaas `Z4us` V  - OrcID -0001-7190-2544
___
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users