gnumed-devel
[Top][All Lists]
Advanced

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

Re: [Gnumed-devel] reviewed status tables/views


From: Karsten Hilbert
Subject: Re: [Gnumed-devel] reviewed status tables/views
Date: Wed, 26 Oct 2005 17:38:40 +0200
User-agent: Mutt/1.5.9i

On Wed, Oct 26, 2005 at 09:23:57AM +1000, Ian Haywood wrote:

> > -- ---------------------------------------------
> > create table reviewed_status (
> >     pk serial primary key,
> >     table_oid oid
> >             not null,
> This is an interesting idea, however to write an Inbox widget sanely we
> need to have a defined list of which tables are reviewable.
Which does not preclude the above. We simply add a check
constraint or even enumeration table. Or a trigger that
checks on pg_class (can't use foreign keys on system tables,
unfortunately).

> (presumably lab_result and doc_obj, in the first instance)
Yes.

> and then a view using SELECT ...UNION SELECT to provide a single view of 
> unreviewed objects.
Absolutely.

> >     fk_reviewed_pk integer
> >             not null,
> >     fk_reviewer integer
> >             not null
> >             references public.xlnk_identity(xfk_identity),
> >     is_technically_abnormal boolean
> >             not null,
> >     clinically_relevant boolean
> >             not null,
> > ) inherits (audit_fields);
> I was looking for a timestamp field, but I realise we inherit modified_when 
> here.
yes

> Most importantly, we need to find clinical items 'destined' for a particular 
> individual,
yes

> but not actually seen yet, a third flag
>       seen boolean,
We don't need it. At first I thought we do. However: No row
in reviewed_status == not reviewed.

Notice how this is not the provider inbox saying "Mrs Smith
has lab results to be reviewed" ...

>       comment text,
added

Karsten
-- 
GPG key ID E4071346 @ wwwkeys.pgp.net
E167 67FD A291 2BEA 73BD  4537 78B9 A9F9 E407 1346




reply via email to

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