<div dir="ltr"><div class="gmail_extra"><div class="gmail_quote"><br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div bgcolor="#ffffff" text="#3366ff">
I have double checked my code 'layer_id' is coming straight from
calling $dbh->primary_key( undef, undef, 'layer');<br></div></blockquote><div><br></div><div>Your table doesn't even have a layer_id column. Try this query to be sure: <span style="font-family:monospace,monospace">SELECT layer_id FROM layer;</span>. It should error out saying that the column doesn't exist. It definitely doesn't have any columns that use PostGIS data types, so I see no reason why PostGIS would affect anything related to this table. If you're looking at different copies of your database, make <i>extra</i> sure that they're really identical.<br><br>Aside from that, I'd dig up some documentation of that function and look it over; I wasn't able to find any after a few minutes of searching on Google. PostGIS still seems like an extremely unlikely source for the problem.<br></div></div></div></div>