[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Gnumed-bugs] a query problem when bootstrapping bundle [v18-v19-dyn

From: Busser, Jim
Subject: Re: [Gnumed-bugs] a query problem when bootstrapping bundle [v18-v19-dynamic]
Date: Sun, 17 Nov 2013 20:53:38 +0000

On 2013-11-17, at 11:47 AM, "Busser, Jim" <address@hidden>  wrote:

… I ran into a problem that relates to preparation for specifying a praxis branch.

Log attached.

Might it have anything to do with the fact that I had imported, into my v18 org structure, 12,000 physician offices?

-- Jim

On closer examination I had misjudged the purpose of the problem query from the log which was

insert into dem.org_unit (fk_org, description)
(select pk from where = c_hs.narrative),
'unit of ' || c_hs.narrative
clin.hospital_stay c_hs
not exists (
select 1 from dem.org_unit
dem.org_unit.description = 'unit of ' || c_hs.narrative
fk_org = (select pk from where = c_hs.narrative)

which on my v18 yields

 ?column? |                 ?column?                 
          | unit of Enterprise Healthcare Unit
          | unit of VGH
          | unit of Vancouver General - Med Day Care
          | unit of Vancouver General - Med Day Care
          | unit of Vancouver General Hospital
          | unit of Vanc
(6 rows)

I now suspect this query was trying to ensure that every org which was not yet characterized by one or more units becomes, at minimum, a unit of itself but  If that is the case, why is it constrained to organizations which had been referenced from hospital stays, and why is it populating the org unit description from

'unit of ' || c_hs.narrative

when clin.hospital_stay.narrative is 'a comment on the hospital stay' ?

It would seem to me that the description of an org unit as a 'unit of' something should be acquired from

'unit of ' ||


-- Jim

reply via email to

[Prev in Thread] Current Thread [Next in Thread]