Re: [sqlite] sqlite3 database unreadable on Mountain Lion

2012-08-06 Thread Doug Currie

On Aug 6, 2012, at 4:51 PM, Simon Slavin  wrote:

> On 6 Aug 2012, at 7:48pm, Doug Currie  wrote:
> 
>> ~ e$ /usr/local/bin/sqlite3 :memory: 'SELECT sqlite_source_id()'
>> 2012-05-14 01:41:23 8654aa9540fe9fd210899d83d17f3f407096c004
> 
> I think this copy has been installed by something else.

Yes, I installed it.

>  I don't think it comes with Apple's distribution of Mountain Lion.  If this 
> is the file which is being executed by default (in other words, if that's the 
> file reported by the command 'which sqlite3' on your system) then this may be 
> the cause of your problem.

I don't have a problem, Tobias does, and I suspect it is because the ML version 
of sqlite3 in /usr/bin (2012-04-03) predates the 3.7.12 release, and has the 
bug Dan recalls.

e

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


Re: [sqlite] sqlite3 database unreadable on Mountain Lion

2012-08-06 Thread Simon Slavin

On 6 Aug 2012, at 7:48pm, Doug Currie  wrote:

> ~ e$ /usr/local/bin/sqlite3 :memory: 'SELECT sqlite_source_id()'
> 2012-05-14 01:41:23 8654aa9540fe9fd210899d83d17f3f407096c004

I think this copy has been installed by something else.  I don't think it comes 
with Apple's distribution of Mountain Lion.  If this is the file which is being 
executed by default (in other words, if that's the file reported by the command 
'which sqlite3' on your system) then this may be the cause of your problem.

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


Re: [sqlite] sqlite3 database unreadable on Mountain Lion

2012-08-06 Thread Black, Michael (IS)
Fully qualified path names may still both load the same shared library.

I assume you have "ldd" available?  Run that on the binaries and see which 
library they'll load.  Probably the same one unless they are statically linked.

Michael D. Black
Senior Scientist
Advanced Analytics Directorate
Advanced GEOINT Solutions Operating Unit
Northrop Grumman Information Systems


From: sqlite-users-boun...@sqlite.org [sqlite-users-boun...@sqlite.org] on 
behalf of Doug Currie [doug.cur...@gmail.com]
Sent: Monday, August 06, 2012 1:48 PM
To: General Discussion of SQLite Database
Subject: EXT :Re: [sqlite] sqlite3 database unreadable on Mountain Lion

On Aug 6, 2012, at 8:26 AM, Simon Slavin <slav...@bigfraud.org> wrote:

> So either Apple has made a change between versions, or we have different 
> paths.

I use fully qualified pathnames here:

~ e$ /usr/bin/sqlite3  :memory: 'SELECT sqlite_source_id()'
2012-04-03 19:43:07 86b8481be7e7692d14ce762d21bfb69504af
~ e$ /usr/local/bin/sqlite3 :memory: 'SELECT sqlite_source_id()'
2012-05-14 01:41:23 8654aa9540fe9fd210899d83d17f3f407096c004

I never had a pre-release OSX ML installed. I did update /usr/local/bin/sqlite3 
from sqlite.org.

e

___
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] sqlite3 database unreadable on Mountain Lion

2012-08-06 Thread Doug Currie

On Aug 6, 2012, at 8:26 AM, Simon Slavin  wrote:

> So either Apple has made a change between versions, or we have different 
> paths.

I use fully qualified pathnames here:

~ e$ /usr/bin/sqlite3  :memory: 'SELECT sqlite_source_id()'
2012-04-03 19:43:07 86b8481be7e7692d14ce762d21bfb69504af
~ e$ /usr/local/bin/sqlite3 :memory: 'SELECT sqlite_source_id()'
2012-05-14 01:41:23 8654aa9540fe9fd210899d83d17f3f407096c004

I never had a pre-release OSX ML installed. I did update /usr/local/bin/sqlite3 
from sqlite.org.

e

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


Re: [sqlite] sqlite3 database unreadable on Mountain Lion

2012-08-06 Thread Simon Slavin

On 6 Aug 2012, at 1:04pm, Chris Smith  wrote:

> Running Mountain Lion, I got:
> 2012-06-11 02:05:22 f5b5a13f7394dc143aa136f1d4faba6839eaa6dc
> 
> for:
> sqlite3 :memory: 'SELECT sqlite_source_id()'

For comparison, in a pre-release version of Mountain Lion I get

$ which sqlite3
/usr/bin/sqlite3

$ sqlite3 :memory: 'SELECT sqlite_version()'
3.7.12

$ sqlite3 :memory: 'SELECT sqlite_source_id()'
2012-04-03 19:43:07 86b8481be7e7692d14ce762d21bfb69504af

So either Apple has made a change between versions, or we have different paths.

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


Re: [sqlite] sqlite3 database unreadable on Mountain Lion

2012-08-06 Thread Richard Hipp
On Mon, Aug 6, 2012 at 8:04 AM, Chris Smith  wrote:

> Running Mountain Lion, I got:
>  2012-06-11 02:05:22 f5b5a13f7394dc143aa136f1d4faba6839eaa6dc
>

Have you upgraded your SQLite?  Because Doug Currie at
http://www.mail-archive.com/sqlite-users@sqlite.org/msg71932.html gives a
very different version number?



>
> for:
>  sqlite3 :memory: 'SELECT sqlite_source_id()'
>
> On Mon, Aug 6, 2012 at 7:26 AM, Richard Hipp  wrote:
>
> > On Fri, Aug 3, 2012 at 10:33 AM, Tobias Giesen  > >wrote:
> >
> > > Hello,
> > >
> > > here's a problem that's puzzling me.
> > >
> > > I have one particular type of database that has become unreadable on
> > > the new Mac OS 10.8. It must be related to the SQL structure. The error
> > > I get is "database disk image is malformed". But the same file, on
> > > Snow Leopard, works fine.
> > >
> > > The SQLite version on Snow Leopard is 3.6.12, and on Mountain Lion it
> > > is 3.7.12.
> > >
> >
> > What does the following command show on ML?
> >
> > sqlite3 :memory: 'SELECT sqlite_source_id()'
> >
> >
> > >
> > > The strange thing is, when I attempt to load the sqlite3.dylib from
> > > Snow Leopard under Mountain Lion, it also does not work. But I'm not
> > > totally sure if loading the older sqlite3 library actually worked.
> > >
> > > Does anybody have any advice for me?
> > >
> > > Many thanks!
> > > Tobias Giesen
> > > www.syncovery.com
> > >
> > >
> > >
> > > ___
> > > sqlite-users mailing list
> > > sqlite-users@sqlite.org
> > > http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users
> > >
> >
> >
> >
> > --
> > D. Richard Hipp
> > d...@sqlite.org
> > ___
> > sqlite-users mailing list
> > sqlite-users@sqlite.org
> > http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users
> >
> >
>
>
> --
> History tells all of us that nobody gets a pass.  Your [country's]
> perpetual existence is not guaranteed.  If you do not believe in yourself,
> and believe that you're better than the alternative, and have the
> educational skills to come to that empirical judgment, then there is no
> reason for you to continue, and often you won't. --Victor Davis Hanson
> ___
> sqlite-users mailing list
> sqlite-users@sqlite.org
> http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users
>



-- 
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] sqlite3 database unreadable on Mountain Lion

2012-08-06 Thread Chris Smith
Running Mountain Lion, I got:
 2012-06-11 02:05:22 f5b5a13f7394dc143aa136f1d4faba6839eaa6dc

for:
 sqlite3 :memory: 'SELECT sqlite_source_id()'

On Mon, Aug 6, 2012 at 7:26 AM, Richard Hipp  wrote:

> On Fri, Aug 3, 2012 at 10:33 AM, Tobias Giesen  >wrote:
>
> > Hello,
> >
> > here's a problem that's puzzling me.
> >
> > I have one particular type of database that has become unreadable on
> > the new Mac OS 10.8. It must be related to the SQL structure. The error
> > I get is "database disk image is malformed". But the same file, on
> > Snow Leopard, works fine.
> >
> > The SQLite version on Snow Leopard is 3.6.12, and on Mountain Lion it
> > is 3.7.12.
> >
>
> What does the following command show on ML?
>
> sqlite3 :memory: 'SELECT sqlite_source_id()'
>
>
> >
> > The strange thing is, when I attempt to load the sqlite3.dylib from
> > Snow Leopard under Mountain Lion, it also does not work. But I'm not
> > totally sure if loading the older sqlite3 library actually worked.
> >
> > Does anybody have any advice for me?
> >
> > Many thanks!
> > Tobias Giesen
> > www.syncovery.com
> >
> >
> >
> > ___
> > sqlite-users mailing list
> > sqlite-users@sqlite.org
> > http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users
> >
>
>
>
> --
> D. Richard Hipp
> d...@sqlite.org
> ___
> sqlite-users mailing list
> sqlite-users@sqlite.org
> http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users
>
>


-- 
History tells all of us that nobody gets a pass.  Your [country's]
perpetual existence is not guaranteed.  If you do not believe in yourself,
and believe that you're better than the alternative, and have the
educational skills to come to that empirical judgment, then there is no
reason for you to continue, and often you won't. --Victor Davis Hanson
___
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users


Re: [sqlite] sqlite3 database unreadable on Mountain Lion

2012-08-06 Thread Richard Hipp
On Fri, Aug 3, 2012 at 10:33 AM, Tobias Giesen wrote:

> Hello,
>
> here's a problem that's puzzling me.
>
> I have one particular type of database that has become unreadable on
> the new Mac OS 10.8. It must be related to the SQL structure. The error
> I get is "database disk image is malformed". But the same file, on
> Snow Leopard, works fine.
>
> The SQLite version on Snow Leopard is 3.6.12, and on Mountain Lion it
> is 3.7.12.
>

What does the following command show on ML?

sqlite3 :memory: 'SELECT sqlite_source_id()'


>
> The strange thing is, when I attempt to load the sqlite3.dylib from
> Snow Leopard under Mountain Lion, it also does not work. But I'm not
> totally sure if loading the older sqlite3 library actually worked.
>
> Does anybody have any advice for me?
>
> Many thanks!
> Tobias Giesen
> www.syncovery.com
>
>
>
> ___
> sqlite-users mailing list
> sqlite-users@sqlite.org
> http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users
>



-- 
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] sqlite3 database unreadable on Mountain Lion

2012-08-03 Thread Simon Slavin

On 3 Aug 2012, at 8:32pm, Tobias Giesen  wrote:

> I have a problem with this. Even when I invoke an old sqlite3 
> executable, Mountain Lion still launches 3.7.12.

What are you doing to 'invoke' ?

Put the executable in a folder with your database.  cd to that folder.  type

./sqlite3 databasename.sqlite

> Apparently Apple 
> prevents starting other versions of it and redirects everything to
> their current version in /usr/bin.

There really isn't anything like this in OS X.  The 'which' command will tell 
you which version you'll get if you don't specify a folder

which sqlite3

if you specify a folder for your executable you get the one you specified.

Of course if you have installed DarwinPorts or anything like that you deserve 
all the confusion you created.

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


Re: [sqlite] sqlite3 database unreadable on Mountain Lion

2012-08-03 Thread Tobias Giesen
> On ML here I can launch my version in /user/local/bin just fine.

Maybe because it's newer. Try to start the Snow Leopard version. If you
can get that done, I will be thrilled!

However I will also try putting it in /usr/local/bin next.

Cheers,
Tobias


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


Re: [sqlite] sqlite3 database unreadable on Mountain Lion

2012-08-03 Thread Warren Young

On 8/3/2012 1:26 PM, Tobias Giesen wrote:

SQLite version 3.7.12 2012-05-14 01:41:23


Apple's version is 3.7.12 2012-04-03 19:43:07.


Well, that's the problem, then, isn't it?  SQLite 3.7.12 shipped on May 
14.  Apple must have shipped a pre-release version of SQLite 3.7.12, 
with the bug Dan remembers in it.


You should be able to fix it by statically compiling SQLite 3 into your 
program.  Then it doesn't matter that the platform version is broken.

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


Re: [sqlite] sqlite3 database unreadable on Mountain Lion

2012-08-03 Thread Doug Currie
On Aug 3, 2012, at 3:32 PM, Tobias Giesen  wrote:

> Apparently Apple prevents starting other versions of it and redirects 
> everything to
> their current version in /usr/bin.

On ML here I can launch my version in /user/local/bin just fine.

e$ which sqlite3
/usr/local/bin/sqlite3
e$ sqlite3
SQLite version 3.7.12 2012-05-14 01:41:23
Enter ".help" for instructions
Enter SQL statements terminated with a ";"
sqlite> SELECT sqlite_source_id();
2012-05-14 01:41:23 8654aa9540fe9fd210899d83d17f3f407096c004
sqlite> .exit
e$ uname -mprsv
Darwin 12.0.0 Darwin Kernel Version 12.0.0: Sun Jun 24 23:00:16 PDT 2012; 
root:xnu-2050.7.9~1/RELEASE_X86_64 x86_64 i386

e


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


Re: [sqlite] sqlite3 database unreadable on Mountain Lion

2012-08-03 Thread Tobias Giesen
Hi,

I have a problem with this. Even when I invoke an old sqlite3 
executable, Mountain Lion still launches 3.7.12. Apparently Apple 
prevents starting other versions of it and redirects everything to
their current version in /usr/bin.

As I wrote earlier, the same thing happened with the sqlite3.dylib.
I am positive that I loaded an older library from my code, but Mac OS
replaced it with the current one they have.

Ever heard of such a thing? And how to work around it?

So there's still no solution ...

Cheers,
Tobias

 
> if your users with 10.8 do need to do the .dump, all you need send them is 
> the executable version of sqlite3 which comes with 10.7, and a script 
> which calls it.  It should run fine under 10.8 and does not have any 
> dependencies or call any libraries.
> 
> But give the experts time to explore your problem first, since by the look of 
> it it shouldn't be occurring.
> 
> Simon.

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


Re: [sqlite] sqlite3 database unreadable on Mountain Lion

2012-08-03 Thread Tobias Giesen
> The broken.sql file works with 3.7.12 here.

So you're not using Mountain Lion ...

> SQLite version 3.7.12 2012-05-14 01:41:23

Apple's version is 3.7.12 2012-04-03 19:43:07.

> CREATE TABLE t1(x, CONSTRAINT pk_cons PRIMARY KEY(x));

Yes I can do that too. But in some larger tables, it does not work.

> SELECT sqlite_source_id();

I get:
2012-04-03 19:43:07 86b8481be7e7692d14ce762d21bfb69504af

Kind Regards,
Tobias Giesen

"To avoid a reboot, make sure that no SuperFlexible or ExtremeSync 
 processes are running in Task Manager before installing an update."

Super Flexible Software Ltd. & Co. KG
Lessingstr. 42
48485 Neuenkirchen, Germany
www.superflexible.com
www.tgtools.com
 
---
Registered at register court Steinfurt as HRA 5061
Liability / general partner: TGTools Ltd.
Company No. 05513299
Registered in England and Wales
Directors: Tobias Giesen and Claudia Giesen

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


Re: [sqlite] sqlite3 database unreadable on Mountain Lion

2012-08-03 Thread Doug Currie

On Aug 3, 2012, at 2:33 PM, Dan Kennedy  wrote:

> There was a problem similar to your description at one point, but
> it should have been fixed before the 3.7.12 release. What do you
> get from the shell command "SELECT sqlite_source_id();" on
> Mountain Lion?

e$ /usr/bin/sqlite3
SQLite version 3.7.12 2012-04-03 19:43:07
Enter ".help" for instructions
Enter SQL statements terminated with a ";"
sqlite> SELECT sqlite_source_id();
2012-04-03 19:43:07 86b8481be7e7692d14ce762d21bfb69504af


e


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


Re: [sqlite] sqlite3 database unreadable on Mountain Lion

2012-08-03 Thread Dan Kennedy

On 08/03/2012 11:33 PM, Tobias Giesen wrote:

Hello,

thanks for the replies!

A sample Mountain-unreadable file is here:
http://www.superflexible.com/broken.sql

Works fine under Snow Leopard.

I get the same results when using my own application as when using
/usr/bin/sqlite3. So, we can concentrate on the sqlite3 command line tool.

I noticed that with the new sqlite version, I can no longer use the
CONSTRAINT keyword. In other words, in a CREATE TABLE script, I
had to change this:
CONSTRAINT PK_SECTIONS PRIMARY KEY (ID),
to this:
PRIMARY KEY (ID),


The broken.sql file works with 3.7.12 here. And I can do:

  SQLite version 3.7.12 2012-05-14 01:41:23
  Enter ".help" for instructions
  Enter SQL statements terminated with a ";"
  sqlite> CREATE TABLE t1(x, CONSTRAINT pk_cons PRIMARY KEY(x));
  sqlite>

There was a problem similar to your description at one point, but
it should have been fixed before the 3.7.12 release. What do you
get from the shell command "SELECT sqlite_source_id();" on
Mountain Lion?

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


Re: [sqlite] sqlite3 database unreadable on Mountain Lion

2012-08-03 Thread Tobias Giesen
Sounds like a plan!! Many thanks! 

Please excuse the shortness of this mail, as I am sending it from my phone. If 
necessary, I will send more details soon.
Warmest mobile regards from
Tobias Giesen


On 03.08.2012, at 19:12, Simon Slavin  wrote:

> 
> On 3 Aug 2012, at 5:48pm, Tobias Giesen  wrote:
> 
>> yes I can run the dump on Snow Leopard, but many of my customers do not
>> have Snow Leopard any more and they do not want to send me their files
>> for conversion.
>> 
>> The problem is that hundreds of customers need to convert/fix their 
>> files. It must be done under Mountain only and I have to automate it
>> or they will yell at me.
> 
> I suspect that the experts here will figure out what the problem is.  
> However, if your users with 10.8 do need to do the .dump, all you need send 
> them is the executable version of sqlite3 which comes with 10.7, and a script 
> which calls it.  It should run fine under 10.8 and does not have any 
> dependencies or call any libraries.
> 
> But give the experts time to explore your problem first, since by the look of 
> it it shouldn't be occurring.
> 
> 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] sqlite3 database unreadable on Mountain Lion

2012-08-03 Thread Simon Slavin

On 3 Aug 2012, at 5:48pm, Tobias Giesen  wrote:

> yes I can run the dump on Snow Leopard, but many of my customers do not
> have Snow Leopard any more and they do not want to send me their files
> for conversion.
> 
> The problem is that hundreds of customers need to convert/fix their 
> files. It must be done under Mountain only and I have to automate it
> or they will yell at me.

I suspect that the experts here will figure out what the problem is.  However, 
if your users with 10.8 do need to do the .dump, all you need send them is the 
executable version of sqlite3 which comes with 10.7, and a script which calls 
it.  It should run fine under 10.8 and does not have any dependencies or call 
any libraries.

But give the experts time to explore your problem first, since by the look of 
it it shouldn't be occurring.

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


Re: [sqlite] sqlite3 database unreadable on Mountain Lion

2012-08-03 Thread Tobias Giesen
Hello,

yes I can run the dump on Snow Leopard, but many of my customers do not
have Snow Leopard any more and they do not want to send me their files
for conversion.

The problem is that hundreds of customers need to convert/fix their 
files. It must be done under Mountain only and I have to automate it
or they will yell at me.

Cheers,
Tobias

 
> On 3 Aug 2012, at 5:33pm, Tobias Giesen  wrote:
> 
> > And a .dump results in an incomplete dump, otherwise it would be easy
> > for me to convert/fix the database.
> > 
> > The .dump does not give me any of the contents of the table DATA.
> 
> You should definitely be able run .dump using the shell tool in your 10.7 
> setup, then read the dump in using .read in your 10.8 setup to create a new 
> database file.
> 
> If you can't do the .dump on your 10.7 setup please run an integrity check
> 
> 
> 
> and tell us what it says (no need to paste a hundred error messages, just 
> summarise).
> 
> 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] sqlite3 database unreadable on Mountain Lion

2012-08-03 Thread Simon Slavin

On 3 Aug 2012, at 5:33pm, Tobias Giesen  wrote:

> And a .dump results in an incomplete dump, otherwise it would be easy
> for me to convert/fix the database.
> 
> The .dump does not give me any of the contents of the table DATA.

You should definitely be able run .dump using the shell tool in your 10.7 
setup, then read the dump in using .read in your 10.8 setup to create a new 
database file.

If you can't do the .dump on your 10.7 setup please run an integrity check



and tell us what it says (no need to paste a hundred error messages, just 
summarise).

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


Re: [sqlite] sqlite3 database unreadable on Mountain Lion

2012-08-03 Thread Tobias Giesen
Hello,

thanks for the replies! 

A sample Mountain-unreadable file is here:
http://www.superflexible.com/broken.sql

Works fine under Snow Leopard.

I get the same results when using my own application as when using 
/usr/bin/sqlite3. So, we can concentrate on the sqlite3 command line tool.

I noticed that with the new sqlite version, I can no longer use the
CONSTRAINT keyword. In other words, in a CREATE TABLE script, I 
had to change this:
CONSTRAINT PK_SECTIONS PRIMARY KEY (ID),
to this:
PRIMARY KEY (ID),

And the new sqlite version can't read the old sqlite files.

But there may be more to it.

And pragma integrity_check reports:
Error: malformed database schema (DATA) - near "CONSTRAINT":
syntax error

And a .dump results in an incomplete dump, otherwise it would be easy
for me to convert/fix the database.

The .dump does not give me any of the contents of the table DATA.

Cheers,
Tobias

 
> On 3 Aug 2012, at 3:33pm, Tobias Giesen  wrote:
> 
> > I have one particular type of database that has become unreadable on
> > the new Mac OS 10.8. It must be related to the SQL structure. The error
> > I get is "database disk image is malformed". But the same file, on
> > Snow Leopard, works fine.
> > 
> > The SQLite version on Snow Leopard is 3.6.12, and on Mountain Lion it
> > is 3.7.12.
> 
> How are you accessing this file ?  Are you using your own application or are 
> you using the shell tool included with Mac OS X in
> 
> /usr/bin/sqlite3
> 
> ?  In the folder where you find the database file on your 10.7 computer, are 
> there any other files with similar names ?  They may be journal files for 
> when the database was not closed properly.
> 
> > The strange thing is, when I attempt to load the sqlite3.dylib from
> > Snow Leopard under Mountain Lion, it also does not work. But I'm not
> > totally sure if loading the older sqlite3 library actually worked.
> 
> That may be totally unrelated to the file format.  You may be trying to open 
> the wrong dynamic library, or one compiled for a different OS, or something.  
> Check out the database itself using the shell tool, then involve a dynamic 
> library only once you're sure the database file is okay.
> 
> 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] sqlite3 database unreadable on Mountain Lion

2012-08-03 Thread Dan Kennedy

On 08/03/2012 09:33 PM, Tobias Giesen wrote:

Hello,

here's a problem that's puzzling me.

I have one particular type of database that has become unreadable on
the new Mac OS 10.8. It must be related to the SQL structure. The error
I get is "database disk image is malformed". But the same file, on
Snow Leopard, works fine.

The SQLite version on Snow Leopard is 3.6.12, and on Mountain Lion it
is 3.7.12.

The strange thing is, when I attempt to load the sqlite3.dylib from
Snow Leopard under Mountain Lion, it also does not work. But I'm not
totally sure if loading the older sqlite3 library actually worked.

Does anybody have any advice for me?


I'd like to see the database file if possible. Are you able to
post it somewhere or else mail it directly to me?

Dan.

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


Re: [sqlite] sqlite3 database unreadable on Mountain Lion

2012-08-03 Thread Adam DeVita
Good day,

I had a similar sounding issue on 2 different flavours of Windows.
The problem was an over active anti-virus program.

Adam

On Fri, Aug 3, 2012 at 11:45 AM, Simon Slavin  wrote:
>
> On 3 Aug 2012, at 3:33pm, Tobias Giesen  wrote:
>
>> I have one particular type of database that has become unreadable on
>> the new Mac OS 10.8. It must be related to the SQL structure. The error
>> I get is "database disk image is malformed". But the same file, on
>> Snow Leopard, works fine.
>>
>> The SQLite version on Snow Leopard is 3.6.12, and on Mountain Lion it
>> is 3.7.12.
>
> How are you accessing this file ?  Are you using your own application or are 
> you using the shell tool included with Mac OS X in
>
> /usr/bin/sqlite3
>
> ?  In the folder where you find the database file on your 10.7 computer, are 
> there any other files with similar names ?  They may be journal files for 
> when the database was not closed properly.
>
>> The strange thing is, when I attempt to load the sqlite3.dylib from
>> Snow Leopard under Mountain Lion, it also does not work. But I'm not
>> totally sure if loading the older sqlite3 library actually worked.
>
> That may be totally unrelated to the file format.  You may be trying to open 
> the wrong dynamic library, or one compiled for a different OS, or something.  
> Check out the database itself using the shell tool, then involve a dynamic 
> library only once you're sure the database file is okay.
>
> Simon.
> ___
> sqlite-users mailing list
> sqlite-users@sqlite.org
> http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users



-- 
VerifEye Technologies Inc.
905-948-0015x245
151 Whitehall Dr, Unit 2
Markham ON, L3R 9T1
Canada
___
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users


[sqlite] sqlite3 database unreadable on Mountain Lion

2012-08-03 Thread Tobias Giesen
Hello,

here's a problem that's puzzling me.

I have one particular type of database that has become unreadable on
the new Mac OS 10.8. It must be related to the SQL structure. The error
I get is "database disk image is malformed". But the same file, on
Snow Leopard, works fine.

The SQLite version on Snow Leopard is 3.6.12, and on Mountain Lion it
is 3.7.12.

The strange thing is, when I attempt to load the sqlite3.dylib from
Snow Leopard under Mountain Lion, it also does not work. But I'm not
totally sure if loading the older sqlite3 library actually worked.

Does anybody have any advice for me?

Many thanks!
Tobias Giesen
www.syncovery.com



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


[sqlite] sqlite3 database unreadable on Mountain Lion

2012-08-03 Thread Tobias Giesen
Hello,

here's a problem that's puzzling me.

I have one particular type of database that has become unreadable on
the new Mac OS 10.8. It must be related to the SQL structure. The error
I get is "database disk image is malformed". But the same file, on
Snow Leopard, works fine.

The SQLite version on Snow Leopard is 3.6.12, and on Mountain Lion it
is 3.7.12.

The strange thing is, when I attempt to load the sqlite3.dylib from
Snow Leopard under Mountain Lion, it also does not work. But I'm not
totally sure if loading the older sqlite3 library actually worked.

Does anybody have any advice for me?

Many thanks!
Tobias Giesen
www.syncovery.com



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