Re: [Dhis2-devs] Global ranges

2009-06-09 Thread Murodullo Latifov
...@ifi.uio.no joha...@ifi.uio.no To: Murodullo Latifov murodlati...@yahoo.com Cc: Knut Staring knu...@gmail.com; dhis2-devs@lists.launchpad.net Sent: Tuesday, June 9, 2009 3:55:37 PM Subject: Re: [Dhis2-devs] Global ranges Hi, Most likely this is pg security restriction. Open PGadmin and navigate

Re: [Dhis2-devs] Global ranges

2009-06-09 Thread Jason Pickering
...@ifi.uio.no joha...@ifi.uio.no To: Murodullo Latifov murodlati...@yahoo.com Cc: Knut Staring knu...@gmail.com; dhis2-devs@lists.launchpad.net Sent: Tuesday, June 9, 2009 3:55:37 PM Subject: Re: [Dhis2-devs] Global ranges Hi, Most likely this is pg security restriction. Open PGadmin

Re: [Dhis2-devs] Global ranges

2009-05-20 Thread Knut Staring
On Wed, May 20, 2009 at 3:57 AM, Ngoc Thanh Nguyen thanh.hispviet...@gmail.com wrote: - if you want all dataelements have ranges insert into minmaxdataelement(sourceid, dataelementid, minvalue, maxvalue) select organisationunitid, dataelementid, 0, 99 from organisationunit, dataelement

Re: [Dhis2-devs] Global ranges

2009-05-20 Thread Knut Staring
Ok, I think I would like to recommend ignoring the file I sent and rather redefine the table and then run Thanh's first SQL, for a total of three statements. They can all be run in one go, just paste the following into the SQL window in PgAdmin III: DROP TABLE minmaxdataelement; CREATE TABLE

[Dhis2-devs] Global ranges

2009-05-19 Thread johansa
Hi, In Sierra Leone, none of the orgunits have defined min-max ranges yet, and the historical data is too poor to be used for calculation of such ranges yet. Still, there have been some instances of really bad typos, such as 775 instead of 75. Most entries (maybe around 98%) are below 100, so as

Re: [Dhis2-devs] Global ranges

2009-05-19 Thread Knut Staring
Hi again, I'm assuming the orgunit and dataelement IDs are the same as in our SL demo (http://208.76.222.114/dhis_sl). This is a big assumption, but anyway your db will suffer no harm if it's not the fully the case. Right click on the following link and save the file, then unzip it somwhere and

Re: [Dhis2-devs] Global ranges

2009-05-19 Thread Jason Pickering
Would like to hear what the devs have to say, but maybe something like... 1) Delete the primary key minmaxdataelementid 2) Execute INSERT INTO minmaxdataelement SELECT a.organisationunitid, b.dataelementid, 0 as minvalue, 99 as maxvalue, 'TRUE'::boolean as generated FROM (SELECT DISTINCT

Re: [Dhis2-devs] Global ranges

2009-05-19 Thread Ngoc Thanh Nguyen
On Wed, May 20, 2009 at 3:13 AM, Jason Pickering jason.p.picker...@gmail.com wrote: Would like to hear what the devs have to say, but maybe something like... 1) Delete the primary key minmaxdataelementid 2) Execute INSERT INTO minmaxdataelement SELECT a.organisationunitid,