Re: [Lazarus] DBGrid displays Float as integer

2024-02-01 Thread LacaK via lazarus
If i execute: "SELECT CAST(AVG(km_gelaufen) *AS REAL*) FROM laufdaten" the known problem of integer only shows up again. BUT: If i execute this "SELECT CAST(AVG(km_gelaufen)  AS REAL) FROM laufdaten " in SQliteStudio it works as it should. Ok then it is clear that SQLite produces result

Re: [Lazarus] DBGrid displays Float as integer

2024-01-31 Thread LacaK via lazarus
Hi, IMO AVG() should produce floating point result. https://www.sqlite.org/lang_aggfunc.html#aggfunclist: The result of avg() is always a floating point value whenever there is at least one non-NULL input even if all inputs are integers. In SQLite plays role column affinity. I expect that

Re: [Lazarus] Dbnavigator won't post to MSACESS db

2023-12-10 Thread LacaK via lazarus
In my written code, yes. And I have no problems writing to the table that way. But using the Dbnavigator post button won’t work. Then I suspect that is your problem. The Dbnavigator post button only does a post, never ApplyUpdates and transaction commit. The ApplyUpdates can be

Re: [Lazarus] TSQLConnector for MySQL non-standard port

2023-04-24 Thread LacaK via lazarus
Hello, try use "Params" and put there "Port=" -Laco. Hi, I would like to use a non-standard port for my MySQL-connection. Is this possible ? If so, how ? Standard port is 3306. I tried to add my non-standard port to the hostname (:), but that does not work: 'TMySQL57Connection : Server

Re: [Lazarus] Mantis vs GitLab issue tracker

2021-08-16 Thread LacaK via lazarus
is it just my impression that Mantis was more feature rich an had better layout? An example: Mantis has "Reported by me". You can find this in your 'issues' list? It is my impression too. I would like to see panels (like in https://gitlab.com/groups/freepascal.org/-/boards): -

Re: [Lazarus] Mantis vs GitLab issue tracker

2021-08-16 Thread LacaK via lazarus
is it just my impression that Mantis was more feature rich an had better layout? An example: Mantis has "Reported by me". It is my impression too. I would like to see panels (like in https://gitlab.com/groups/freepascal.org/-/boards): - Reported by me (filter Author="my account") -

Re: [Lazarus] TSql57 replacement

2020-09-17 Thread LacaK via lazarus
Is there another way to connect now? I don't want to install Mysql 57. Cann't you use TMySQL57Connection with SkipLibraryVersionCheck property set to True? -Laco. -- ___ lazarus mailing list lazarus@lists.lazarus-ide.org

Re: [Lazarus] LazDataDesktop: transaction handling

2019-09-04 Thread LacaK via lazarus
If data of underlaying TSQLQuery are presented and edited only thorought this DBGrid then I would add to TSQLQuery option "sqoAutoApplyUpdates". (I am not familiar with architecture of LazDataDesktop) Which causes that on every Post/Delete updates are applied to database. There will remain

Re: [Lazarus] freetds + lazarus cannot get around "some character(s) could not be converted" error

2019-07-28 Thread LacaK via lazarus
Hello, I am attempting to write a Lazarus program using a TMSSQLConnection on Linux (Ubuntu 16.04 64 bit) with FreeTDS. Whenever I try to apply updates on my TSQLQuery component and commit the transaction on its associated TSQLtransaction component I receive this error: An error

Re: [Lazarus] How to deploy a Lazarus app for Windows?

2017-04-27 Thread LacaK via Lazarus
I remember using these: http://nsis.sourceforge.net/Main_Page http://www.jrsoftware.org/isinfo.php If you need installer in Microsoft Installation Package format (*.msi) then you can look at WiX toolset: http://wixtoolset.org and WixEdit: http://wixedit.sourceforge.net/ -Laco. --

Re: [Lazarus] Request for apply patch

2017-04-05 Thread LacaK via Lazarus
Hi Lazarus Developers, can somebody please look at and if all okay apply patch in bug report http://bugs.freepascal.org/view.php?id=27764 There is one new unit which implements simple Delphi compatible Database Login Dialog. Hi, I have updated patch attached to #27764 (Database Login

Re: [Lazarus] Linux 64 to Linux ARC crosscompile was:Lazarus and Windows 10 IoT

2017-03-30 Thread LacaK via Lazarus
Alternate solution to my modified question (Cross-compile from Windows to Linux/ARM): - Download FpcUpDeluxe executable from https://github.com/newpascal/fpcupdeluxe/releases (in my case 1.2.0m) - Run it and choose InstallDir (for example D:\TEMP\fpcupdeluxe) - Select FPC and Lazarus version

Re: [Lazarus] Linux 64 to Linux ARC crosscompile was:Lazarus and Windows 10 IoT

2017-03-29 Thread LacaK via Lazarus
I am sure taht this question was already asked, but I can not find clear answer. Is there possibility to create Lazarus application with GUI which will run on Raspberi Pi - ARM - Windows 10 IoT ? (Target OS=Win32, Target CPU=Arm ?) If not, is there possibility to create same application

Re: [Lazarus] Writing >1000 TBufDataset records to file is extremely slow

2017-03-27 Thread LacaK via Lazarus
But now another issue is coming up: If I increase the number of records to 40,000 population of records slows down after about 10,000 records, speeds up again, and comes to an apparant stand-still for 32900 records. After waiting some time the record counter (which is incremented in steps of

Re: [Lazarus] Writing >1000 TBufDataset records to file is extremely slow

2017-03-27 Thread LacaK via Lazarus
Try call FExportDataset.MergeChangeLog before: WriteLn('Saving...'); Does anything in your timing changed ? Ah - that's it. TBufDataset saves the records instantly now. Probably, this should go into the official wiki site for TBufDataset. But now another issue is coming up: If I

Re: [Lazarus] Writing >1000 TBufDataset records to file is extremely slow

2017-03-27 Thread LacaK via Lazarus
Try call FExportDataset.MergeChangeLog before: WriteLn('Saving...'); Does anything in your timing changed ? -Laco. -- ___ Lazarus mailing list Lazarus@lists.lazarus-ide.org http://lists.lazarus-ide.org/listinfo/lazarus

[Lazarus] Request for apply patch

2017-02-09 Thread LacaK via Lazarus
Hi Lazarus Developers, can somebody please look at and if all okay apply patch in bug report http://bugs.freepascal.org/view.php?id=27764 There is one new unit which implements simple Delphi compatible Database Login Dialog. Thanks -Laco. -- ___

Re: [Lazarus] SQLite & DB Aware Components

2016-12-01 Thread LacaK via Lazarus
Dňa 1.12.2016 o 21:40 Martin Collins via Lazarus napísal(a): On 01/12/16 16:15, Martin Collins via Lazarus wrote: From what I understand, SQLite TEXT type has no set length so db aware components treat it as a memo. Therefore when I assign a TEXT field to a db aware component, all that appears

Re: [Lazarus] Lazarus and MySQL 5.7

2016-11-28 Thread LacaK via Lazarus
What version of Lazarus can connect to MySQL 5.7 using TSqlConnector? My laptop has 1.6 and does not seem to be able to connect using that component. I added TMySQL57Connection to trunk (1.7). Thank you Mattias. -Laco. -- ___ Lazarus mailing list

Re: [Lazarus] Lazarus and MySQL 5.7

2016-11-21 Thread LacaK via Lazarus
Hi, Please create bug report on http://bugs.freepascal.org and attach your modified files (at least ;-)) -Laco. Sorry, the link below is broken. This is the good one: http://www.bononiadocta.it/Lazarus/Sqldb.tar.bz2 Il 22/11/2016 01:37, Giuliano Colla ha scritto: I cannot contribute the

Re: [Lazarus] Open Office dbase

2016-11-13 Thread LacaK via Lazarus
You can use TDBF component or TODBCConnection (from FCL DB) with dBase or FoxPro driver (I do not known if exists for Linux) -Laco. I have an application that creates dbase files and writes information to them. I now need a procedure that will open the newly filled table so that it can be

Re: [Lazarus] TThread.Synchronize

2016-10-26 Thread LacaK via Lazarus
Dňa 26.10.2016 o 11:17 Michael Schnell via Lazarus napísal(a): On 26.10.2016 07:57, LacaK via Lazarus wrote: procedure TRefreshFileListThread.Execute; begin while not Terminated do begin Synchronize(@MyForm.UpdateFileList); // UpdateFileList is method which clears listbox and then adds

Re: [Lazarus] TThread.Synchronize

2016-10-26 Thread LacaK via Lazarus
Big Thanks to all. Now I understand what is happening ... probably I wil use critical section to block access from thread when code in main thread is performed ... -Laco. ShowModal() for a modal form will call it. [...] I did test in Delphi and Delphi seems also perform synchronize upon

Re: [Lazarus] TThread.Synchronize

2016-10-26 Thread LacaK via Lazarus
ShowModal() for a modal form will call it. Ah really? It happens in my application! Then that is your problem. :-))) But is it correct behavior ? IMO it is against thread safety, which should Synchronize guarantee! The two issues are completely unrelated. The current behaviour is

Re: [Lazarus] TThread.Synchronize

2016-10-25 Thread LacaK via Lazarus
Check for Application.ProcessMessages and CheckSynchronize calls. These process synchronize queue, if I am not mistaken. I do not call CheckSynchronize nor ProcessMessages in my application. So only any LCL component or widget set can call it in background ? ShowModal() for a modal form

Re: [Lazarus] TThread.Synchronize

2016-10-25 Thread LacaK via Lazarus
I do not call CheckSynchronize nor ProcessMessages in my application. So only any LCL component or widget set can call it in background ? It should be easy for you to set a breakpoint into MyForm.MyMethod and check the call stack. But error (AV) happens only in production and only

Re: [Lazarus] TThread.Synchronize

2016-10-25 Thread LacaK via Lazarus
Check for Application.ProcessMessages and CheckSynchronize calls. These process synchronize queue, if I am not mistaken. I do not call CheckSynchronize nor ProcessMessages in my application. So only any LCL component or widget set can call it in background ? From Delphi doc: "Synchronize

Re: [Lazarus] TThread.Synchronize

2016-10-25 Thread LacaK via Lazarus
My understanding is that, Synchronize schedules execution of MyForm.MyMethod to main thread, so method is not executed until control is returned from event handler in MyForm. Right? TThread.Synchronze pushes the procedure that is given as a parameter (including it's Self pointer) to the

[Lazarus] TThread.Synchronize

2016-10-25 Thread LacaK via Lazarus
Hi *, I have form on which is button. When user clicks button OnClick event handler is called (it is method of form). Processing of this method takes some time say 1 minute. In the background is operating another thread which every 10 seconds calls Synchronize(@MyForm.MyMethod). My

Re: [Lazarus] ActiveX, TOLEControl

2016-10-19 Thread LacaK via Lazarus
Hi *, I need help with OCX component (not visual I guess), which I need use in Lazarus application (to control another application, which supplies this OCX control). I have imported type library using importtl.exe (new unit was created successfully) Then in program I have created

[Lazarus] ActiveX, TOLEControl

2016-10-18 Thread LacaK via Lazarus
Hi *, I need help with OCX component (not visual I guess), which I need use in Lazarus application (to control another application, which supplies this OCX control). I have imported type library using importtl.exe (new unit was created successfully) Then in program I have created instance:

Re: [Lazarus] TDBEdit, TStringField Size, DataSize, DisplayWidth and MaxLength

2016-10-14 Thread LacaK via Lazarus
Dňa 14.10.2016 o 10:08 Tony Whyman via Lazarus napísal(a): On 14/10/16 06:43, LacaK via Lazarus wrote: I do not know IBX, but don't you use overriden TDataSet.InternalInitFieldDefs ? It will allow you put extra info into FieldDef and then use overriden TDataSet.CreateFields, which will allow

Re: [Lazarus] TDBEdit, TStringField Size, DataSize, DisplayWidth and MaxLength

2016-10-13 Thread LacaK via Lazarus
I am aware of it. I have not added all other MBCS because ! I doubt, which are realy used nowadays. My guess is that UTF-8 is far most used / supported as client character set. No problem to add them if there will be real demand from users ... Perhaps the correct answer is to let the

Re: [Lazarus] Teaching Pascal at College

2016-10-12 Thread LacaK via Lazarus
I would also caution against starting on GUI programming too early. +1 (few years ago I have teached programing on school in our city. I am not a techaer, but school lost teacher and was not able to find someone else) I have used FreePascal + Lazarus for my courses, but we have used only

Re: [Lazarus] TDBEdit, TStringField Size, DataSize, DisplayWidth and MaxLength

2016-10-11 Thread LacaK via Lazarus
> > Which FPC version is this likely to be released in?> 3.0.2 - no3.0.4 - ? 3.2.0 - yes> On a quick review of the code, all seems good. Just

Re: [Lazarus] TDBEdit, TStringField Size, DataSize, DisplayWidth and MaxLength

2016-10-11 Thread LacaK via Lazarus
An IBX user came to me with a problem and the problem seems to be a deep seated disconnect between multi-byte character sets, TStringField.Size and TDBEdit.MaxLength. Something needs to give - but I am not sure what should. Firstly documentation: If you go back to Delphi, TField.DataSize

[Lazarus] Jpeg Exif reader was: TImage shows loaded image rotated by 90?

2016-09-29 Thread LacaK via Lazarus
Attached improved code. (as far as there is a lot of Exif tags, not all are parsed and placed in FExif record, but all are in FIFD array) -Laco. I have created small Exif reader for my own needs. I have looked also in FCL TFPReaderJpeg (which uses pasjpeg) if there is no support, but I do not

Re: [Lazarus] TLazIntfImage.Assign ?

2016-09-29 Thread LacaK via Lazarus
IMO it can be removed - obviously there are not any side effects any more. Ok, I will remove it ... Thanks ;-) -Laco -- ___ Lazarus mailing list Lazarus@lists.lazarus-ide.org http://lists.lazarus-ide.org/listinfo/lazarus

[Lazarus] TLazIntfImage.Assign ?

2016-09-27 Thread LacaK via Lazarus
Hi, Please look at implementation : procedure TLazIntfImage.Assign(Source: TPersistent); var Src: TLazIntfImage; Desc: TRawImageDescription; begin if Source is TLazIntfImage then begin Src:=TLazIntfImage(Source); Desc:=Src.DataDescription; Desc.Width:=0; // avoid side

Re: [Lazarus] TImage shows loaded image rotated by 90?

2016-09-26 Thread LacaK via Lazarus
I have created small Exif reader for my own needs. I have looked also in FCL TFPReaderJpeg (which uses pasjpeg) if there is no support, but I do not see. If there would be interest for extending functionality of this reader to support reading of Exif information I can prepare patch. There

Re: [Lazarus] TImage shows loaded image rotated by 90?

2016-09-26 Thread LacaK via Lazarus
I have created small Exif reader for my own needs. I have looked also in FCL TFPReaderJpeg (which uses pasjpeg) if there is no support, but I do not see. If there would be interest for extending functionality of this reader to support reading of Exif information I can prepare patch. Here is