Link between Tables

Hello,

I am trying to explore the structure of the database administrator entant that perfect mastery of queries that the GUI does not allow dhis2, I wanted to know the table that connects organisationunit table and organitlevel table?

···


Riddy NDOMA
Software Developer
Skype: riddyndoma, G+: riddyndoma, FB: riddy ndoma

Twitter: riddyndoma, LinkedIn: riddy ndoma
Blog: http://riddyndoma.blogspot.com/

Vous servir est mon désire (Serving you is my desire)

One place to start is the generated table (resource table) called _orgunitstructure

Knut

···

On Thu, Nov 14, 2013 at 2:43 PM, riddy ndoma riddyndoma@gmail.com wrote:

Hello,

I am trying to explore the structure of the database administrator entant that perfect mastery of queries that the GUI does not allow dhis2, I wanted to know the table that connects organisationunit table and organitlevel table?

Riddy NDOMA
Software Developer
Skype: riddyndoma, G+: riddyndoma, FB: riddy ndoma

Twitter: riddyndoma, LinkedIn: riddy ndoma
Blog: http://riddyndoma.blogspot.com/


Vous servir est mon désire (Serving you is my desire)


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


Knut Staring

Dept. of Informatics, University of Oslo

+4791880522

http://dhis2.org

It is managed from the resource table _orgunitstructure. Since according to the diagram you gave me the orgunitlevel table is connected only with the Map table

···

2013/11/14 Knut Staring knutst@gmail.com

One place to start is the generated table (resource table) called _orgunitstructure

Knut


Riddy NDOMA
Software Developer
Skype: riddyndoma, G+: riddyndoma, FB: riddy ndoma

Twitter: riddyndoma, LinkedIn: riddy ndoma
Blog: http://riddyndoma.blogspot.com/

Vous servir est mon désire (Serving you is my desire)

On Thu, Nov 14, 2013 at 2:43 PM, riddy ndoma riddyndoma@gmail.com wrote:

Hello,

I am trying to explore the structure of the database administrator entant that perfect mastery of queries that the GUI does not allow dhis2, I wanted to know the table that connects organisationunit table and organitlevel table?

Riddy NDOMA
Software Developer
Skype: riddyndoma, G+: riddyndoma, FB: riddy ndoma

Twitter: riddyndoma, LinkedIn: riddy ndoma
Blog: http://riddyndoma.blogspot.com/


Vous servir est mon désire (Serving you is my desire)


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

Knut Staring

Dept. of Informatics, University of Oslo

+4791880522

http://dhis2.org

Hi Riddy,

Actually there is no link between org unit level and orgunit tables. Moreover level of org unit is not persisted, that means each time the level of orgunit is computed when needed. I think this is unnecessary computation while level org units is stable for the long time or all over. Now I see _orgunitstructure provides some sort of persistence to level orgunit structure.

regards,

murod

···

On Thu, Nov 14, 2013 at 6:53 PM, riddy ndoma riddyndoma@gmail.com wrote:

It is managed from the resource table _orgunitstructure. Since according to the diagram you gave me the orgunitlevel table is connected only with the Map table


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

2013/11/14 Knut Staring knutst@gmail.com

One place to start is the generated table (resource table) called _orgunitstructure

Knut


Riddy NDOMA
Software Developer
Skype: riddyndoma, G+: riddyndoma, FB: riddy ndoma

Twitter: riddyndoma, LinkedIn: riddy ndoma
Blog: http://riddyndoma.blogspot.com/

Vous servir est mon désire (Serving you is my desire)

On Thu, Nov 14, 2013 at 2:43 PM, riddy ndoma riddyndoma@gmail.com wrote:

Hello,

I am trying to explore the structure of the database administrator entant that perfect mastery of queries that the GUI does not allow dhis2, I wanted to know the table that connects organisationunit table and organitlevel table?

Riddy NDOMA
Software Developer
Skype: riddyndoma, G+: riddyndoma, FB: riddy ndoma

Twitter: riddyndoma, LinkedIn: riddy ndoma
Blog: http://riddyndoma.blogspot.com/


Vous servir est mon désire (Serving you is my desire)


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

Knut Staring

Dept. of Informatics, University of Oslo

+4791880522

http://dhis2.org

Hi Riddy,

The resource tables are not part of the schema or data model as such, but generated by the system (from data administration) to make it easier for db people to make select queries for reports etc. One example is the hierarchical listing of orgunits in the _orgunitstructure table. This table is updated by the nightly scheduling job, if that is enabled, or manually from Data Administration. So that table might be out of sync with the orgunit table, if you do not make sure it is re-generated.

The levels/hierarchy of orgunits are managed through the parent reference in the organisationunit table.

The orgunitlevel table is just to store labels for each level, e.g. used in the level selector in GIS.

Ola

···

2013/11/14 Knut Staring knutst@gmail.com

One place to start is the generated table (resource table) called _orgunitstructure

Knut


Riddy NDOMA
Software Developer
Skype: riddyndoma, G+: riddyndoma, FB: riddy ndoma

Twitter: riddyndoma, LinkedIn: riddy ndoma
Blog: http://riddyndoma.blogspot.com/

Vous servir est mon désire (Serving you is my desire)

On Thu, Nov 14, 2013 at 2:43 PM, riddy ndoma riddyndoma@gmail.com wrote:

Hello,

I am trying to explore the structure of the database administrator entant that perfect mastery of queries that the GUI does not allow dhis2, I wanted to know the table that connects organisationunit table and organitlevel table?

Riddy NDOMA
Software Developer
Skype: riddyndoma, G+: riddyndoma, FB: riddy ndoma

Twitter: riddyndoma, LinkedIn: riddy ndoma
Blog: http://riddyndoma.blogspot.com/


Vous servir est mon désire (Serving you is my desire)


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

Knut Staring

Dept. of Informatics, University of Oslo

+4791880522

http://dhis2.org

Thank you to the team for your support,

Hi @Ola, then how to ensure that the resources automatically generate tables? as you have said that there is possibility of activated!

···

2013/11/14 Ola Hodne Titlestad olati@ifi.uio.no

Hi Riddy,

The resource tables are not part of the schema or data model as such, but generated by the system (from data administration) to make it easier for db people to make select queries for reports etc. One example is the hierarchical listing of orgunits in the _orgunitstructure table. This table is updated by the nightly scheduling job, if that is enabled, or manually from Data Administration. So that table might be out of sync with the orgunit table, if you do not make sure it is re-generated.

The levels/hierarchy of orgunits are managed through the parent reference in the organisationunit table.

The orgunitlevel table is just to store labels for each level, e.g. used in the level selector in GIS.

Ola


On 14 Nov 2013 14:54, “riddy ndoma” riddyndoma@gmail.com wrote:

It is managed from the resource table _orgunitstructure. Since according to the diagram you gave me the orgunitlevel table is connected only with the Map table


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


Riddy NDOMA
Software Developer
Skype: riddyndoma, G+: riddyndoma, FB: riddy ndoma

Twitter: riddyndoma, LinkedIn: riddy ndoma
Blog: http://riddyndoma.blogspot.com/

Vous servir est mon désire (Serving you is my desire)

2013/11/14 Knut Staring knutst@gmail.com

One place to start is the generated table (resource table) called _orgunitstructure

Knut


Riddy NDOMA
Software Developer
Skype: riddyndoma, G+: riddyndoma, FB: riddy ndoma

Twitter: riddyndoma, LinkedIn: riddy ndoma
Blog: http://riddyndoma.blogspot.com/

Vous servir est mon désire (Serving you is my desire)

On Thu, Nov 14, 2013 at 2:43 PM, riddy ndoma riddyndoma@gmail.com wrote:

Hello,

I am trying to explore the structure of the database administrator entant that perfect mastery of queries that the GUI does not allow dhis2, I wanted to know the table that connects organisationunit table and organitlevel table?

Riddy NDOMA
Software Developer
Skype: riddyndoma, G+: riddyndoma, FB: riddy ndoma

Twitter: riddyndoma, LinkedIn: riddy ndoma
Blog: http://riddyndoma.blogspot.com/


Vous servir est mon désire (Serving you is my desire)


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

Knut Staring

Dept. of Informatics, University of Oslo

+4791880522

http://dhis2.org

Thank you to the team for your support,

Hi @Ola, then how to ensure that the resources automatically generate tables? as you have said that there is possibility to activate it!

···

2013/11/14 riddy ndoma riddyndoma@gmail.com

Thank you to the team for your support,

Hi @Ola, then how to ensure that the resources automatically generate tables? as you have said that there is possibility of activated!


Riddy NDOMA
Software Developer
Skype: riddyndoma, G+: riddyndoma, FB: riddy ndoma

Twitter: riddyndoma, LinkedIn: riddy ndoma
Blog: http://riddyndoma.blogspot.com/

Vous servir est mon désire (Serving you is my desire)

2013/11/14 Ola Hodne Titlestad olati@ifi.uio.no

Hi Riddy,

The resource tables are not part of the schema or data model as such, but generated by the system (from data administration) to make it easier for db people to make select queries for reports etc. One example is the hierarchical listing of orgunits in the _orgunitstructure table. This table is updated by the nightly scheduling job, if that is enabled, or manually from Data Administration. So that table might be out of sync with the orgunit table, if you do not make sure it is re-generated.

The levels/hierarchy of orgunits are managed through the parent reference in the organisationunit table.

The orgunitlevel table is just to store labels for each level, e.g. used in the level selector in GIS.

Ola


On 14 Nov 2013 14:54, “riddy ndoma” riddyndoma@gmail.com wrote:

It is managed from the resource table _orgunitstructure. Since according to the diagram you gave me the orgunitlevel table is connected only with the Map table


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


Riddy NDOMA
Software Developer
Skype: riddyndoma, G+: riddyndoma, FB: riddy ndoma

Twitter: riddyndoma, LinkedIn: riddy ndoma
Blog: http://riddyndoma.blogspot.com/

Vous servir est mon désire (Serving you is my desire)

2013/11/14 Knut Staring knutst@gmail.com

One place to start is the generated table (resource table) called _orgunitstructure

Knut


Riddy NDOMA
Software Developer
Skype: riddyndoma, G+: riddyndoma, FB: riddy ndoma

Twitter: riddyndoma, LinkedIn: riddy ndoma
Blog: http://riddyndoma.blogspot.com/

Vous servir est mon désire (Serving you is my desire)

On Thu, Nov 14, 2013 at 2:43 PM, riddy ndoma riddyndoma@gmail.com wrote:

Hello,

I am trying to explore the structure of the database administrator entant that perfect mastery of queries that the GUI does not allow dhis2, I wanted to know the table that connects organisationunit table and organitlevel table?

Riddy NDOMA
Software Developer
Skype: riddyndoma, G+: riddyndoma, FB: riddy ndoma

Twitter: riddyndoma, LinkedIn: riddy ndoma
Blog: http://riddyndoma.blogspot.com/


Vous servir est mon désire (Serving you is my desire)


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

Knut Staring

Dept. of Informatics, University of Oslo

+4791880522

http://dhis2.org

Hi Ola,

Doesn’t it mean that using parent/child hierarchy one has to compute the level, which is already known and is not subject for change during the long run? Computing level from parent/child hierarchy is costly and should be avoided. And what is wrong with storing just a column of level ids in orgunit table for easy reference? Taking into account the fact that DHIS2 is data warehousing tool at large and data redundancy and denormalized tables are the rule.

regards,

murod

···

On Thu, Nov 14, 2013 at 7:07 PM, Ola Hodne Titlestad olati@ifi.uio.no wrote:

Hi Riddy,

The resource tables are not part of the schema or data model as such, but generated by the system (from data administration) to make it easier for db people to make select queries for reports etc. One example is the hierarchical listing of orgunits in the _orgunitstructure table. This table is updated by the nightly scheduling job, if that is enabled, or manually from Data Administration. So that table might be out of sync with the orgunit table, if you do not make sure it is re-generated.

The levels/hierarchy of orgunits are managed through the parent reference in the organisationunit table.

The orgunitlevel table is just to store labels for each level, e.g. used in the level selector in GIS.

Ola


On 14 Nov 2013 14:54, “riddy ndoma” riddyndoma@gmail.com wrote:

It is managed from the resource table _orgunitstructure. Since according to the diagram you gave me the orgunitlevel table is connected only with the Map table


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


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

2013/11/14 Knut Staring knutst@gmail.com

One place to start is the generated table (resource table) called _orgunitstructure

Knut


Riddy NDOMA
Software Developer
Skype: riddyndoma, G+: riddyndoma, FB: riddy ndoma

Twitter: riddyndoma, LinkedIn: riddy ndoma
Blog: http://riddyndoma.blogspot.com/

Vous servir est mon désire (Serving you is my desire)

On Thu, Nov 14, 2013 at 2:43 PM, riddy ndoma riddyndoma@gmail.com wrote:

Hello,

I am trying to explore the structure of the database administrator entant that perfect mastery of queries that the GUI does not allow dhis2, I wanted to know the table that connects organisationunit table and organitlevel table?

Riddy NDOMA
Software Developer
Skype: riddyndoma, G+: riddyndoma, FB: riddy ndoma

Twitter: riddyndoma, LinkedIn: riddy ndoma
Blog: http://riddyndoma.blogspot.com/


Vous servir est mon désire (Serving you is my desire)


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

Knut Staring

Dept. of Informatics, University of Oslo

+4791880522

http://dhis2.org

Hi Riddy,

Have a look in Data Administration->Scheduling. There is an option for Resource Tables there.

The scheduled tasks take place at midnight every day.

You can read more about Scheduling in the manual.

Ola

···

Ola Hodne Titlestad (Mr)
HISP
Department of Informatics

University of Oslo

Mobile: +47 48069736
Home address: Eftasåsen 68, 0687 Oslo, Norway. Googlemaps link

On 14 November 2013 15:28, riddy ndoma riddyndoma@gmail.com wrote:

Thank you to the team for your support,

Hi @Ola, then how to ensure that the resources automatically generate tables? as you have said that there is possibility to activate it!

2013/11/14 riddy ndoma riddyndoma@gmail.com

Thank you to the team for your support,

Hi @Ola, then how to ensure that the resources automatically generate tables? as you have said that there is possibility of activated!


Riddy NDOMA
Software Developer
Skype: riddyndoma, G+: riddyndoma, FB: riddy ndoma

Twitter: riddyndoma, LinkedIn: riddy ndoma
Blog: http://riddyndoma.blogspot.com/

Vous servir est mon désire (Serving you is my desire)

2013/11/14 Ola Hodne Titlestad olati@ifi.uio.no

Hi Riddy,

The resource tables are not part of the schema or data model as such, but generated by the system (from data administration) to make it easier for db people to make select queries for reports etc. One example is the hierarchical listing of orgunits in the _orgunitstructure table. This table is updated by the nightly scheduling job, if that is enabled, or manually from Data Administration. So that table might be out of sync with the orgunit table, if you do not make sure it is re-generated.

The levels/hierarchy of orgunits are managed through the parent reference in the organisationunit table.

The orgunitlevel table is just to store labels for each level, e.g. used in the level selector in GIS.

Ola


On 14 Nov 2013 14:54, “riddy ndoma” riddyndoma@gmail.com wrote:

It is managed from the resource table _orgunitstructure. Since according to the diagram you gave me the orgunitlevel table is connected only with the Map table


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


Riddy NDOMA
Software Developer
Skype: riddyndoma, G+: riddyndoma, FB: riddy ndoma

Twitter: riddyndoma, LinkedIn: riddy ndoma
Blog: http://riddyndoma.blogspot.com/

Vous servir est mon désire (Serving you is my desire)

2013/11/14 Knut Staring knutst@gmail.com

One place to start is the generated table (resource table) called _orgunitstructure

Knut


Riddy NDOMA
Software Developer
Skype: riddyndoma, G+: riddyndoma, FB: riddy ndoma

Twitter: riddyndoma, LinkedIn: riddy ndoma
Blog: http://riddyndoma.blogspot.com/

Vous servir est mon désire (Serving you is my desire)

On Thu, Nov 14, 2013 at 2:43 PM, riddy ndoma riddyndoma@gmail.com wrote:

Hello,

I am trying to explore the structure of the database administrator entant that perfect mastery of queries that the GUI does not allow dhis2, I wanted to know the table that connects organisationunit table and organitlevel table?

Riddy NDOMA
Software Developer
Skype: riddyndoma, G+: riddyndoma, FB: riddy ndoma

Twitter: riddyndoma, LinkedIn: riddy ndoma
Blog: http://riddyndoma.blogspot.com/


Vous servir est mon désire (Serving you is my desire)


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

Knut Staring

Dept. of Informatics, University of Oslo

+4791880522

http://dhis2.org

Hi @Hola,
Thank you for this track solution. The bottom line is that I know where to start, I’ll dig more!

···

2013/11/15 Ola Hodne Titlestad olati@ifi.uio.no

Hi Riddy,

Have a look in Data Administration->Scheduling. There is an option for Resource Tables there.

The scheduled tasks take place at midnight every day.

You can read more about Scheduling in the manual.

Ola



Riddy NDOMA
Software Developer
Skype: riddyndoma, G+: riddyndoma, FB: riddy ndoma

Twitter: riddyndoma, LinkedIn: riddy ndoma
Blog: http://riddyndoma.blogspot.com/

Vous servir est mon désire (Serving you is my desire)


Ola Hodne Titlestad (Mr)
HISP
Department of Informatics

University of Oslo

Mobile: +47 48069736
Home address: Eftasåsen 68, 0687 Oslo, Norway. Googlemaps link

On 14 November 2013 15:28, riddy ndoma riddyndoma@gmail.com wrote:

Thank you to the team for your support,

Hi @Ola, then how to ensure that the resources automatically generate tables? as you have said that there is possibility to activate it!

2013/11/14 riddy ndoma riddyndoma@gmail.com

Thank you to the team for your support,

Hi @Ola, then how to ensure that the resources automatically generate tables? as you have said that there is possibility of activated!


Riddy NDOMA
Software Developer
Skype: riddyndoma, G+: riddyndoma, FB: riddy ndoma

Twitter: riddyndoma, LinkedIn: riddy ndoma
Blog: http://riddyndoma.blogspot.com/

Vous servir est mon désire (Serving you is my desire)

2013/11/14 Ola Hodne Titlestad olati@ifi.uio.no

Hi Riddy,

The resource tables are not part of the schema or data model as such, but generated by the system (from data administration) to make it easier for db people to make select queries for reports etc. One example is the hierarchical listing of orgunits in the _orgunitstructure table. This table is updated by the nightly scheduling job, if that is enabled, or manually from Data Administration. So that table might be out of sync with the orgunit table, if you do not make sure it is re-generated.

The levels/hierarchy of orgunits are managed through the parent reference in the organisationunit table.

The orgunitlevel table is just to store labels for each level, e.g. used in the level selector in GIS.

Ola


On 14 Nov 2013 14:54, “riddy ndoma” riddyndoma@gmail.com wrote:

It is managed from the resource table _orgunitstructure. Since according to the diagram you gave me the orgunitlevel table is connected only with the Map table


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


Riddy NDOMA
Software Developer
Skype: riddyndoma, G+: riddyndoma, FB: riddy ndoma

Twitter: riddyndoma, LinkedIn: riddy ndoma
Blog: http://riddyndoma.blogspot.com/

Vous servir est mon désire (Serving you is my desire)

2013/11/14 Knut Staring knutst@gmail.com

One place to start is the generated table (resource table) called _orgunitstructure

Knut


Riddy NDOMA
Software Developer
Skype: riddyndoma, G+: riddyndoma, FB: riddy ndoma

Twitter: riddyndoma, LinkedIn: riddy ndoma
Blog: http://riddyndoma.blogspot.com/

Vous servir est mon désire (Serving you is my desire)

On Thu, Nov 14, 2013 at 2:43 PM, riddy ndoma riddyndoma@gmail.com wrote:

Hello,

I am trying to explore the structure of the database administrator entant that perfect mastery of queries that the GUI does not allow dhis2, I wanted to know the table that connects organisationunit table and organitlevel table?

Riddy NDOMA
Software Developer
Skype: riddyndoma, G+: riddyndoma, FB: riddy ndoma

Twitter: riddyndoma, LinkedIn: riddy ndoma
Blog: http://riddyndoma.blogspot.com/


Vous servir est mon désire (Serving you is my desire)


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

Knut Staring

Dept. of Informatics, University of Oslo

+4791880522

http://dhis2.org