Page 1 of 1

Create Firebird DB in Runtime ignore page_size and collation

Posted: 13.10.2021, 15:28
by hamacker
Hi guys, I´am new user of ZeosLib and maybe my mistake. but when I try to create a firebird database using sample code that I found in doc, and add page_size and collation parameters then database is created but page size always 8192(my test was 16384) and collate always 'UT8' (my test was UNICODE_CI_AI). My code sample using FPC 3.22, Lazarus IDE 2.3 and ZeosLib 7.2.15 build from OPM(Online Package Manager):
AConn.Properties.Values['CreateNewDatabase'] :=
'CREATE DATABASE ' + QuotedStr(AConn.Database) + // 'C:\PATH\TO\DATABASE.FDB'
' USER ' + QuotedStr(AConn.User) + // 'SYSDBA'
' PASSWORD ' + QuotedStr(AConn.Password) + // 'masterkey'
' PAGE_SIZE ' + intToStr(APAGE_SIZE) + // '16384'
' DEFAULT CHARACTER SET '+QuotedStr(ACHARSET) + // 'UTF8'
' COLLATION '+QuotedStr(ACOLLATION) +';'; // 'UNICODE_CI_AI'
//todo: o codigo acima esta criando pagina 8192 e collation UTF8, desrespeitando os parametros page_size e collation
//que passamos
AConn.Connect;

Re: Create Firebird DB in Runtime ignore page_size and collation

Posted: 13.10.2021, 17:36
by marsupilami
Hello hamacker,

which version of Zeos do you use? You surely don't use Zeos 7.1? If you use Zeos 7.1 please upgrade to Zeos 7.2 or consider upgrading to Zeos 8.0.

Best regards,

Jan

Re: Create Firebird DB in Runtime ignore page_size and collation

Posted: 14.10.2021, 22:04
by hamacker
Thanks for your reply, so... I use FreePascal 3.22, Lazarus IDE 2.3 and ZeosLib 7.2.15 build from sources via OPM(Online Package Manager)
The command does not fail, it´s create a database but not page and collate that I specify.
Is there a ZeosLib 8, where?

Re: Create Firebird DB in Runtime ignore page_size and collation

Posted: 15.10.2021, 13:02
by marsupilami
Hello hamacker,

we had a bug where we created databases from the connection settings rather than from the create database string. I am not sure, wether this is solved already. You might want to give Zeos 8.0 a try, the bug could be fixred there. It is not released yet but that is more of a problem of documentation. In all other aspects it is ready for release. See https://sourceforge.net/p/zeoslib/code-0/HEAD/tree/branches/8.0-patches/. You might want to use Subversion to ckeck out the latest revision from time to time.

Regarding Zeos 7.2.15: Are you sure, it shows that version number? OPM should only have Zeos 7.2.14 available. 7.2.15 is a development version, that is only available from the SVN currently. Maybe you installed it using LazFpcUp or something like this?

Best regards,

Jan

Re: Create Firebird DB in Runtime ignore page_size and collation

Posted: 19.10.2021, 15:48
by hamacker
Yes, I am sure!
But in Linux ZeosDBO is 7.2.14
I use fpcupdeluge and build trunk of Lazarus-IDE 7.3(next release, but RC) for testing.
I'am learning ZeosDBO.

Re: Create Firebird DB in Runtime ignore page_size and collation

Posted: 19.10.2021, 16:25
by marsupilami

Re: Create Firebird DB in Runtime ignore page_size and collation

Posted: 03.11.2021, 17:06
by hamacker
I'am testing Zeos8 from github.
Where can I put question, before bugs?

Re: Create Firebird DB in Runtime ignore page_size and collation

Posted: 03.11.2021, 20:39
by aehimself
You can try the Zeos 8 category :)