Hi all,
I quickly tried to connect to a PostgreSQL server via a TPQConnection: put the relevant controls in a form, filled in data (IP addresses, passwords...), solved problems with DLLs in winslow 64 bits, and finally I succeeded in performing SQL queries interactively in TSQLquery dialog box. I even put a DBGrid on the form, and it works - in design mode.
BUT, when the program is run, as soon as the DBGrid is clicked, or a DBNavigator is used, the program crashes. Typical errors are stack overflow and segment fault. The debugger seems lost and does not give reliable informations.
I tried different versions of various DLLs (libpq and companions), but nothing changed.
Then I upgraded Lazarus from 1.6.4 to 1.8.4: nothing changed.
Then I installed Lazarus on a Ubuntu X64 machine, which has a fully functional Postgre server running (in production): nothing changed.
Then, on the same form, I duplicated the same controls as before, side by side, but with a connection to an MS-SQL server. At design time, all is ok. When running, the form starts ok (for both Postgre and MSSQL); the MS-SQL part is fully workable and clickable; as soon as I touch the Postgre part, the program crashes as before. So it seems that the problem lies in TPQConnection, but then why in design mode all is ok?
I've seen that this problem with Postgre has already been reported in this forum, twice this year, with no replies.
What should I do? Does somebody has a suggestion? Should I signal a bug? TY.