Create Firebird DB in Runtime ignore page_size and collation

The official tester's forum for ZeosLib 7.1. Ask for help, post proposals or solutions.
Post Reply
hamacker
Junior Boarder
Junior Boarder
Posts: 37
Joined: 13.10.2021, 15:15

Create Firebird DB in Runtime ignore page_size and collation

Post 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;
marsupilami
Platinum Boarder
Platinum Boarder
Posts: 1939
Joined: 17.01.2011, 14:17

Re: Create Firebird DB in Runtime ignore page_size and collation

Post 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
hamacker
Junior Boarder
Junior Boarder
Posts: 37
Joined: 13.10.2021, 15:15

Re: Create Firebird DB in Runtime ignore page_size and collation

Post 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?
marsupilami
Platinum Boarder
Platinum Boarder
Posts: 1939
Joined: 17.01.2011, 14:17

Re: Create Firebird DB in Runtime ignore page_size and collation

Post 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
hamacker
Junior Boarder
Junior Boarder
Posts: 37
Joined: 13.10.2021, 15:15

Re: Create Firebird DB in Runtime ignore page_size and collation

Post 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.
hamacker
Junior Boarder
Junior Boarder
Posts: 37
Joined: 13.10.2021, 15:15

Re: Create Firebird DB in Runtime ignore page_size and collation

Post by hamacker »

I'am testing Zeos8 from github.
Where can I put question, before bugs?
User avatar
aehimself
Zeos Dev Team
Zeos Dev Team
Posts: 787
Joined: 18.11.2018, 17:37
Location: Hungary

Re: Create Firebird DB in Runtime ignore page_size and collation

Post by aehimself »

You can try the Zeos 8 category :)
Delphi 12.1, Zeos 8 from latest GIT snapshot
Using:
- MySQL server 8.0.18; libmariadb.dll 3.3.8
- Oracle server 11.2.0, 12.1.0, 19.0.0; oci.dll 21.13
- MSSQL 2012, 2019; sybdb.dll FreeTDS_2435
- SQLite 3.45.2
Post Reply