On 08/13/2016 01:14 AM, Ward WIllats wrote:
Consider:
1. Create a new database, set the pragma page_size=512
2. Create a new database on the connection with ATTACH DATABASE
'/tmp/number_two.db' AS second;
3. Issue pragma second.page_size=4096 to try and set the page size on the
attached DB to 4096.
4. Read back with pragma second.page_size and get the default page size of
1024. (We are still on 3.10.1)
Is it expected that the 4096 did not "stick?" Is there some relationship
between page sizes in a main and attached DB?
Can't reproduce this problem here. Are you able to reproduce it with the
shell tool?
$ ./sqlite3 x.db
SQLite version 3.10.1 2016-01-13 21:41:56
Enter ".help" for usage hints.
sqlite> PRAGMA main.page_size = 512;
sqlite> ATTACH '/tmp/two.db' AS second;
sqlite> PRAGMA second.page_size = 4096;
sqlite> PRAGMA second.page_size;
4096
sqlite> PRAGMA second.journal_mode = wal;
wal
sqlite> CREATE TABLE second.t1(a, b);
sqlite> PRAGMA second.page_size;
4096
sqlite> PRAGMA main.page_size;
512
Dan.
Thanks
-- Ward
(In real life, we also set journal_mode=WAL on both databases AFTER issuing the
page_size pragma, in case it makes any difference.)
_______________________________________________
sqlite-users mailing list
sqlite-users@mailinglists.sqlite.org
http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users
_______________________________________________
sqlite-users mailing list
sqlite-users@mailinglists.sqlite.org
http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users