← Back to team overview

dhis2-devs team mailing list archive

Re: Tracked Entity Instances Query - SQL syntax error

 

Thank you Morten.

On Wed, Aug 17, 2016 at 7:10 PM, Morten Olav Hansen <morten@xxxxxxxxx>
wrote:

> Seems like a bug yes, I will look into it
>
> --
> Morten Olav Hansen
> Senior Engineer, DHIS 2
> University of Oslo
> http://www.dhis2.org
>
> On Mon, Aug 15, 2016 at 10:34 AM, chathura widanage <
> chathurawidanage@xxxxxxxxx> wrote:
>
>> Hi all,
>>
>> I am using below API call to query all the TEIs which are accessible by
>> the current user.
>>
>> /api/trackedEntityInstances/query.json?ouMode=ACCESSIBLE&att
>> ribute=izuwkaOUgFg&attribute=C8DBAo2wEYN&attribute=BZEpuufLyDE&attribute=
>> WqdldQpOIxm
>>
>> In our setup,  we have 5 orgUnitLevels and above query works fine for
>> superuser who has just one orgUnit assigned which is of level 1.
>>
>> There are other users who has multiple level 4 and 5 orgUnits assigned.
>> Above API call fails for those users giving a 500 error code. Basically
>> this doesn't work for any user who has multiple orgUnits.
>>
>> The cause for the issue seems to be a SQL syntax error.
>>
>> Please find the link to the stack trace below.
>>
>> https://dl.dropboxusercontent.com/u/81780569/stack.txt
>>
>> The issue was visible in DHIS2 v2.23 and v2.24.
>>
>> Have I done something wrong in the above API call or is this a bug in the
>> DHIS2. Is there any walk around for this issue?
>>
>> Thanks
>> --
>> Best Regards,
>>
>> *Chathura Widanage,*
>> Undergraduate,
>> Department of Computer Science and Engineering,
>> University of Moratuwa,
>> Sri Lanka
>>
>> <https://www.linkedin.com/profile/public-profile-settings?trk=prof-edit-edit-public_profile>
>>   <http://facebook.com/chathura.widanage>
>> <https://plus.google.com/u/0/109418781686423002025>
>> <https://github.com/chathurawidanage>
>>
>> _______________________________________________
>> Mailing list: https://launchpad.net/~dhis2-devs
>> Post to     : dhis2-devs@xxxxxxxxxxxxxxxxxxx
>> Unsubscribe : https://launchpad.net/~dhis2-devs
>> More help   : https://help.launchpad.net/ListHelp
>>
>>
>
> _______________________________________________
> Mailing list: https://launchpad.net/~dhis2-devs
> Post to     : dhis2-devs@xxxxxxxxxxxxxxxxxxx
> Unsubscribe : https://launchpad.net/~dhis2-devs
> More help   : https://help.launchpad.net/ListHelp
>
>


-- 
Regards,
Pamod Amarakoon

Confidentiality Notice: the information contained in this email and any
attachments may be legally privileged and confidential. If you are not an
intended recipient, you are hereby notified that any dissemination,
distribution, or copying of this e-mail is strictly prohibited. If you have
received this e-mail in error, please notify the sender and permanently
delete the e-mail and any attachments immediately. You should not retain,
copy or use this e-mail or any attachments for any purpose, nor disclose
all or any part of the contents to any other person.

Follow ups

References