Quantcast

MySql and Persistence Layer

classic Classic list List threaded Threaded
4 messages Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

MySql and Persistence Layer

bruno.buzzi
Hi,

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 ?

regards
bruno
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: MySql and Persistence Layer

Alessandro  Vernet
Administrator
Hi Bruno,

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.

https://github.com/orbeon/orbeon-forms/issues/750

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?

Alex
--
Follow Orbeon on Twitter: @orbeon
Follow me on Twitter: @avernet
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: MySql and Persistence Layer

bruno.buzzi
Alex

"This means that you can't easily make changes to version 1 and republish it."

But in the FormBuilder you have a ComboBox to republish old versions (this is easy !)...

I think i'm missing something ...

regards
bruno
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: MySql and Persistence Layer

Alessandro  Vernet
Administrator
Bruno,

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.

Or maybe, the published form was pushed from an other environment with the Form Runner home page [remote server operations](https://doc.orbeon.com/form-runner/feature/home-page.html#remote-server-operations) , and you don't have access to that environment anymore.

Those are all cases that would call for the implementation of [RFE 750](https://github.com/orbeon/orbeon-forms/issues/750) .

Alex
--
Follow Orbeon on Twitter: @orbeon
Follow me on Twitter: @avernet
Loading...