Re: [sqlite] Version 3.0.0 ALPHA now available

2004-06-25 Thread Doug Currie

Friday, June 18, 2004, 8:33:26 AM, DRH wrote:
> A file format and API freeze is scheduled for July 1.  Users
> are encouraged to evaluate this release and make suggestions
> on how to improve the interface prior to that date.

I ported Tiago Dionizio's LuaSQLite to version 3.0.1. Here are a
few SQLite C API comments based on that experience...

0. Overall the new API is easy to use and understand; it is a logical
extension to the version 2 API. Porting was straightforward and
offered new opportunities for BLOBs and stronger dynamic data typing.

1. Windows DLLs will need sqlite3_libversion() function.

2. Loss of the sqlite_error_string(errnum) function complicates things
a bit. Before the change a glue library could defer capturing the
error string when an error occurred. In fact, it could simply pass the
error code back to the caller, and let the caller decide if a string
was necessary. Now the onus is on the library to capture the error
string immediately. Two reasons: the caller may perform db operations
before inspecting the returned result code and deciding the string is
desired, or the library may need to do some db cleanup functions
(e.g., sqlite3_finalize) after an error occurs, and the caller will
want the string associated with the original call, not the cleanup.

3. It would be convenient to be able to get the size of an integer
before calling one of sqlite3_column_int sqlite3_column_int64 or
sqlite3_column_double. Of course, the glue library can do this with
sqlite3_column_int64 and some arithmetic; the point is that when
sqlite3_column_type returns SQLITE_INTEGER it is not apparent which of
the three above calls to retrieve the value is optimal. [In the case
of Lua the only choice is double or text; asking sqlite for a double
may lose precision if the integer is larger than 52 bits; asking for
text leads to excessive type conversions on the Lua side.]

4. It is odd that sqlite3_exec returns an error message string (well I
guess it is legacy code). It triggers the only use of sqlite3_free in
the glue library just to handle this string. [The library doesn't use
sqlite3_mprintf() or sqlite3_vmprintf() preferring
sqlite3_bind_xxx().] Note that the comment in the source above
sqlite3_free is incorrect w.r.t. sqlite3_open.

e


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Spam: Re: [sqlite] Version 3.0.0 ALPHA now available

2004-06-19 Thread DJ Anubis
Le samedi 19 Juin 2004 09:28, Hans-Juergen Taenzer a écrit :

> But for example in the interface file sqlite(3).h there is not made
> use of this typedef (or INT64_TYPE defined in sqliteInt.h):
>
> long long int sqlite3_value_int64(sqlite3_value*);

try to patch as:
 
INT64_TYPE sqlite3_value_int64(sqlite3_value*);

or

long long sqlite3_value_int64(sqlite3_value*);

if this compiles, propose the typo change as a bug report. This could 
help improving portability.

-- 
JCR
aka DJ Anubis
LAB Project Initiator & coordinator

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Spam: Re: [sqlite] Version 3.0.0 ALPHA now available

2004-06-19 Thread Hans-Juergen Taenzer
DJ Anubis  ([EMAIL PROTECTED]) wrote:

 > Le vendredi 18 Juin 2004 22:20, Hans-Juergen Taenzer a écrit :
 >> I don't think there would be problems with the new version 3.0 if
 >> there wasn't the problem with the 'long long' datatype. Just
 >> using a suitable typdef for this datatype would resolve the
 >> problem (maybe there have to be changes to printf() too, I
 >> haven't checked it yet).

 > It should compile with MSC as os_win.h already contains the needed
 > definitions:

 > #if defined(_MSC_VER) || defined(__BORLANDC__)
 >   typedef __int64 off_t;
 > #else
 > # if !defined(_CYGWIN_TYPES_H)
 >   typedef long long off_t;
 > #   if defined(__MINGW32__)
 > # define _OFF_T_
 > #   endif
 > # endif
 > #endif

 > Maybe some defines checking needed.

That's true.

But for example in the interface file sqlite(3).h there is not made use of
this typedef (or INT64_TYPE defined in sqliteInt.h):

long long int sqlite3_value_int64(sqlite3_value*);

I would like it if SQLite 3.0 would support MSVC just as SQLite 2.x does.

Hans-Jürgen Tänzer

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Spam: Re: [sqlite] Version 3.0.0 ALPHA now available

2004-06-18 Thread Hans-Juergen Taenzer
Hihn, Jason  ([EMAIL PROTECTED]) wrote:

 > I am not the one to answer this, but I do know the mains that
 > KJSEmbed is going through at the moment. The whole delay is trying
 > to get it to compile in MSVC, but they moved to mingw32, where
 > it's much more standard. They've since been chugging along.
 > "Weeks" of work was reduced to days.

 > I guess what I'm saying is MSVC didn't embrace ANSI enough.

In the past SQLite (and my programs using SQLite) compiled just fine with
MSVC and run without any problems.

I don't think there would be problems with the new version 3.0 if there
wasn't the problem with the 'long long' datatype. Just using a suitable
typdef for this datatype would resolve the problem (maybe there have to be
changes to printf() too, I haven't checked it yet).

And I think using another compiler than GNUC would be a good test for the
new version too.

 > Could minw32 work for you?

Yes, but I want to have a good IDE to work with. :-)

Gruss
 Hans-Jürgen

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



RE: Spam: Re: [sqlite] Version 3.0.0 ALPHA now available

2004-06-18 Thread Hihn, Jason
I am not the one to answer this, but I do know the mains that KJSEmbed is going 
through at the moment. The whole delay is trying to get it to compile in MSVC, but 
they moved to mingw32, where it's much more standard. They've since been chugging 
along. "Weeks" of work was reduced to days. 

I guess what I'm saying is MSVC didn't embrace ANSI enough. Could minw32 work for you?

http://www.mingw.org/



-Original Message-
From: Hans-Juergen Taenzer [mailto:[EMAIL PROTECTED] 
Sent: Friday, June 18, 2004 2:37 PM
To: [EMAIL PROTECTED]
Subject: Spam: Re: [sqlite] Version 3.0.0 ALPHA now available

D. Richard Hipp ([EMAIL PROTECTED]) wrote:

 > Version 3.0.0 (alpha) of SQLite is now available on the
 > website.

Will there be support for other compilers than GNUC?

For example the datatype "long long" is not supported by MSVC.
In the prior versions there were the typedef off_t, which was defined
suitable as __int64.

Hans-Jürgen Tänzer

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: [sqlite] Version 3.0.0 ALPHA now available

2004-06-18 Thread VTenneti





Any chance of getting Correlated Subqueries, including the EXISTS / NOT
EXISTS clause ?

And since it is open season, could we have user defined expression
evaluation functionality (other than user defined compares that 3.0 already
has). For example arithmetic, substring etc ?




   
 "D. Richard Hipp" 
 <[EMAIL PROTECTED]>   
To 
 18/06/2004 13:33  [EMAIL PROTECTED] 
cc 
   
   Subject 
       [sqlite] Version 3.0.0 ALPHA now
       available   
   
   
   
   
   
   




Version 3.0.0 (alpha) of SQLite is now available on the
website.

http://www.sqlite.org/
http://www.sqlite.org/version3.html
http://www.sqlite.org/capi3.html

This is an alpha release intended for testing and evaluation
only.  Version 3 is not yet ready for production use.

A file format and API freeze is scheduled for July 1.  Users
are encouraged to evaluate this release and make suggestions
on how to improve the interface prior to that date.

Anonymous CVS access has been reenabled.

--
D. Richard Hipp -- [EMAIL PROTECTED] -- 704.948.4565


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



[sqlite] Version 3.0.0 ALPHA now available

2004-06-18 Thread D. Richard Hipp
Version 3.0.0 (alpha) of SQLite is now available on the
website.
   http://www.sqlite.org/
   http://www.sqlite.org/version3.html
   http://www.sqlite.org/capi3.html
This is an alpha release intended for testing and evaluation
only.  Version 3 is not yet ready for production use.
A file format and API freeze is scheduled for July 1.  Users
are encouraged to evaluate this release and make suggestions
on how to improve the interface prior to that date.
Anonymous CVS access has been reenabled.
--
D. Richard Hipp -- [EMAIL PROTECTED] -- 704.948.4565
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]