Upgrade from 2.24 to 2.25 -> DataElements relationship to existing DataSets Lost

Hi,

We are in the process of testing an upgrade from 2.24 to 2.25. We have followed the upgrade procedures and run the upgrade sql script. We have also noted the change in relationship between DataElements and DataSets in 2.25 with the introduction of DataSetElements as outlined in the release notes.

However, after upgrading, all our DataElements that were previously associated with specific DataSets are no longer related. After the upgrade all our existing DataSets have an empty array of DataSetElements.

Is there something else we need to do here as part of the upgrade to ensure the DataSet / DataElements relationships are retained and transformed properly into DataSet / DataSetElements relationships?

Thanks,

Lorill

···

Lorill Crees
Project Leader / Senior Developer
2Paths Solutions Ltd.

lcrees@2paths.com
skype: lorill2paths

(604) 689-4123 x 15

Hi Lorill,

okay no that is clearly not supposed to happen. Are you able to share privately a database dump from before the 2.25 upgrade?

regards,

Lars

···

On Tue, Nov 22, 2016 at 12:25 AM, Lorill Crees lcrees@2paths.com wrote:

Hi,

We are in the process of testing an upgrade from 2.24 to 2.25. We have followed the upgrade procedures and run the upgrade sql script. We have also noted the change in relationship between DataElements and DataSets in 2.25 with the introduction of DataSetElements as outlined in the release notes.

However, after upgrading, all our DataElements that were previously associated with specific DataSets are no longer related. After the upgrade all our existing DataSets have an empty array of DataSetElements.

Is there something else we need to do here as part of the upgrade to ensure the DataSet / DataElements relationships are retained and transformed properly into DataSet / DataSetElements relationships?

Thanks,

Lorill Crees
Project Leader / Senior Developer
2Paths Solutions Ltd.

lcrees@2paths.com
skype: lorill2paths

(604) 689-4123 x 15

Lorill


Mailing list: https://launchpad.net/~dhis2-devs

Post to : dhis2-devs@lists.launchpad.net

Unsubscribe : https://launchpad.net/~dhis2-devs

More help : https://help.launchpad.net/ListHelp

Lars Helge Øverland

Lead developer, DHIS 2

University of Oslo

Skype: larshelgeoverland

lars@dhis2.org

http://www.dhis2.org

Hi Lars,

Thanks, I will follow up with you privately to share a 2.24 database.

Thanks,

Lorill

···

On Mon, Nov 21, 2016 at 3:37 PM, Lars Helge Øverland lars@dhis2.org wrote:

Hi Lorill,

okay no that is clearly not supposed to happen. Are you able to share privately a database dump from before the 2.25 upgrade?

regards,

Lars

On Tue, Nov 22, 2016 at 12:25 AM, Lorill Crees lcrees@2paths.com wrote:

Hi,

We are in the process of testing an upgrade from 2.24 to 2.25. We have followed the upgrade procedures and run the upgrade sql script. We have also noted the change in relationship between DataElements and DataSets in 2.25 with the introduction of DataSetElements as outlined in the release notes.

However, after upgrading, all our DataElements that were previously associated with specific DataSets are no longer related. After the upgrade all our existing DataSets have an empty array of DataSetElements.

Is there something else we need to do here as part of the upgrade to ensure the DataSet / DataElements relationships are retained and transformed properly into DataSet / DataSetElements relationships?

Thanks,

Lorill Crees
Project Leader / Senior Developer
2Paths Solutions Ltd.

lcrees@2paths.com
skype: lorill2paths

(604) 689-4123 x 15

Lorill


Mailing list: https://launchpad.net/~dhis2-devs

Post to : dhis2-devs@lists.launchpad.net

Unsubscribe : https://launchpad.net/~dhis2-devs

More help : https://help.launchpad.net/ListHelp

Lars Helge Øverland

Lead developer, DHIS 2

University of Oslo

Skype: larshelgeoverland

lars@dhis2.org

http://www.dhis2.org

Lorill Crees
Project Leader / Senior Developer
2Paths Solutions Ltd.

lcrees@2paths.com
skype: lorill2paths

(604) 689-4123 x 15

Hi Lars,

I thought of one more thing to try before sending you a database - I hadn’t dropped our custom SQL views prior to the upgrade. Dropping the views prior to starting up DHIS 2 fixed the issue and we can now see the relationships between DataSets and DataElements via DataSetElements preserved.

By the way there wasn’t any exceptions in the logs when the views were present, the data transformation just silently failed. We just need to be mindful to always drop the SQL views as part of all upgrade processes (which we usually do).

Cheers,

Lorill

···

On Mon, Nov 21, 2016 at 3:43 PM, Lorill Crees lcrees@2paths.com wrote:

Hi Lars,

Thanks, I will follow up with you privately to share a 2.24 database.

Thanks,

Lorill

On Mon, Nov 21, 2016 at 3:37 PM, Lars Helge Øverland lars@dhis2.org wrote:

Hi Lorill,

okay no that is clearly not supposed to happen. Are you able to share privately a database dump from before the 2.25 upgrade?

regards,

Lars


Lorill Crees
Project Leader / Senior Developer
2Paths Solutions Ltd.

lcrees@2paths.com
skype: lorill2paths

(604) 689-4123 x 15

On Tue, Nov 22, 2016 at 12:25 AM, Lorill Crees lcrees@2paths.com wrote:

Hi,

We are in the process of testing an upgrade from 2.24 to 2.25. We have followed the upgrade procedures and run the upgrade sql script. We have also noted the change in relationship between DataElements and DataSets in 2.25 with the introduction of DataSetElements as outlined in the release notes.

However, after upgrading, all our DataElements that were previously associated with specific DataSets are no longer related. After the upgrade all our existing DataSets have an empty array of DataSetElements.

Is there something else we need to do here as part of the upgrade to ensure the DataSet / DataElements relationships are retained and transformed properly into DataSet / DataSetElements relationships?

Thanks,

Lorill Crees
Project Leader / Senior Developer
2Paths Solutions Ltd.

lcrees@2paths.com
skype: lorill2paths

(604) 689-4123 x 15

Lorill


Mailing list: https://launchpad.net/~dhis2-devs

Post to : dhis2-devs@lists.launchpad.net

Unsubscribe : https://launchpad.net/~dhis2-devs

More help : https://help.launchpad.net/ListHelp

Lars Helge Øverland

Lead developer, DHIS 2

University of Oslo

Skype: larshelgeoverland

lars@dhis2.org

http://www.dhis2.org

Lorill Crees
Project Leader / Senior Developer
2Paths Solutions Ltd.

lcrees@2paths.com
skype: lorill2paths

(604) 689-4123 x 15

Thanks Lorill for figuring it out. It’s a good point - we wrap the data set element upgrade in a transaction so it will fail if it cannot drop the old datasetmembers table. The issue with logging is that the built-in upgrade scripts are supposed to fail after the very first run and so it would be noisy to always log errors. I have added a note about the SQL views now in the upgrade notes. Thanks for reporting.

best regards,

Lars

···

On Tue, Nov 22, 2016 at 1:14 AM, Lorill Crees lcrees@2paths.com wrote:

Hi Lars,

I thought of one more thing to try before sending you a database - I hadn’t dropped our custom SQL views prior to the upgrade. Dropping the views prior to starting up DHIS 2 fixed the issue and we can now see the relationships between DataSets and DataElements via DataSetElements preserved.

By the way there wasn’t any exceptions in the logs when the views were present, the data transformation just silently failed. We just need to be mindful to always drop the SQL views as part of all upgrade processes (which we usually do).

Cheers,

Lorill

On Mon, Nov 21, 2016 at 3:43 PM, Lorill Crees lcrees@2paths.com wrote:

Hi Lars,

Thanks, I will follow up with you privately to share a 2.24 database.

Thanks,

Lorill


Lorill Crees
Project Leader / Senior Developer
2Paths Solutions Ltd.

lcrees@2paths.com
skype: lorill2paths

(604) 689-4123 x 15

On Mon, Nov 21, 2016 at 3:37 PM, Lars Helge Øverland lars@dhis2.org wrote:

Hi Lorill,

okay no that is clearly not supposed to happen. Are you able to share privately a database dump from before the 2.25 upgrade?

regards,

Lars


Lorill Crees
Project Leader / Senior Developer
2Paths Solutions Ltd.

lcrees@2paths.com
skype: lorill2paths

(604) 689-4123 x 15

On Tue, Nov 22, 2016 at 12:25 AM, Lorill Crees lcrees@2paths.com wrote:

Hi,

We are in the process of testing an upgrade from 2.24 to 2.25. We have followed the upgrade procedures and run the upgrade sql script. We have also noted the change in relationship between DataElements and DataSets in 2.25 with the introduction of DataSetElements as outlined in the release notes.

However, after upgrading, all our DataElements that were previously associated with specific DataSets are no longer related. After the upgrade all our existing DataSets have an empty array of DataSetElements.

Is there something else we need to do here as part of the upgrade to ensure the DataSet / DataElements relationships are retained and transformed properly into DataSet / DataSetElements relationships?

Thanks,

Lorill Crees
Project Leader / Senior Developer
2Paths Solutions Ltd.

lcrees@2paths.com
skype: lorill2paths

(604) 689-4123 x 15

Lorill


Mailing list: https://launchpad.net/~dhis2-devs

Post to : dhis2-devs@lists.launchpad.net

Unsubscribe : https://launchpad.net/~dhis2-devs

More help : https://help.launchpad.net/ListHelp

Lars Helge Øverland

Lead developer, DHIS 2

University of Oslo

Skype: larshelgeoverland

lars@dhis2.org

http://www.dhis2.org

Lars Helge Øverland

Lead developer, DHIS 2

University of Oslo

Skype: larshelgeoverland

lars@dhis2.org

http://www.dhis2.org