Re: [fpc-pascal]SQLite and NULL Strings...

2003-07-16 Thread Boguslaw Brandys
Hello, >From SQLite docs: "Note that the callback function reports a NULL value in the database as a NULL pointer, which is very different from an empty string. If the i-th parameter is an empty string, we will get: argv[i][0] == 0 But if the i-th parameter is NULL we will get: argv[i] == 0"So

Re: [fpc-pascal]SQLite and NULL Strings...

2003-07-15 Thread James Mills
On Tue, Jul 15, 2003 at 09:41:11AM -0700, Alan Mead wrote: > > --- James Mills <[EMAIL PROTECTED]> wrote: > > > > Well the only bad thing is that it returns data where there should > > be no > > data. ie: '""' instead of the expected '', causing the program to > > treat > > '""' as if it were a r

Re: [fpc-pascal]SQLite and NULL Strings...

2003-07-15 Thread Alan Mead
--- James Mills <[EMAIL PROTECTED]> wrote: > > Well the only bad thing is that it returns data where there should > be no > data. ie: '""' instead of the expected '', causing the program to > treat > '""' as if it were a real string. All the better. The string '""' is unlikely to exists you yo

Re: [fpc-pascal]SQLite and NULL Strings...

2003-07-15 Thread James Mills
On Tue, Jul 15, 2003 at 08:53:12AM -0700, Alan Mead wrote: > > --- James Mills <[EMAIL PROTECTED]> wrote: > > On Tue, Jul 15, 2003 at 08:35:44AM -0700, Alan Mead wrote: > > > > > > --- James Mills <[EMAIL PROTECTED]> wrote: > > > > > > > My program relies on the fact that some fields (which are

Re: [fpc-pascal]SQLite and NULL Strings...

2003-07-15 Thread Alan Mead
--- James Mills <[EMAIL PROTECTED]> wrote: > On Tue, Jul 15, 2003 at 08:35:44AM -0700, Alan Mead wrote: > > > > --- James Mills <[EMAIL PROTECTED]> wrote: > > > > > My program relies on the fact that some fields (which are > string > > > types) > > > are null. I'm not sure what to say next so I'

Re: [fpc-pascal]SQLite and NULL Strings...

2003-07-15 Thread James Mills
On Tue, Jul 15, 2003 at 08:35:44AM -0700, Alan Mead wrote: > > --- James Mills <[EMAIL PROTECTED]> wrote: > > > My program relies on the fact that some fields (which are string > > types) > > are null. I'm not sure what to say next so I'll leave it at that :P > > If your database never contains

Re: [fpc-pascal]SQLite and NULL Strings...

2003-07-15 Thread Alan Mead
--- James Mills <[EMAIL PROTECTED]> wrote: > My program relies on the fact that some fields (which are string > types) > are null. I'm not sure what to say next so I'll leave it at that :P If your database never contains an empty string, then your program can rely on the empty strings you retrie

Re: [fpc-pascal]SQLite and NULL Strings...

2003-07-15 Thread James Mills
On Tue, Jul 15, 2003 at 05:27:42PM +0200, Michael Van Canneyt wrote: > > > On Wed, 16 Jul 2003, James Mills wrote: > > > On Tue, Jul 15, 2003 at 07:04:05AM -0700, Alan Mead wrote: > > > > > > --- James Mills <[EMAIL PROTECTED]> wrote: > > > > On Tue, Jul 15, 2003 at 04:36:24AM -0700, Alan Mead w

Re: [fpc-pascal]SQLite and NULL Strings...

2003-07-15 Thread Michael Van Canneyt
On Wed, 16 Jul 2003, James Mills wrote: > On Tue, Jul 15, 2003 at 07:04:05AM -0700, Alan Mead wrote: > > > > --- James Mills <[EMAIL PROTECTED]> wrote: > > > On Tue, Jul 15, 2003 at 04:36:24AM -0700, Alan Mead wrote: > > > > > > > > --- James Mills <[EMAIL PROTECTED]> wrote: > > > > > > > > > Ju

Re: [fpc-pascal]SQLite and NULL Strings...

2003-07-15 Thread James Mills
On Tue, Jul 15, 2003 at 07:04:05AM -0700, Alan Mead wrote: > > --- James Mills <[EMAIL PROTECTED]> wrote: > > On Tue, Jul 15, 2003 at 04:36:24AM -0700, Alan Mead wrote: > > > > > > --- James Mills <[EMAIL PROTECTED]> wrote: > > > > > > > Just reconfirming with you and solidifying my knowledge.

Re: [fpc-pascal]SQLite and NULL Strings...

2003-07-15 Thread Alan Mead
--- James Mills <[EMAIL PROTECTED]> wrote: > On Tue, Jul 15, 2003 at 04:36:24AM -0700, Alan Mead wrote: > > > > --- James Mills <[EMAIL PROTECTED]> wrote: > > > > > Just reconfirming with you and solidifying my knowledge. > > > The reason it returns "" is because: when working with > > > nativ

Re: [fpc-pascal]SQLite and NULL Strings...

2003-07-15 Thread Michael Van Canneyt
On Tue, 15 Jul 2003, James Mills wrote: > On Mon, Jul 14, 2003 at 03:39:36PM +0200, Michael Van Canneyt wrote: > > > > > > On Mon, 14 Jul 2003, James Mills wrote: > > > > > On Mon, Jul 14, 2003 at 09:59:17AM +0200, Michael Van Canneyt wrote: > > > > > > > > > > > > On Mon, 14 Jul 2003, James Mil

Re: [fpc-pascal]SQLite and NULL Strings...

2003-07-15 Thread James Mills
On Mon, Jul 14, 2003 at 03:39:36PM +0200, Michael Van Canneyt wrote: > > > On Mon, 14 Jul 2003, James Mills wrote: > > > On Mon, Jul 14, 2003 at 09:59:17AM +0200, Michael Van Canneyt wrote: > > > > > > > > > On Mon, 14 Jul 2003, James Mills wrote: > > > > > > > Hi, > > > > > > > > This is a very

Re: [fpc-pascal]SQLite and NULL Strings...

2003-07-15 Thread James Mills
On Tue, Jul 15, 2003 at 03:15:58PM +0200, Michael Van Canneyt wrote: > > > On Tue, 15 Jul 2003, James Mills wrote: > > > On Tue, Jul 15, 2003 at 04:36:24AM -0700, Alan Mead wrote: > > > > > > --- James Mills <[EMAIL PROTECTED]> wrote: > > > > > > > Just reconfirming with you and solidifying my k

Re: [fpc-pascal]SQLite and NULL Strings...

2003-07-15 Thread Michael Van Canneyt
On Tue, 15 Jul 2003, James Mills wrote: > On Tue, Jul 15, 2003 at 04:36:24AM -0700, Alan Mead wrote: > > > > --- James Mills <[EMAIL PROTECTED]> wrote: > > > > > Just reconfirming with you and solidifying my knowledge. > > > The reason it returns "" is because: when working with > > > native pas

Re: [fpc-pascal]SQLite and NULL Strings...

2003-07-15 Thread James Mills
On Tue, Jul 15, 2003 at 04:36:24AM -0700, Alan Mead wrote: > > --- James Mills <[EMAIL PROTECTED]> wrote: > > > Just reconfirming with you and solidifying my knowledge. > > The reason it returns "" is because: when working with > > native pascal types, assigning null to a string results > > in

Re: [fpc-pascal]SQLite and NULL Strings...

2003-07-15 Thread Alan Mead
--- James Mills <[EMAIL PROTECTED]> wrote: > Just reconfirming with you and solidifying my knowledge. > The reason it returns "" is because: when working with > native pascal types, assigning null to a string results > in an empty string "" right ? > > cheers > James James, Pascal is a stro

Re: [fpc-pascal]SQLite and NULL Strings...

2003-07-14 Thread James Mills
On Mon, Jul 14, 2003 at 03:06:44PM +0200, Michael Van Canneyt wrote: > > > On Mon, 14 Jul 2003, James Mills wrote: > > > On Mon, Jul 14, 2003 at 02:26:28PM +0200, Michael Van Canneyt wrote: > > > > > > > > > On Mon, 14 Jul 2003, James Mills wrote: > > > > > > > On Mon, Jul 14, 2003 at 09:59:17AM

Re: [fpc-pascal]SQLite and NULL Strings...

2003-07-14 Thread James Mills
On Mon, Jul 14, 2003 at 03:39:36PM +0200, Michael Van Canneyt wrote: > > > On Mon, 14 Jul 2003, James Mills wrote: > > > On Mon, Jul 14, 2003 at 09:59:17AM +0200, Michael Van Canneyt wrote: > > > > > > > > > On Mon, 14 Jul 2003, James Mills wrote: > > > > > > > Hi, > > > > > > > > This is a very

Re: [fpc-pascal]SQLite and NULL Strings...

2003-07-14 Thread Michael Van Canneyt
On Mon, 14 Jul 2003, James Mills wrote: > On Mon, Jul 14, 2003 at 09:59:17AM +0200, Michael Van Canneyt wrote: > > > > > > On Mon, 14 Jul 2003, James Mills wrote: > > > > > Hi, > > > > > > This is a very weird behaviour I've found of either SQLite, or the Unit. > > > I'm not sure... I have been

Re: [fpc-pascal]SQLite and NULL Strings...

2003-07-14 Thread James Mills
On Mon, Jul 14, 2003 at 09:59:17AM +0200, Michael Van Canneyt wrote: > > > On Mon, 14 Jul 2003, James Mills wrote: > > > Hi, > > > > This is a very weird behaviour I've found of either SQLite, or the Unit. > > I'm not sure... I have been discussing this same problem on the SQLite > > mailing lis

Re: [fpc-pascal]SQLite and NULL Strings...

2003-07-14 Thread Michael Van Canneyt
On Mon, 14 Jul 2003, James Mills wrote: > On Mon, Jul 14, 2003 at 02:26:28PM +0200, Michael Van Canneyt wrote: > > > > > > On Mon, 14 Jul 2003, James Mills wrote: > > > > > On Mon, Jul 14, 2003 at 09:59:17AM +0200, Michael Van Canneyt wrote: > > > > > > > > > > > > On Mon, 14 Jul 2003, James Mil

Re: [fpc-pascal]SQLite and NULL Strings...

2003-07-14 Thread James Mills
On Mon, Jul 14, 2003 at 02:26:28PM +0200, Michael Van Canneyt wrote: > > > On Mon, 14 Jul 2003, James Mills wrote: > > > On Mon, Jul 14, 2003 at 09:59:17AM +0200, Michael Van Canneyt wrote: > > > > > > > > > On Mon, 14 Jul 2003, James Mills wrote: > > > > > > > Hi, > > > > > > > > This is a very

Re: [fpc-pascal]SQLite and NULL Strings...

2003-07-14 Thread Michael Van Canneyt
On Mon, 14 Jul 2003, James Mills wrote: > On Mon, Jul 14, 2003 at 09:59:17AM +0200, Michael Van Canneyt wrote: > > > > > > On Mon, 14 Jul 2003, James Mills wrote: > > > > > Hi, > > > > > > This is a very weird behaviour I've found of either SQLite, or the Unit. > > > I'm not sure... I have been

Re: [fpc-pascal]SQLite and NULL Strings...

2003-07-14 Thread James Mills
On Mon, Jul 14, 2003 at 09:59:17AM +0200, Michael Van Canneyt wrote: > > > On Mon, 14 Jul 2003, James Mills wrote: > > > Hi, > > > > This is a very weird behaviour I've found of either SQLite, or the Unit. > > I'm not sure... I have been discussing this same problem on the SQLite > > mailing lis

Re: [fpc-pascal]SQLite and NULL Strings...

2003-07-14 Thread Michael Van Canneyt
On Mon, 14 Jul 2003, James Mills wrote: > Hi, > > This is a very weird behaviour I've found of either SQLite, or the Unit. > I'm not sure... I have been discussing this same problem on the SQLite > mailing list but without success there, so perhaps someone here might > know... > > I have attache

[fpc-pascal]SQLite and NULL Strings...

2003-07-13 Thread James Mills
Hi, This is a very weird behaviour I've found of either SQLite, or the Unit. I'm not sure... I have been discussing this same problem on the SQLite mailing list but without success there, so perhaps someone here might know... I have attached a test database, which contains 1 database entry, null