<div dir="ltr"><div><div><div><div><div><div><div><div><div><div>Hi all,<br><br></div>I have just released the plugin Dynamic Layers which let you<br><br></div>* configure a "dynamic datasource" for any layer with variables. You can use a syntax like {$myvar} <br></div>* Configure a table of variable values to use as replacements<br></div>* Use a vector layer as a source for this variables ( fields name must correspond to variable names<br></div><div>* Define a layer as "extent layer" on which to zoom to full extent when aplying variables<br></div><div><br></div><div>Then you can apply the variables on the configured layers to see the changes in you project, and save the project if you want.<br><br></div><div>Use cases :<br></div><div>* You have some PostGIS layers with subqueries such as <br></div><div>table=(SELECT * FROM mytable WHERE country = 'France')<br><br></div><div>and you have data for the whole world. You can use the plugin to configure a datasource such as<br>table=(SELECT * FROM mytable WHERE country = '{$COUNTRY}')<br><br></div><div>And then set the variable COUNTRY to 'Spain' or wichever country.<br><br></div><div>You can also change the path to shapefiles, such as <br></div><div>"/my/folder/mydata_{$COUNTRY}.shp"<br></div><div><br></div>A video is sometimes better than a description : <a href="https://vimeo.com/141541813">https://vimeo.com/141541813</a><br><br></div>Source code here:<br><a href="https://vimeo.com/141541813">https://vimeo.com/141541813</a><br><br></div>Documentation in progress...<br><br><br></div>Any feedback welcome <br><br></div>Regards<br></div>MichaĆ«l<br></div>