[postgis-devel] Typmod Goodness

Kevin Neufeld kneufeld at refractions.net
Fri Aug 7 11:13:06 PDT 2009


Paul Ramsey wrote:
>> And, may I ask why you filtered out pg_temp tables?  Why would you not what
>> to list geography columns on any temporary tables you may have made?
> 
> I'll turn the question back to you, since I created the view by
> copying populate_geometry_columns :)

:) Ah.  populate_geometry_columns repopulates geometry_columns from all geometry columns detected in the database.  The 
pg_temp filter is used here for the main reason that without it, temporary tables from *all* users would be retrieved. 
It's not appropriate (or permissible) to access a temp table in another users' session ... so why even list them in the 
first place, right?  Also, another albeit weak answer is that since it's a static table (not a view) listing a geometry 
column that will disappear in the very near future may not seem like a good thing to do.


With the geography_columns view, you would need the pg_temp filter IF you don't have the additional filter of 
pg_table_is_visible().  But if you're only looking at tables in your search_path (which can't possible include temp 
tables of other users), then you would have the option to list temp tables that are, in fact, available to you.


Anywho, it's just a thought for discussion.  I don't know what the specs say about it.

-- Kevin



More information about the postgis-devel mailing list