Search found 13 matches

by rayanAyar
23.05.2023, 05:15
Forum: User Patches
Topic: SQLite ExecuteDirect
Replies: 1
Views: 382

SQLite ExecuteDirect

I assume that method TZConnection.ExecuteDirect(const SQL: string) should send SQL to DB-library "as is". Without "preparing statements". Without any parsing and modifications. Am I right? This behavior is in TZPostgreSQLConnection.ExecuteImmediat: procedure TZPostgreSQLConnectio...
by rayanAyar
21.05.2023, 03:32
Forum: User Contributions
Topic: GetClientVersion for PostgreSQL
Replies: 4
Views: 1670

Re: GetClientVersion for PostgreSQL

aehimself wrote: 20.05.2023, 18:41 You are using C builder, correct?
Lazarus. Linux.
by rayanAyar
18.05.2023, 17:22
Forum: User Contributions
Topic: GetClientVersion for PostgreSQL
Replies: 4
Views: 1670

GetClientVersion for PostgreSQL

Draft patch "GetClientVersion for PostgreSQL".
Function gives version of client library.
Tested on git branch "8.0-patches".
by rayanAyar
12.01.2014, 16:24
Forum: ZeosLib 7.1 stable Forum
Topic: PostgreSQL performance - CAPIPreparedStatement
Replies: 4
Views: 1155

Re: PostgreSQL performance - CAPIPreparedStatement

Again just the first call should be slow. Reopening same query performes loads (hope the slow PG is really able to do that) faster than. Works slow every time. Try to keep one query request alive until you close your app. Than the prepared stmts do really make sence. Practically all querries that I...
by rayanAyar
11.01.2014, 10:59
Forum: ZeosLib 7.1 stable Forum
Topic: PostgreSQL performance - CAPIPreparedStatement
Replies: 4
Views: 1155

PostgreSQL performance - CAPIPreparedStatement

I migrated from Zeos 7.0.3 to 7.1.2. And PostgreSQL performance highly reduced in some parts of code. One query which executes several times per minute: on 7.0.3 takes 150 milliseconds on 7.1.2 takes 1000 milliseconds Еxamining and tracing code, I found some dirty solution: file "src/dbc/ZDbcPo...
by rayanAyar
11.01.2014, 05:36
Forum: SQLite
Topic: sqlite_prepare_v2
Replies: 6
Views: 2698

Re: sqlite_prepare_v2

Yes, that works for me (tested R3060 &R3062 on Zeos 7.1.2).
by rayanAyar
10.01.2014, 07:31
Forum: SQLite
Topic: sqlite_prepare_v2
Replies: 6
Views: 2698

Re: sqlite_prepare_v2

I meant that patching "procedure TZSQLiteCAPIPreparedStatement.Prepare" (patch R3060) does nothing. Because there is a typo in "TZSQLiteBaseDriver.Prepare_v2": function TZSQLiteBaseDriver. Prepare (db: Psqlite; const zSql: PAnsiChar; nBytes: Integer; out ppStmt: Psqlite3_stmt; pz...
by rayanAyar
10.01.2014, 03:14
Forum: SQLite
Topic: sqlite_prepare_v2
Replies: 6
Views: 2698

Re: sqlite_prepare_v2

Just commited your changes to \testing-7.2 (SVN) Patch done R3060 If patching "procedure TZSQLiteCAPIPreparedStatement.Prepare" then probably need to patch here: http://sourceforge.net/p/zeoslib/code-0/HEAD/tree/trunk/src/plain/ZPlainSqLiteDriver.pas#l990 Currently there is a typo: functi...
by rayanAyar
09.01.2014, 07:37
Forum: SQLite
Topic: sqlite_prepare_v2
Replies: 6
Views: 2698

sqlite_prepare_v2

Is there any reason to use SQLite API function "sqlite_prepare" instead of "sqlite_prepare_v2" ? Both functions are listed in code: http://sourceforge.net/p/zeoslib/code-0/HEAD/tree/trunk/src/plain/ZPlainSqLiteDriver.pas#l336 But used only first: http://sourceforge.net/p/zeoslib/...
by rayanAyar
20.02.2011, 09:47
Forum: User Contributions
Topic: 64 bits Compatibility
Replies: 8
Views: 3329

On 64 bit:
SizeOf(SizeInt) = SizeOf(Int64) = 8
SizeOf(Longint) = 4

systemh.inc(247):
{$ifdef CPU64}
SizeInt = Int64;
PtrInt = Int64;
...
{$endif CPU64}

{$ifdef CPU32}
SizeInt = Longint;
PtrInt = Longint;
...
{$endif CPU32}
by rayanAyar
14.01.2011, 02:12
Forum: User Contributions
Topic: 64 bits Compatibility
Replies: 8
Views: 3329

1. I can't check on D5. I have no windows. I work with Lazarus@Linux.

2. I am not author of the patch. I just made changes from first post by matthius. Check it work for me (Ubuntu 10.04 amd64). And made diff-file for convinience.
by rayanAyar
10.01.2011, 15:32
Forum: User Contributions
Topic: 64 bits Compatibility
Replies: 8
Views: 3329

Re: 64 bits Compatibility

matthius wrote:To be 64 bits compatible here is the code :
...
This changes as patch for Zeos 6.6.6