Jong, I did not make much changes to the fpc files itself. The only change I made to the api wrapper is the location of the libpq.so / dll file. It use to load from current working dir, or going on a rampant search according to the LD_LIBRARY_PATH environment variable on linux. I made a mod where the location of the lib file may be set.<br>
<br>You might not be able to use this code at all due to the TDataSet ancestry being non existent.. BUT, if you can find any use at all for this code, check it out at svn://<a href="http://196.36.108.47/fpc_pgsqlclientlib">196.36.108.47/fpc_pgsqlclientlib</a><br>
<br>The classes are in libpq_components.pas. References to other units to compile is in an svn external under lib directory.<br><br>The code is extremely ugly. Good luck.<br><br><div class="gmail_quote">On Mon, Aug 17, 2009 at 1:30 PM, Graeme Geldenhuys <span dir="ltr"><<a href="mailto:graemeg@opensoft.homeip.net">graemeg@opensoft.homeip.net</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;"><div class="im">Desmond Coertzen wrote:<br>
<blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
I tried TPQConnection in a production environment on a server-side deamon, and bytea was the first missing data type that haunted me. The "encode" postgres function will save you here: Encode your bytea field <br>
</blockquote>
<br></div>
I can't remember, but I think bytea (I call it blob) work fine for me, but I'll have to double check to be 100% sure.<div class="im"><br>
<br>
<br>
<blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
to hex, then run a hextobin afterwards. (Sorry if you use dbAware components in this case). Some other field types were missing as well, I <br>
</blockquote>
<br></div>
I do not use DB-aware components in our applications. I use "mediator views" also know as Model-GUI-Mediator. The the following URL for an article on it.<br>
<br>
<a href="http://opensoft.homeip.net/articles/" target="_blank">http://opensoft.homeip.net/articles/</a><br>
<br>
<br>
<blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
of TDataSet, but, it worked for everything I needed in those daemons, it is lightweight and stable. !!/No support for parameters and prepared statements/!!<br>
</blockquote>
<br>
I have had some "prepare statement" issues with SqlDB+PostgreSQL as well. I still need to investigate this further. In the mean time, I disable all "prepare" calls in my application for now.<div class="im">
<br>
<br>
<br>
<blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
I'm still a novice pascal programmer. If you are interested in my code, I can publish somewhere and send you a url.<br>
</blockquote>
<br></div>
Are we allowed to merge some of your changes back into the SqlDB code? If so, yes please do post a url.<br>
<br>
<br>
Regards,<br>
- Graeme -<br><font color="#888888">
<br>
-- <br>
fpGUI Toolkit - a cross-platform GUI toolkit using Free Pascal</font><div><div></div><div class="h5"><br>
<a href="http://opensoft.homeip.net/fpgui/" target="_blank">http://opensoft.homeip.net/fpgui/</a><br>
<br>
_______________________________________________<br>
fpc-devel maillist - <a href="mailto:fpc-devel@lists.freepascal.org" target="_blank">fpc-devel@lists.freepascal.org</a><br>
<a href="http://lists.freepascal.org/mailman/listinfo/fpc-devel" target="_blank">http://lists.freepascal.org/mailman/listinfo/fpc-devel</a><br>
</div></div></blockquote></div><br>