[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Gnumed-devel] Love the phrasewheel in Add substance
From: |
Karsten Hilbert |
Subject: |
Re: [Gnumed-devel] Love the phrasewheel in Add substance |
Date: |
Thu, 6 Jan 2011 18:28:34 +0100 |
User-agent: |
Mutt/1.5.20 (2009-06-14) |
On Thu, Jan 06, 2011 at 08:30:14AM -0800, Jim Busser wrote:
> What I noticed (hopefully intended)
yes
> is that -- when searching in "component" (see screenshot)
>
> the string finds matches across the combination of component string AND
> brand string
That is a function of the queries the match provider runs:
SELECT DISTINCT ON (component)
pk_component,
(substance || ' ' || amount || unit || ' ' ||
preparation || ' (' || brand || ')')
AS component
FROM ref.v_drug_components
WHERE
substance %(fragment_condition)s
OR
brand %(fragment_condition)s
ORDER BY component
LIMIT 50
> the wheel becomes active at 3 characters only for *word beginnings*
>
> but at 4 characters will also match middle/end strings in words
Yes, that is how it's configured:
mp.setThresholds(2, 3, 4)
And that's one of the original ideas of Richard. Note, that
already with 2 characters it would/should match at the
beginning of a phrase (in the above query: "substance" or
"brand").
> In the example below:
>
> "omp." matches on the fragment in (MetoPharm comp.)
>
> "omp" would find nothing
>
> "met" would find each of "metoprolol" and "MetoPharm"
"me" really should already match.
> "tab" would find nothing (presumably filter is on the names, not the
> forms)
That's right.
> PS the window on Mac does not open adequately (opens 15%
> too narrow) & must be manually resized. Dunno whether wx
> allows to say "open windows to auto-zoomed width 'as suits
> KDE' PLUS 15%"?
Unfortunately, there isn't, really.
Karsten
--
GPG key ID E4071346 @ wwwkeys.pgp.net
E167 67FD A291 2BEA 73BD 4537 78B9 A9F9 E407 1346