After a couple of simple test (i generated a Form Definition with 2 version) there is something i do not understand:
* In orbeon.orbeon_form_data there are two entries (one per each version) --> OK
* BUT form_version has "1" in both cases.
* In orbeon_form_definition there are two entries (one per each version) --> OK
* In this case form_version is "1" for one register and "2" for the other --> OK
Why in orbeon_form_data the value is "1" for both forms ?
Which is the logic of this behavior ?
You're correct about `orbeon_form_definition`: if you have multiple versions, they will be stored, and those version will be kept track of in that table. What you see in `orbeon_form_data` are the forms accessible from Form Builder. There, we don't keep track of versioning. The downside is that is if you create a form, publish it as version 1, do some changes, and publish version 2, you'll have those 2 versions published, but in Form Builder only the "latest" version will be available. This means that you can't easily make changes to version 1 and republish it. Implementing issue 750 would be a way to resolve this.
Note that this isn't really a "new" problem with versioning. That is, if in Form Builder you create a form, publish it, then do and save changes to the form, you don't have an easy way to go back to the published version. Here too, implementing 750 would solve it.
Does this help?
Follow Orbeon on Twitter: @orbeon
Follow me on Twitter: @avernet
Correct: in Form Builder, you can publish a form "as version 1". But what if the version you currently have in Form Builder is version 2, and you'd like to make a change to the "source" of version 1, and republish it as version 1?
Or maybe, independently of versioning, you deleted the form from Form Builder, and would like to retrieve a published version, so you can make a change to it.