changeDatasourcePlugin plugin release 2.0
The plugin has received several main improvements and minor changes:
Changelog:
- Data sources browsing
- Bad Layers Handling
- Expression driven data sources replace
Data source browsing
New data source selection can now be performed by a Qgis browser widget between those currently available. Clicking on browse button in the contextual windows or in in the datasources tables now appears Qgis browser instance where can be specified the new datasource to apply.
Bad Layers Handling
This feature has been developed thanks to Baswein suggestions who contributed with a precious and accurate plugin testing during development.
The plugin can handle bad layers replacing the standard bad layer manager with the datasources table. The new feature has been developed thanks to The standard bad layer manager allows to fix only at the opening of the project.
If not reconciled at the opening of the project, bad layers and their related settings (for example symbologies, labels, joins …) are definitively lost. Furthermore datasources browsing is allowed only for file datasources (OGR and GDAL). For other datasources the only way is to manually modify connection string.
The new feature allows to specify bad layers with missing datasources later, during qgis project session, specifying them with the same plugin methods.
The bad layers handling have to be activated checking “Handle bad layers” checkbox located at the bottom of the main plugin dialog, and restarting QGis.
Once activated the improved Bad Layers Handling, if missing datasources are detected the following dialog appears after loading the project.
The dialog notifies that the bad layers are now handled by changeDatasource plugin.
The bad layers awaiting to be reconciled are keeped with all their properties and settings under the “unhandled layers” group located at the bottom of legend tree.
Bad layers are reconciled specifying a new valid and compatible datasource with the contextual dialog or by the datasources table. Unhandled layers are marked with light brown background
If successfully reconciled the layers are moved from the “unhandled layers” group to their original legend position, preserving in this way the right project draw order.
Expression driven data sources table replacing
The datasource table dialog allows a new method for massive change of layers datasources using expressions. The well known widget can be used to rewrite the datasources using layers properties (filename, data type, provider, geometry type ….) as fields:
Do you plan to port it to QGIS 3?
Yes, but I have not yet planned the migration. Sincerely, I would not waste my time with a QGIS3 release and then find the feature in QGIS3 core but now we should be in freeze phase and apparently nobody feels the need…
not sure why this capability would not have been added to QGIS3 core, it is a great plugin and without it I’m not sure how one would change datasources of multiple layers at the same time. Similarly, do you have any plans to port PickLayer over to QGI3 – another one of my favorites!
picklayer plugin is much more simple to port. I was thinking to some improvements
that’s great news, thanks!
so painful to use QGIS 3 without change datasource and picklayer plugins. I guess that’s what happens when you become used to the functions made available with those plugins and use them everyday. Have you been able to make any progress on porting them to Q3?
thanks Enrico for posting Q3 update to PickLayer last week – you seriously made my day!!
thanks Rob. You are very kind.