Re: [Dhis2-devs] Issues with "number of days in a week fix"

2014-09-15 Thread Lars Helge Øverland
Great. On Tue, Sep 16, 2014 at 7:46 AM, Mansi Singhal wrote: > Hello, > > Thanks Lars for your suggestions. Our branch doesn't had that method. I > have taken those changes and it just works fine. > > Actually, commit no: 16720 >

Re: [Dhis2-devs] Issues with "number of days in a week fix"

2014-09-15 Thread Mansi Singhal
Hello, Thanks Lars for your suggestions. Our branch doesn't had that method. I have taken those changes and it just works fine. Actually, commit no: 16720 doesn't contain that change. Period class might have changed in some

[Dhis2-devs] [Branch ~dhis2-devs-core/dhis2/trunk] Rev 16729: minor npe check

2014-09-15 Thread noreply
revno: 16729 committer: Morten Olav Hansen branch nick: dhis2 timestamp: Tue 2014-09-16 12:20:02 +0700 message: minor npe check modified: dhis-2/dhis-support/dhis-support-hibernate/src/main/java/org/hisp/dhis/hibernate/HibernateGene

[Dhis2-devs] [Branch ~dhis2-devs-core/dhis2/trunk] Rev 16728: removed ALL/F_METADATA_IMPORT (and EXPORT) restriction on /api/metadata, security is handled by A...

2014-09-15 Thread noreply
revno: 16728 committer: Morten Olav Hansen branch nick: dhis2 timestamp: Tue 2014-09-16 12:18:47 +0700 message: removed ALL/F_METADATA_IMPORT (and EXPORT) restriction on /api/metadata, security is handled by AclService modified: dh

Re: [Dhis2-devs] periodstructure giving errors...

2014-09-15 Thread Jason Pickering
Did you clear your server cache and or restart DHIS2? On Tue, Sep 16, 2014 at 5:50 AM, Moemedi Ntunyane < moemedi.ntuny...@hotmail.com> wrote: > I have eliminated all duplicates but this error still persist. > > Process failed: PreparedStatementCallback; SQL [insert into > _periodstructure values

Re: [Dhis2-devs] periodstructure giving errors...

2014-09-15 Thread Moemedi Ntunyane
I have eliminated all duplicates but this error still persist. Process failed: PreparedStatementCallback; SQL [insert into _periodstructure values (?,?,?,?,?,?,?,?,?,?,?,?,?)]; ERROR: null value in column "iso" violates not-null constraint; nested exception is org.postgresql.util.PSQLException:

[Dhis2-devs] [Branch ~dhis2-devs-core/dhis2/trunk] Rev 16727: PT DV GIS ER EV, 403 error handling.

2014-09-15 Thread noreply
Merge authors: Jan Henrik Øverland (janhenrik-overland) revno: 16727 [merge] committer: Jan Henrik Overland branch nick: dhis2 timestamp: Mon 2014-09-15 17:15:39 -0700 message: PT DV GIS ER EV, 403 error handling. modified: dhis-2

[Dhis2-devs] [Branch ~dhis2-devs-core/dhis2/trunk] Rev 16726: Included font awesome in data entry / cache manifest so it can be used in custom forms

2014-09-15 Thread noreply
revno: 16726 committer: Lars Helge Overland branch nick: dhis2 timestamp: Tue 2014-09-16 01:04:48 +0200 message: Included font awesome in data entry / cache manifest so it can be used in custom forms modified: dhis-2/dhis-services/

[Dhis2-devs] [Branch ~dhis2-devs-core/dhis2/trunk] Rev 16725: Removed sortOrder property of data element, indicator, data set. Not used for anything.

2014-09-15 Thread noreply
revno: 16725 committer: Lars Helge Overland branch nick: dhis2 timestamp: Mon 2014-09-15 22:06:58 +0200 message: Removed sortOrder property of data element, indicator, data set. Not used for anything. removed: dhis-2/dhis-api/src/m

[Dhis2-devs] [Bug 1369619] [NEW] Visualizer, "show values" not working when hiding series

2014-09-15 Thread Lars Helge Øverland
Public bug reported: In data visualizer, the "show values" function for displaying numbers next to bars does not work properly when you click to hide the series (under chart title). The values seem to be placed incorrectly in the chart / the values of the hidden bars are not hidden themselves, and

[Dhis2-devs] [Bug 1369609] [NEW] Analysis, data dimension not available on edit favorite

2014-09-15 Thread Lars Helge Øverland
Public bug reported: In pivot table (and dv) the data dimension does not become available when editing an existing favorite where the data dimension was not part of the pivot. Steps to reproduce: - Create a pivot favorite without the data dimension, and save. - Load the favorite. - Select some da

[Dhis2-devs] [Branch ~dhis2-devs-core/dhis2/trunk] Rev 16724: Code style

2014-09-15 Thread noreply
revno: 16724 committer: Lars Helge Overland branch nick: dhis2 timestamp: Mon 2014-09-15 16:37:25 +0200 message: Code style modified: dhis-2/dhis-support/dhis-support-hibernate/src/main/java/org/hisp/dhis/hibernate/HibernateGenericS

Re: [Dhis2-devs] Issues with "number of days in a week fix"

2014-09-15 Thread Lars Helge Øverland
Hi again, I have set up an example locally with a few indicators called "x number of cases per day" where numerator is no of cases and denominator is [days] for a week. See attached. It works correctly. - Could it be a build issue? - Can you please check in your branch on Period.java, method get

Re: [Dhis2-devs] periodstructure giving errors...

2014-09-15 Thread Moemedi Ntunyane
Hi Lars, I have not done that. Im only capturing statistical data. Regards, Moemedi Ntunyane Co-founder KeyInConsulting Date: Mon, 15 Sep 2014 16:10:13 +0200 Subject: Re: [Dhis2-devs] periodstructure giving errors... From: larshe...@gmail.com To: jason.p.picker...@gmail.com CC: moemedi.ntuny..

Re: [Dhis2-devs] periodstructure giving errors...

2014-09-15 Thread Jason Pickering
Yeah, so you need to get rid of all references is all tables to those bogus periods, I think. We had a lot of these issues when upgrading to 2.16, because of legacy data import from DHIS 1.4, which seemed to have gone amiss at somepoint, but it never seemed to matter up until now. Of course, looki

Re: [Dhis2-devs] periodstructure giving errors...

2014-09-15 Thread Moemedi Ntunyane
Thanks, will eliminate all of them. So far the query returned 5 records. But other records are referenced by foreign keys like: chart_periods;reporttable_periods;completedatasetregistration Moemedi Ntunyane Co-founder KeyInConsulting Date: Mon, 15 Sep 2014 16:01:08 +0200 Subject: Re: [Dhis2-dev

Re: [Dhis2-devs] periodstructure giving errors...

2014-09-15 Thread busoye
Following from Lars' question, or import data from another system? Regards, Busoye On 2014-09-15 16:10, Lars Helge Øverland wrote: > Hi Moemedi, > > may I ask, did you ever run the "aggregation queries" (producing aggregate > values from event data) on your database? > > regards, >

Re: [Dhis2-devs] periodstructure giving errors...

2014-09-15 Thread Lars Helge Øverland
Hi Moemedi, may I ask, did you ever run the "aggregation queries" (producing aggregate values from event data) on your database? regards, Lars On Mon, Sep 15, 2014 at 4:01 PM, Jason Pickering < jason.p.picker...@gmail.com> wrote: > I suspect you have more invalid periods then. You should foll

Re: [Dhis2-devs] periodstructure giving errors...

2014-09-15 Thread Jason Pickering
I suspect you have more invalid periods then. You should follow the same procedure for other period types, i.e. checking to be sure that all months are one month, all weeks are one week, etc. You may want to try something like SELECT startdate, periodtypeid,COUNT(*) from period GROUP BY startdat

Re: [Dhis2-devs] periodstructure giving errors...

2014-09-15 Thread Moemedi Ntunyane
Hi Jason Thnx, I had successfully elimated duplicate records the error still pesistit complaining of ISO column: is this column a date column?? Process failed: PreparedStatementCallback; SQL [insert into _periodstructure values (?,?,?,?,?,?,?,?,?,?,?,?,?)]; ERROR: null value in column "iso"

Re: [Dhis2-devs] Issues with "number of days in a week fix"

2014-09-15 Thread Mansi Singhal
Hey Lars, I checked it again clearing cache. Issue still remains the same. Can you please check it once again on your side. On Mon, Sep 15, 2014 at 5:35 PM, Lars Helge Øverland wrote: > Hi Mansi, > > that's strange. Actually in rev 16720 the important change is that > analytics uses Period.getD

Re: [Dhis2-devs] Issues with "number of days in a week fix"

2014-09-15 Thread Lars Helge Øverland
Hi Mansi, that's strange. Actually in rev 16720 the important change is that analytics uses Period.getDaysInPeriod(), which adds one day to the result (since period end date is inclusive). See line 331 in DefaultAnalyticsService. Are you sure its not a cache issue? Let me double check on my side.

Re: [Dhis2-devs] periodstructure giving errors...

2014-09-15 Thread Jason Pickering
So, the period 1589;6;"2010-02-01";"2010-02-28 , points to a yearly period type, which is not a year in duration. You are going to need to get rid of it. You will need to do something like SELECT COUNT(*) FROM datavalue where periodid = 1589; If you have any records with this periodID, you are go

Re: [Dhis2-devs] periodstructure giving errors...

2014-09-15 Thread Moemedi Ntunyane
Hi Jason Thanx, I just run the query you gave and no records were available and removed not = year(!=year) and records where available. The date format is available as: 1573;6;"2010-01-01";"2010-01-31" 1589;6;"2010-02-01";"2010-02-28" The error available shows that there is key violation for nu

[Dhis2-devs] Issues with "number of days in a week fix"

2014-09-15 Thread Mansi Singhal
Hey Lars , I have taken revision number 16720 from trunk in our branch. What i observed is Number of days in a week are still taken as 6. DateUtilsTest class also assumes number of days as 6. We were assuming number of days in a week as 7. Is it a bug or Do I need to take changes from some other

Re: [Dhis2-devs] periodstructure giving errors...

2014-09-15 Thread Jason Pickering
Very likely you have an invalid period in the periods table. Can you run this and see what happens? SELECT * FROM period where age(enddate,startdate) != '1 year'::interval and periodtypeid = (SELECT periodtypeid from periodtype where name = 'Yearly'); Also, you should get an error which will hel