Page 2 of 6

Posted: 05.04.2012, 21:10
by elidorio2
I downloaded the latest version of svn (1132), when installing the message below:
C: \ lazarus \ components \ Zeos \ src \ component \ ZDatasetUtils.pas (1176.55) Error: Incompatible type for arg no. 1: Got "TDateTime," expected "Int64"

I'm using windows 7 64 09.30.2 with Lazarus.

Posted: 05.04.2012, 21:23
by EgonHugeist
Now you start making me curious. I Use the same FPC/Lazarus on W32.

Are you sure there are no old dcu's/ppu's and old packages? Please be sure. Remove all old files and compile/add the packages...

Posted: 06.04.2012, 13:44
by elidorio2
Hello EgonHugeist,

Actually the problem continues, I had the pleasure of assembling a new machine with virtualbox and installed Lazarus 09.30.2 and Zeos last svn version (1132).
It appears that errors
Lazarus 09.30.2 below error:
C: \ lazarus \ components \ zeos \ src \ component \ ZDatasetUtils.pas (1176.55) Error: Incompatible type for arg no. 1: Got "TDateTime," expected "Int64"

I also tested with Lazarus 09.30.4, the error:
F: \ Development \ Components \ zeos700-alpha \ src \ core \ ZClasses.pas (84.22) Error: No matching Implementation for interface method "IUnknown.QueryInterface (constref TGuid, out <Formal type>): LongInt; stdcall; "found

Posted: 08.04.2012, 04:58
by elidorio2
Hello EgonHugeist,

Please help me, my problem is with windows 7 64 bit.
Under Windows 32 is working with the normal version 7.0.0-dev

Posted: 08.04.2012, 10:43
by ism
Try this

Code: Select all

Index: src/dbc/ZDbcPostgreSqlUtils.pas
===================================================================
--- src/dbc/ZDbcPostgreSqlUtils.pas	(revision 1136)
+++ src/dbc/ZDbcPostgreSqlUtils.pas	(working copy)
@@ -166,7 +166,7 @@
     if Connection.GetClientCodePageInformations^.Encoding = ceUTF8 then
       Result := {$IFNDEF WITH_UTF8_CONTROLS}stUnicodeString{$ELSE}stString{$ENDIF}
     else
-    {$ENDIF}
+
       Result := stString
   else if TypeName = 'text' then
     Result := stAsciiStream

Posted: 08.04.2012, 11:13
by EgonHugeist
ism, thanks for your hint again. Patch done Rev. 1137. I'll write MDeams to give you commit rights for the repositories on SourceForge.Net! Your help is allways welcome. (But he has to deside this.)

elidorio2,

Delete really all old Zeos7 files on your W64 system

i don't know if you use TortoiseSVN.

Here is a workaround:
Use either
http://zeoslib.svn.sourceforge.net/view ... /?view=tar

or
http://zeoslib.svn.sourceforge.net/view ... /?view=tar

to download the latest Zeos7 files without TortoiseSVN.

I think ism, can confirm that Zeos7 compiles without problems on FPC2.6, Lazarus 0.90.3.2 and Windows64/Linux64 Bit.

So the problem can only be on your computer. And i don't know what's going wrong there....


best regards

Posted: 08.04.2012, 19:24
by elidorio2
Hello EgonHugeist,


The problem continues, I downloaded the zeos, as you talked ZeosLib-testing.tar, as you said. It has the same errors:
I tested with Windows 7 and Lazarus 09.30.4. FPC 2.6.0
09.30.2 FPC 2.4.4 Lazarus


C: \ lazarus \ components \ Zeos \ testing \ src \ component \ ZDatasetUtils.pas (1176.55) Error: Incompatible type for arg no. 1: Got "TDateTime," expected "Int64"

C: \ lazarus \ components \ Zeos \ testing \ src \ component \ ZDatasetUtils.pas (1176.55) Error: Incompatible type for arg no. 1: Got "TDateTime," expected "Int64"

Note:
EgonHugeist, could you possibly acessaar my machine, then you will not see the error in the mine, turn all the installation of Zeos and error continues.
Add me on msn: edson.lidorio @ gmail.com
gtalk: edson.lidorio @ gmail.com

Greetings

Edson

Posted: 08.04.2012, 20:46
by EgonHugeist
I found the problem:

http://www.lazarus.freepascal.org/index ... ic=13071.0

This is a FPC-Bug?? with win64.

Tried to solve it. Please download the testing-egonhugeist branch again. Is the problem still present? Rev.1140

EgonHugeist

Posted: 08.04.2012, 21:42
by ism
not solved , maybe problem in length pointer in 64 bit

with this patch all compiling , but i not test the work for rev 1140 testing

what {$IFNDEF OLDFPC} ?

Code: Select all

Index: src/component/ZDatasetUtils.pas
===================================================================
--- src/component/ZDatasetUtils.pas	(revision 1140)
+++ src/component/ZDatasetUtils.pas	(working copy)
@@ -1156,34 +1156,8 @@
   @return a data which contains a value.
 }
 function NativeToDateTime(DataType: TFieldType; Buffer: Pointer): TDateTime;
-{$IFNDEF OLDFPC}
-var
-  TimeStamp: TTimeStamp;
 begin
-  case DataType of
-    ftDate:
-      begin
-        TimeStamp.Time := 0;
-        TimeStamp.Date := Integer(Buffer^);
-      end;
-    ftTime:
-      begin
-        TimeStamp.Time := Integer(Buffer^);
-        TimeStamp.Date := DateDelta;
-      end;
-  else
-    try
-      TimeStamp := MSecsToTimeStamp(TDateTime(Buffer^));
-    except
-      TimeStamp.Time := 0;
-      TimeStamp.Date := 0;
-    end;
-  end;
-  Result := TimeStampToDateTime(TimeStamp);
-{$ELSE}
-begin
   Result := TDateTime(Buffer^);
-{$ENDIF}
 end;
 
 {**

Posted: 08.04.2012, 21:58
by ism
testing-egonhugeist rev 1140 not needed
and still does not compile

Posted: 08.04.2012, 22:38
by EgonHugeist
ism,

OLDFPC: look to zeoslazarus.inc... I'm not a fpc spezialist.

Can you help me? Solution?? Any ideas?

grumble :wallb: :wallb:

This problem only occours with Windows64 and MSecsToTimeStamp();
Do you have a Win64 system?

Dont want to change the purpose of the function, ism. Which your patch does. Next round: Rev. 1141

Posted: 09.04.2012, 02:41
by elidorio2
Hello EgonHugeist and Ism,
Now yes, the installation was normal Rev. 1141.
Now I will test the question of dll files that were also in trouble.
So I put the test feedback.

Posted: 09.04.2012, 15:44
by elidorio2
Hello EgonHugeist,

I'm doing the test with the version (1141) and when trying to connect to any database Postgresql appears the error message: Access violation.
Attached.
Performed the test with Lazarus 09.30.2 09.30.4 fpc 2.4.4 and lazarus fpc 2.6 and windows 7 64, is the same error message.

Posted: 09.04.2012, 16:21
by EgonHugeist
elidorio2,

is the problem present if yov'e choosen a ClientCodePage? Have you eventualy a mix of 64/32 Bit Dll's?

Does this issue appear on runtime too?

I can acces PG9 without problems...

Posted: 09.04.2012, 18:12
by elidorio2
I set the codepage and yet appearing AV error.
I am using a new machine to test where there is only the dll pg 64.
I ran into the same runtime error occurs. I think the other problem persite version. I copied the dll pg for the application folder and still not resolved.