<div dir="ltr"><div><div><div><div><div>You need a way to partition your query into logical pieces .<br></div>In your case I guess you could compute only some part of "public.mapa_base_141213 b" at a time.<br><br>
</div>For instance : <br><br>CREATE TABLE SPLITED AS<br>
SELECT ST_Split(b.the_geom,z.the_<div class="im">geom) AS the_geom<br>
FROM public.mapa_base_141213 b, public.all_lines_merged z<br></div><div class="im">WHERE<b> </b>b.unique_id > M and b.unique_id < N<br><br></div><div class="im">M and N would be for example :<br></div><div class="im">
1 and 100<br></div><div class="im">101 and 200 ...<br></div><br></div>You could dynamically replace the N and M using pgscript (<a href="http://www.pgadmin.org/docs/dev/pgscript.html">http://www.pgadmin.org/docs/dev/pgscript.html</a>),<br>
</div>with a simple loop.<br></div>This way you could print what you are doing, and do it in separate transactions.<br><br>The number would depend on how much time you would like to have for one transaction<br>Cheers,<br>
RĂ©mi-C<br></div>