<div dir="ltr"><div><div><div><div>For me the advantage is simple: I have a few plpgsql functions which create tables with variables computed from some quite large tables. I then use these tables as input to create other result tables (with geometry).<br>
<br></div>And yes, the advantage is not to deal with multiple deleting in the end of each session.<br><br></div>As you say, perhaps the best is to contact Giuseppe Sucameli to see whether this could be improved (if of course is an useful feature for other users).<br>
<br></div>Thanks,<br></div>António<br><div><div><div><div><div><div><br></div></div></div></div></div></div></div><div class="gmail_extra"><br><br><div class="gmail_quote">2013/10/22 Andreas Neumann <span dir="ltr"><<a href="mailto:a.neumann@carto.net" target="_blank">a.neumann@carto.net</a>></span><br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">ok - wasn't aware of that.<br>
<br>
What is the advantage of using these temp tables? That you do not have<br>
to deal with deleting the table?<br>
<br>
I am not too familiar with the internals of db-manager. Does it<br>
establish a session? Probably Giuseppe Sucameli can help.<br>
<br>
Andreas<br>
<br>
Am 22.10.2013 14:10, schrieb António M. Rodrigues:<br>
<div class="HOEnZb"><div class="h5">> In postgres I can use 'create temporary table...' which will create a new<br>
> object which only exists in the present session. It can only be stored in<br>
> special schemas (which can be accessed from layer--> add postgis layer),<br>
> called pg_tmp_'some integer'.<br>
><br>
> I was just saying it would be nice to be able to browse these objects in<br>
> db_manager. Of course I can do this in the command line with psql.<br>
><br>
> António<br>
><br>
><br>
> 2013/10/22 Andreas Neumann <<a href="mailto:a.neumann@carto.net">a.neumann@carto.net</a>><br>
><br>
>> What do you mean by "temp tables"?<br>
>><br>
>> There are no "temp tables" in a database. Either it is a table, a view<br>
>> or a table. All of these can already be opened with DB manager.<br>
>><br>
>> Andreas<br>
>><br>
>> Am 22.10.2013 13:57, schrieb António M. Rodrigues:<br>
>>> The thing is I have some custom functions which output temp tables. And<br>
>> it<br>
>>> would be useful to be able to explore these tables in db-manager.<br>
>>><br>
>>> I guess it shouldn't be too difficult to tweak dbmanager.<br>
>>> I was looking at the source code for but unfortunately my knowledge of<br>
>>> pyqgis is not quite there (maybe one day... :--) ).<br>
>>><br>
>>> António<br>
>>><br>
>>><br>
>>> 2013/10/22 Andreas Neumann <<a href="mailto:a.neumann@carto.net">a.neumann@carto.net</a>><br>
>>><br>
>>>> Hi,<br>
>>>><br>
>>>> You can load query results in db-manager.<br>
>>>><br>
>>>> Just create a query in db-manager, select the primary key column and the<br>
>>>> geometry column and load it.<br>
>>>><br>
>>>> Works fine for me.<br>
>>>><br>
>>>> Andreas<br>
>>>><br>
>>>> Am 22.10.2013 13:42, schrieb António M. Rodrigues:<br>
>>>>> Hi,<br>
>>>>><br>
>>>>> Is there a way to access temporary tables through db-manager?<br>
>>>>><br>
>>>>> From what I get, this is only possible through layer->add postgis layer<br>
>>>>> (also not available in the browser panel).<br>
>>>>><br>
>>>>> Thanks,<br>
>>>>> António<br>
>>>>><br>
>>>>><br>
>>>>><br>
>>>>> _______________________________________________<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>
>>>> 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>
<br>
</div></div></blockquote></div><br></div>