Re: [Dhis2-devs] Last hibernate sequence value

2015-01-16 Thread Lars Helge Øverland
Hi Greg, that would be easy to implement, but the idea is that it should never be necessary to expose database details and instead work with the API. Do you think you could elaborate a bit on the use-case? Lars On Fri, Jan 16, 2015 at 8:35 AM, Greg Rowles greg.row...@gmail.com wrote: Hi Devs

Re: [Dhis2-devs] Last hibernate sequence value

2015-01-16 Thread Jason Pickering
Hi Greg, I would tend to agree with Lars that this should really not ever be required, but it would be good to know what the use case actually is. The easiest way to do this would be to create an SQL view in DHIS2 as SELECT currval('hibernate_sequence') In a multi-user database environment,

[Dhis2-devs] [Branch ~dhis2-devs-core/dhis2/trunk] Rev 18016: TableAlteror, set default openingdate on organisationunit

2015-01-16 Thread noreply
revno: 18016 committer: Lars Helge Overland larshe...@gmail.com branch nick: dhis2 timestamp: Fri 2015-01-16 10:15:07 +0100 message: TableAlteror, set default openingdate on organisationunit modified:

Re: [Dhis2-devs] Last hibernate sequence value

2015-01-16 Thread Bob Jolliffe
Jason is right. You should only need the hibernate sequence number if you are dealing with the database through sql. And if you are, then the only safe way to use it is to get the sequence during the execution of the statement. Getting the next sequence number and storing it to some variable

Re: [Dhis2-devs] Last hibernate sequence value

2015-01-16 Thread Greg Rowles
Thanks Bob, Jason Others I agree and understand but we have a DHIS2 implementors who prefer to work directly inside the DBMS who are still new to this complex environment. If they need to insert records directly into tables this gives them the opportunity to do the work they're used to (coming

Re: [Dhis2-devs] Last hibernate sequence value

2015-01-16 Thread Greg Rowles
Let me not forget to mention that this type of work would be preparatory and not after roll out... On Fri, Jan 16, 2015 at 11:20 AM, Greg Rowles greg.row...@gmail.com wrote: Thanks Bob, Jason Others I agree and understand but we have a DHIS2 implementors who prefer to work directly inside

Re: [Dhis2-devs] Last hibernate sequence value

2015-01-16 Thread Knut Staring
I assume you are talking about entering Metadata, correct? Like data elements or orgunits? What is the interface you are proposing to give them? Will you have a form with some kinds of restrictions? Are you thinking to link Postgres into Access via ODBC? Will there be multiple simultaneous

Re: [Dhis2-devs] Last hibernate sequence value

2015-01-16 Thread Knut Staring
Yeah, that was my key question - and I thing it could work ok that way. But I would think you could achieve most of what you want through preparing things in Excel and then using the Metadata import instead (so you don't have to worry about the internal database IDs) On Fri, Jan 16, 2015 at 9:25

[Dhis2-devs] [Branch ~dhis2-devs-core/dhis2/trunk] Rev 18017: various fixes to validator, adds length to Property (for column-length)

2015-01-16 Thread noreply
revno: 18017 committer: Morten Olav Hansen morte...@gmail.com branch nick: dhis2 timestamp: Fri 2015-01-16 16:30:50 +0700 message: various fixes to validator, adds length to Property (for column-length) modified:

Re: [Dhis2-devs] Last hibernate sequence value

2015-01-16 Thread Greg Rowles
Thank you Everyone, that leaves our db managers with 3 options then! On Fri, Jan 16, 2015 at 11:29 AM, Knut Staring knu...@gmail.com wrote: Yeah, that was my key question - and I thing it could work ok that way. But I would think you could achieve most of what you want through preparing

[Dhis2-devs] Organisation Units not showing up correctly on Data Visualizer

2015-01-16 Thread Sandesh Sukumar Doolipeta
Hi , We are on the latest revision : 18015. In the data visualizer , we see that the user can only select the assigned orgunit and its children. For instance , If the user is assigned to a country (Org unit level 3 in our case) then , the user is able to see/select only the

Re: [Dhis2-devs] Organisation Units not showing up correctly on Data Visualizer

2015-01-16 Thread Lars Helge Øverland
Hi, yes this is bug, something which sneak in during a refactor last week. We will fix as soon as possible. regards, Lars On Fri, Jan 16, 2015 at 11:33 AM, Sandesh Sukumar Doolipeta sande...@thoughtworks.com wrote: Hi , We are on the latest revision : 18015. In the data

[Dhis2-devs] [Branch ~dhis2-devs-core/dhis2/trunk] Rev 18018: Dashboard, implemented smarter search within words.

2015-01-16 Thread noreply
revno: 18018 committer: Lars Helge Overland larshe...@gmail.com branch nick: dhis2 timestamp: Fri 2015-01-16 12:13:34 +0100 message: Dashboard, implemented smarter search within words. modified:

Re: [Dhis2-devs] Web-API for receiving SMS

2015-01-16 Thread Morten Olav Hansen
Hi Olav To my knowledge there is no such API. The only controller we have that is SMS related is the configuration controller. On Thu Jan 15 2015 at 5:42:55 PM Olav Poppe olav.po...@me.com wrote: Hi devs, is there an API endpoint that can receive SMSes in XML/Json format? We have a bunch of

Re: [Dhis2-devs] Web-API for receiving SMS

2015-01-16 Thread Bob Jolliffe
Thats what I would have thought. Surely it is the sms gateway which translates the sms message and then just pushes using the standard datavalues api? On 16 January 2015 at 11:23, Morten Olav Hansen morte...@gmail.com wrote: Hi Olav To my knowledge there is no such API. The only controller we

Re: [Dhis2-devs] Last hibernate sequence value

2015-01-16 Thread Calle Hedberg
Hi, You guys are all correct when saying that it's best to use the standard tools and/or the web api - the problem is that DHIS2 processing is rather opaque and/or the interface simply do not allow updating things (try accessing the OrgUnitLevel table if it's empty). Example: the other day I

Re: [Dhis2-devs] Last hibernate sequence value

2015-01-16 Thread Bob Jolliffe
Agree Calle. I too have had to make use of the database directly to deal with some things which are just more difficult or not implemented in the api. So the point is just that if you are making sql insert queries then you should make use of the nextval function as described by Jason above to

Re: [Dhis2-devs] Last hibernate sequence value

2015-01-16 Thread Bob Jolliffe
Truncated example: INSERT INTO organisationunit (organisationunitid, name, other fields ...) values (nextval('hibernate_sequence'), 'Bob's Clinic', ...); Aside: I am not sure why this is not defined as a default value like: create table example ( id int

Re: [Dhis2-devs] Last hibernate sequence value

2015-01-16 Thread Knut Staring
To be frank, it doesn't really matter what you use for I'd as long as it is always smaller than the nextval of the hibernate sequence. But in order to ensure that, it is best practice to use it. On Jan 16, 2015 11:57 AM, Bob Jolliffe bobjolli...@gmail.com wrote: Agree Calle. I too have had to

[Dhis2-devs] [Branch ~dhis2-devs-core/dhis2/trunk] Rev 18019: better interactiveness in validating inputs

2015-01-16 Thread noreply
revno: 18019 committer: Abyot Asalefew Gizaw aby...@gmail.com branch nick: dhis2 timestamp: Fri 2015-01-16 13:24:19 +0100 message: better interactiveness in validating inputs modified:

Re: [Dhis2-devs] Organisation Units not showing up correctly on Data Visualizer

2015-01-16 Thread Jan Henrik Øverland
Hi, this should be fixed in trunk now. Jan On Fri, Jan 16, 2015 at 11:34 AM, Lars Helge Øverland larshe...@gmail.com wrote: Hi, yes this is bug, something which sneak in during a refactor last week. We will fix as soon as possible. regards, Lars On Fri, Jan 16, 2015 at 11:33 AM,

[Dhis2-devs] [Branch ~dhis2-devs-core/dhis2/trunk] Rev 18020: Ext tree store override.

2015-01-16 Thread noreply
Merge authors: Jan Henrik Øverland (janhenrik-overland) revno: 18020 [merge] committer: Jan Henrik Overland janhenrik.overl...@gmail.com branch nick: dhis2 timestamp: Fri 2015-01-16 13:45:58 +0100 message: Ext tree store override.

[Dhis2-devs] [Branch ~dhis2-devs-core/dhis2/trunk] Rev 18021: minor fix

2015-01-16 Thread noreply
revno: 18021 committer: Morten Olav Hansen morte...@gmail.com branch nick: dhis2 timestamp: Fri 2015-01-16 20:01:07 +0700 message: minor fix modified:

[Dhis2-devs] [Branch ~dhis2-devs-core/dhis2/trunk] Rev 18022: minor fix for pager, default to 0 if invalid total

2015-01-16 Thread noreply
revno: 18022 committer: Morten Olav Hansen morte...@gmail.com branch nick: dhis2 timestamp: Fri 2015-01-16 20:02:12 +0700 message: minor fix for pager, default to 0 if invalid total modified:

[Dhis2-devs] [Branch ~dhis2-devs-core/dhis2/trunk] Rev 18024: Include 'View name' field in the 'details' area of SQL View.

2015-01-16 Thread noreply
revno: 18024 committer: Tran Chautran.hispviet...@gmail.com branch nick: dhis2 timestamp: Fri 2015-01-16 20:34:21 +0700 message: Include 'View name' field in the 'details' area of SQL View. modified:

[Dhis2-devs] [Branch ~dhis2-devs-core/dhis2/trunk] Rev 18025: Dashboard, fix for swapping positions for wide items

2015-01-16 Thread noreply
revno: 18025 committer: Lars Helge Overland larshe...@gmail.com branch nick: dhis2 timestamp: Fri 2015-01-16 15:09:38 +0100 message: Dashboard, fix for swapping positions for wide items modified:

[Dhis2-devs] [Branch ~dhis2-devs-core/dhis2/trunk] Rev 18026: Minor

2015-01-16 Thread noreply
revno: 18026 committer: Lars Helge Overland larshe...@gmail.com branch nick: dhis2 timestamp: Fri 2015-01-16 15:45:15 +0100 message: Minor modified:

[Dhis2-devs] [Bug 1371228] Re: For option sets in data entry, provide proper validation messages

2015-01-16 Thread Lars Helge Øverland
** Changed in: dhis2 Assignee: (unassigned) = Morten Olav Hansen (mortenoh) -- You received this bug notification because you are a member of DHIS 2 developers, which is subscribed to DHIS. https://bugs.launchpad.net/bugs/1371228 Title: For option sets in data entry, provide proper

[Dhis2-devs] [Branch ~dhis2-devs-core/dhis2/trunk] Rev 18027: event-capture - event exection date is now part of custom form

2015-01-16 Thread noreply
revno: 18027 committer: Abyot Asalefew Gizaw aby...@gmail.com branch nick: dhis2 timestamp: Fri 2015-01-16 16:40:31 +0100 message: event-capture - event exection date is now part of custom form modified:

[Dhis2-devs] [Branch ~dhis2-devs-core/dhis2/trunk] Rev 18028: App controller. Fixed bug with removal of app in UI. Rendering get response as json only as we on...

2015-01-16 Thread noreply
revno: 18028 committer: Lars Helge Overland larshe...@gmail.com branch nick: dhis2 timestamp: Fri 2015-01-16 17:44:06 +0100 message: App controller. Fixed bug with removal of app in UI. Rendering get response as json only as we only

[Dhis2-devs] [Branch ~dhis2-devs-core/dhis2/trunk] Rev 18029: App controller, fixed bug. Using context path instead of server url as dhis href when installing ...

2015-01-16 Thread noreply
revno: 18029 committer: Lars Helge Overland larshe...@gmail.com branch nick: dhis2 timestamp: Fri 2015-01-16 18:12:53 +0100 message: App controller, fixed bug. Using context path instead of server url as dhis href when installing

[Dhis2-devs] [Branch ~dhis2-devs-core/dhis2/trunk] Rev 18030: App controller, better feedback on installation

2015-01-16 Thread noreply
revno: 18030 committer: Lars Helge Overland larshe...@gmail.com branch nick: dhis2 timestamp: Fri 2015-01-16 18:19:19 +0100 message: App controller, better feedback on installation modified:

[Dhis2-devs] [Branch ~dhis2-devs-core/dhis2/trunk] Rev 18031: Codestyle

2015-01-16 Thread noreply
revno: 18031 committer: Lars Helge Overland larshe...@gmail.com branch nick: dhis2 timestamp: Fri 2015-01-16 18:29:56 +0100 message: Codestyle modified:

[Dhis2-devs] [Branch ~dhis2-devs-core/dhis2/trunk] Rev 18032: Made LocationManagerException unchecked. Added method to LocationManager.

2015-01-16 Thread noreply
revno: 18032 committer: Lars Helge Overland larshe...@gmail.com branch nick: dhis2 timestamp: Fri 2015-01-16 18:56:23 +0100 message: Made LocationManagerException unchecked. Added method to LocationManager. modified:

[Dhis2-devs] [Branch ~dhis2-devs-core/dhis2/trunk] Rev 18033: Missing bean definitions

2015-01-16 Thread noreply
revno: 18033 committer: Lars Helge Overland larshe...@gmail.com branch nick: dhis2 timestamp: Fri 2015-01-16 19:22:29 +0100 message: Missing bean definitions modified:

[Dhis2-devs] [Branch ~dhis2-devs-core/dhis2/trunk] Rev 18034: Apps. Made apps served by default by the web api resource. Added config method on apps resource.

2015-01-16 Thread noreply
revno: 18034 committer: Lars Helge Overland larshe...@gmail.com branch nick: dhis2 timestamp: Fri 2015-01-16 20:07:36 +0100 message: Apps. Made apps served by default by the web api resource. Added config method on apps resource.

[Dhis2-devs] [Branch ~dhis2-devs-core/dhis2/trunk] Rev 18035: Apps, added reset apps cinfig method

2015-01-16 Thread noreply
revno: 18035 committer: Lars Helge Overland larshe...@gmail.com branch nick: dhis2 timestamp: Fri 2015-01-16 20:19:13 +0100 message: Apps, added reset apps cinfig method modified:

[Dhis2-devs] [Branch ~dhis2-devs-core/dhis2/trunk] Rev 18036: Apps module, added restore config function

2015-01-16 Thread noreply
revno: 18036 committer: Lars Helge Overland larshe...@gmail.com branch nick: dhis2 timestamp: Fri 2015-01-16 20:19:53 +0100 message: Apps module, added restore config function modified:

[Dhis2-devs] [Branch ~dhis2-devs-core/dhis2/trunk] Rev 18038: update copyright to 2015

2015-01-16 Thread noreply
revno: 18038 committer: Morten Olav Hansen morte...@gmail.com branch nick: dhis2 timestamp: Sat 2015-01-17 14:43:59 +0700 message: update copyright to 2015 modified:

Re: [Dhis2-devs] Last hibernate sequence value

2015-01-16 Thread Calle Hedberg
Hi, FYI, Lars finally got back to me on those examples I sent him: (a) confirming that using Excel for editing XM does not work; (b) pointing out that the reason for my CSV file not working was incorrect field sequence. Point (b) highlights a fundamental (and frequent) problem with the standard

Re: [Dhis2-devs-core] Paging total being wrong on empty result?

2015-01-16 Thread Bob Jolliffe
Not really (I don't think). That commit was related to pageSize to prevent the while loop immediately below entering into an infinite cycle. The current behaviour of the pager in the xample you give seems semantically correct to me. The pager has returned a page. And only 1 amongst 1. There

Re: [Dhis2-devs-core] Paging total being wrong on empty result?

2015-01-16 Thread Mark Polak
I agree with you Bob except that the “total” represents the number of results in the resultset. Which is 0 in this case and therefore that is incorrect. The page and pageCount are different depending on how you define a “page”. But i agree with your view on that matter. Kind regards, Mark

Re: [Dhis2-devs-core] Paging total being wrong on empty result?

2015-01-16 Thread Bob Jolliffe
I agree with you too Mark. The total should be zero. Morten does this total equate to the pageSize in that page count calculation loop? In which case we shouldn't set it to 1, but just not enter the loop at all. On 16 January 2015 at 12:53, Mark Polak mar...@ifi.uio.no wrote: I agree with

Re: [Dhis2-devs-core] Paging total being wrong on empty result?

2015-01-16 Thread Morten Olav Hansen
Yes, setting it to 0 will have this effect On Fri Jan 16 2015 at 11:31:53 AM Morten Olav Hansen morte...@gmail.com wrote: Hi Mark I think it has been like this since the first time we introduced the pager element.. I agree its a bit weird Total should be 0 of course, do we still want to

Re: [Dhis2-devs-core] Paging total being wrong on empty result?

2015-01-16 Thread Morten Olav Hansen
This should be fixed now On Fri Jan 16 2015 at 7:56:45 PM Bob Jolliffe bobjolli...@gmail.com wrote: I agree with you too Mark. The total should be zero. Morten does this total equate to the pageSize in that page count calculation loop? In which case we shouldn't set it to 1, but just not