Hello Sucameli.<br><br>In the shell  :<br>Python 2.4.3 (#1, Sep 21 2011, 20:06:00) <br>[GCC 4.1.2 20080704 (Red Hat 4.1.2-51)] on linux2<br>Type "help", "copyright", "credits" or "license" for more information.<br>
>>> import psycopg2<br>>>> conn = psycopg2.connect("dbname=routing user=postgres")<br> OK .<br><br>In Qgis <br>
<style type="text/css">p, li { white-space: pre-wrap; }</style>
<p style="margin: 0px; text-indent: 0px;">>>> import sys</p>
<p style="margin: 0px; text-indent: 0px;">>>> sys.version</p>
<p style="margin: 0px; text-indent: 0px;">'2.6.5 (r265:79063, Feb 28 2011, 21:55:56) \n[GCC 4.1.2 20080704 (Red Hat 4.1.2-50)]'</p><br>Thanks <br><div class="gmail_quote">2011/9/29 Giuseppe Sucameli <span dir="ltr"><<a href="mailto:sucameli@faunalia.it">sucameli@faunalia.it</a>></span><br>
<blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;">Hi Jules,<br>
<div class="im"><br>
> I've now Install psycopg2 2.4.2 and it run perfectly .<br>
<br>
</div>how do you know it runs? did you try it from the shell?<br>
<div class="im"><br>
On Thu, Sep 29, 2011 at 12:23 PM, Jules Kouadio <<a href="mailto:sekedoua@gmail.com">sekedoua@gmail.com</a>> wrote:<br>
> but i get always the same message when i try to run RT Sql Layer  .<br>
> Even in the qgis python console with the phyton command "import" psycopg2<br>
</div>[[CUT]]<br>
<div class="im">> ImportError: No module named psycopg2<br>
<br>
</div>To help you we need more info,<br>
the OS you run QGis on, the python version used by QGis.<br>
<br>
I know that some people have throuble on Debian OS after<br>
installing python 2.7 and keeping the 2.6 version installed.<br>
I don't know if your problem may be due to this, just tell us<br>
if the version of python running from the shell it's the same of<br>
the one used by QGis.<br>
<br>
To know the running python version, just open the qgis python<br>
console and run:<br>
<br>
import sys<br>
sys.version<br>
<br>
Regards.<br>
<div class="im"><br>
><br>
> 2011/9/29 Noli Sicad <<a href="mailto:nsicad@gmail.com">nsicad@gmail.com</a>><br>
>><br>
>> Download and install psycopg2 2.4.2.<br>
>><br>
>> It is python package, not part of QGIS or QGIS plugins.<br>
>><br>
>> Python-PostgreSQL Database Adapter<br>
>> <a href="http://pypi.python.org/pypi/psycopg2" target="_blank">http://pypi.python.org/pypi/psycopg2</a><br>
>><br>
>> Noli<br>
>><br>
>><br>
>> On 9/29/11, Jules Kouadio <<a href="mailto:sekedoua@gmail.com">sekedoua@gmail.com</a>> wrote:<br>
>> > Hello .<br>
>> > Installation is ok<br>
>> > I get this message when i try to run it<br>
>> > Couldn't import Python module 'psycopg2' for communication with PostgreSQL<br>
>> > database.<br>
>> > Its the same problem whith Postgis Manager Plugin.<br>
>> > My Os version is centos 5.5<br>
>> > Qgis version 1.8.0-Trunck<br>
>> ><br>
>> > --<br>
>> > *<br>
>> > *<br>
>> ><br>
><br>
><br>
><br>
> --<br>
><br>
><br>
><br>
><br>
><br>
</div><div><div></div><div class="h5">> _______________________________________________<br>
> Qgis-user mailing list<br>
> <a href="mailto:Qgis-user@lists.osgeo.org">Qgis-user@lists.osgeo.org</a><br>
> <a href="http://lists.osgeo.org/mailman/listinfo/qgis-user" target="_blank">http://lists.osgeo.org/mailman/listinfo/qgis-user</a><br>
><br>
<br>
<br>
<br>
</div></div><font color="#888888">--<br>
Giuseppe Sucameli<br>
</font></blockquote></div><br><br clear="all"><br>-- <br><font size="6"><b style="color: rgb(0, 51, 51); font-family: courier new,monospace;"><img src="http://skejaime.exen.fr/img/signature.jpg"><br></b><span style="color: rgb(0, 51, 51); font-family: courier new,monospace;"><br>
<br></span></font><br>