← Back to team overview

dhis2-devs team mailing list archive

Re: Unable to get Filtered Charts on Data Visualizer

 

On Fri, Nov 7, 2014 at 1:07 PM, Mansi Singhal <msinghal@xxxxxxxxxxxxxxxx>
wrote:

>
> Hello Lars,
>
> We were trying to filter charts based on Org Unit Group Set filters on
> Data Visualizer. But we are not able to get them. Instead we are getting
> error saying "No values found".
>
> What we did is:
>
> We have organization unit named Afghanistan. We have a Group Set named Type
> of Population . This group set has Organization Unit Groups named Internally
> Displaced People, Most-at-risk Population, Refugee, General Population.
>
> Afghanistan has been associated to General Population as shown in
> *snapshot1.*
> General Population has been associated to Type of Population as shown in
> *snapshot2.*
> Type of Population has Data Dimension set to true as shown in *snapshot3.*
>
> We entered data for Afghanistan and ran Analytics Export.
>
> 1) We tried checking charts on Data Visualizer selecting the required
> indicator and Afghanistan as organization unit filter.
>
> Sql Query that got executed was:
> select "de","monthly","co", sum(value) as value from analytics_2014 where
> "de" in ('a0ea1b1d113', 'a2d257cc8ce') and "monthly" in ('201401',
> '201402', '201403', '201404', '201405', '201406', '201407', '201408',
> '201409', '201410') and ( "uidlevel3" in ('a420aa7ff4d') ) group by
> "de","monthly","co"
>
> We were able to see the expected charts.
>
> 2) We tried checking charts on Data Visualizer selecting the same
> indicator, same organization unit filter(Afghanistan) and an additional Org
> Unit Group Set Filter(selecting General Population from Type of Population).
>
> Sql Query that got executed was:
>
> select "de","monthly","co", sum(value) as value from analytics_2014 where
> "de" in ('aee83d48c4c', 'afa26d34ddd') and "monthly" in ('201401',
> '201402', '201403', '201404', '201405', '201406', '201407', '201408',
> '201409', '201410') and ( "uidlevel3" in ('a420aa7ff4d') ) and (
> "a8a579d5fab" in ('afbdf5ffe08') ) group by "de","monthly","co"
>
> We are not getting charts. It says *No values found*.
>
> We tried checking the data into Analytics tables, But we observed that
> there is no data at all in the filter column.
> Query we ran is: select * from analytics_2014 where a8a579d5fab is not
> null;
> We didn't get any data.
>
> Do you see any reason why data is not getting populated in these columns
> even after we ran analytics export. Analytics export has been executed
> after all the associations and data value entries has been done.
>
> Can you help us figuring out the reason for the issue?
>
>
>
Hi Mansi & Megan,

sorry for the late reply, yes back in Norway now.

As far as I can see there is no data at all for Afghanistan or any of its
sub-units on either uat or www. This query returns 0:

--
select count(*) from datavalue dv
where dv.sourceid in(
  select organisationunitid from _orgunitstructure where
uidlevel3='a420aa7ff4d');
--

Please double-check this on your side.

A general note is that you must put the org units where data is collected
in the org unit groups. As an example, if data is collected at the hospital
level (e.g. Kabul hospital) then the hospital must be part of the group if
you want to do analysis according to group sets - it is not enough to
include a higher-level org unit like the country. I guess you knew this
already.

regards,

Lars

References