<html><body><div style="font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif; font-size: 14px;">Hello,</div><div style="font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif; font-size: 14px;"><div class="ws-ng-mail-style--178eJwLTs0rAQADzwGb-e29d18d66af341deb3883e276bf8093b"><div style="font-family:'Helvetica Neue', Helvetica, Arial, sans-serif;font-size:14px;"><br></div><div style="font-family:'Helvetica Neue', Helvetica, Arial, sans-serif;font-size:14px;">I've
 seen that geometry_columns, geography_columns, raster_columns and 
raster_overviews only display layers for which the role can at least 
SELECT on the table.</div><div style="font-family:'Helvetica Neue', Helvetica, Arial, sans-serif;font-size:14px;">But sometimes privileges are specific and only a subset of columns are defined as ''SELECTable''.</div><div style="font-family:'Helvetica Neue', Helvetica, Arial, sans-serif;font-size:14px;">These views doesn't reference the geom column if its privileges are column defined like this :</div><div style="font-family:'Helvetica Neue', Helvetica, Arial, sans-serif;font-size:14px;"><code>GRANT SELECT(geom) ON schema.my_table TO my_user;</code></div><div style="font-family:'Helvetica Neue', Helvetica, Arial, sans-serif;font-size:14px;"><br></div><div style="font-family:'Helvetica Neue', Helvetica, Arial, sans-serif;font-size:14px;">We need to use <code>has_column_privilege()</code> instead of <code>has_table_privilege()</code> in the where clause of these views.</div><div style="font-family:'Helvetica Neue', Helvetica, Arial, sans-serif;font-size:14px;">The
 first function succeeds either if the privilege is held for the whole 
table, or if there is a column-level grant of the privilege for the 
column.</div><div style="font-family:'Helvetica Neue', Helvetica, Arial, sans-serif;font-size:14px;"><br></div><div style="font-family:'Helvetica Neue', Helvetica, Arial, sans-serif;font-size:14px;"><div>I've made a fork of the PostGIS project to test this update and it works great.</div><div>I've created a branch and commited the modifications to make a PR : <a data-ik-opengraph-image="" data-ik-opengraph-title="Making sure you're not a bot!" data-ik-opengraph-status="anchor" href="https://gitea.osgeo.org/arthurbazin/postgis/commit/d75464c991d25dc1f602a9e641ce40a8bfaaaea0" rel="noopener noreferrer" data-ik="ik-secure">https://gitea.osgeo.org/arthurbazin/postgis/commit/d75464c991d25dc1f602a9e641ce40a8bfaaaea0</a></div></div><div style="font-family:'Helvetica Neue', Helvetica, Arial, sans-serif;font-size:14px;"><div style="font-family:'Helvetica Neue', Helvetica, Arial, sans-serif;font-size:14px;"><br></div><div style="font-family:'Helvetica Neue', Helvetica, Arial, sans-serif;font-size:14px;">Before submitting it, I would like to have your opinion on this improvement.</div></div><div style="font-family:'Helvetica Neue', Helvetica, Arial, sans-serif;font-size:14px;"><br></div><div style="font-family:'Helvetica Neue', Helvetica, Arial, sans-serif;font-size:14px;">Note
 that I didn't create any ticket on track to avoid the auto resolution 
by the new AI bot (if my informations are good) and start my first PR on
 this project (easy one but we need to start somewhere)</div><div style="font-family:'Helvetica Neue', Helvetica, Arial, sans-serif;font-size:14px;"><br></div><div data-ik-opengraph-ignore=""><div>Best regards !</div><div><br></div><div><div><b>///</b> <span style="color:#0088FF;"><b>Arthur Bazin</b></span> <b>___</b></div><div><span class="size" style="font-size:12px"><span style="color:rgb(0, 136, 255);">⟁ </span><span style="color:#666;">France</span></span></div></div></div></div></div><div style="font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif; font-size: 14px;"><br></div></body></html>