Re: Database version

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Database version

Igor Korot
Hi, Peter,

On Fri, Jul 21, 2017 at 11:06 AM, Peter Da Silva
<[hidden email]> wrote:
> https://www.sqlite.org/c3ref/c_source_id.html

Those are for the library.
But...

Let's say I made some database files 2 years ago.
Now I want the current SQLite code to open them and performs some queries
from the C interface.

>
> This is also stored at offset 96 in the db file:
>
> https://www.sqlite.org/fileformat.html

Is this the number I'm after?

Thank you.

>
> I don’t think there’s a pragma for extracting it from within SQLite code.
>
> On 7/21/17, 9:58 AM, "sqlite-users on behalf of Igor Korot" <[hidden email] on behalf of [hidden email]> wrote:
>
>      Hi, ALL,
>     Is there a way to know the version of the .db file I am using?
>
>     I'd like to issue some kind of SELECT statement to get it.
>
>     Looks like there is an interface to get the library version, but I don't
>     see anything for a db file.
>
>     Thank you.
>     _______________________________________________
>     sqlite-users mailing list
>     [hidden email]
>     http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users
>
>
> _______________________________________________
> sqlite-users mailing list
> [hidden email]
> http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users
_______________________________________________
sqlite-users mailing list
[hidden email]
http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Database version

Peter da Silva
The problem is that SQLITE_VERSION_NUMBER is not “the database version”, it’s something like “the last version of SQLite that committed a transaction”.

The database version number is “3”.
 

_______________________________________________
sqlite-users mailing list
[hidden email]
http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users
Loading...