<div dir="ltr">Dear all,<br>
<br>
I have set up a form in QGIS 2.6 using the attribute editor layout
'autogenerate', to edit an editable view in a postgres database. This
works nicely. I would like to use this form to edit data in other
databases that have an identical structure. Ideally, I would set up a
project file with all properties set where I could choose to load layers
either from one or another database (with identical structures), and
when I edit a layer the correct form opens.<br>
<br>
If I save it as a .qml file (from project1 connected to database1), then
load it in project2 (connected to database2 with identical tables
loaded) through properties>fields>load style it appears to load it
(the edit widgets get changed to the same as in project1), but when I
click a value relation widget the layer, key column and value column
fields are empty. When I open the attribute table all fields that have a
value relation that refers to a lookup table that contains different
values than the original lookup table will show their values between
brackets (at least, those values that do not appear in the original
table). <br>
<br>
It looks as if the .qml retains a link to the original database and
lookup tables (and not just to layer names as they are loaded in the
project). Is there a way to configure a form based on a table structure
that can be re-used for other tables with the same structure?<br>
<br>
Thanks,<br>
<br>
Janneke</div>