dm d data model - bennettoxford/openprescribing GitHub Wiki
We have written a blog on what is the NHS dm+d which is useful introductory reading.
Further useful reading: https://archive.psnc.org.uk/pages/dmd.html
The dmd
app has the following models:
DMDProduct
- each row is either a VMP or an AMP
- databaset table:
dmd_product
- key fields:
dmdid
: the primary keyvpid
: identifier of VMP; matchesdmdid
ifconcept_class
is1
concept_class
:1
if product is VMP;2
if AMPbnf_code
: BNF code of product -- note that a BNF code may be used for multiple VMPsname
DMDVmpp
- each row is a combination of virtual product and pack size
- database table:
dmd_vmpp
- key fields:
vppid
: the primary keyvpid
: reference todmd_vmp.vpid
(note that we don't have aDMDVmp
model, but the database table exists)nm
: the name plus pack size (eg "Paracetamol 500mg effervescent tablets sugar free 24 tablet")
NCSOConcession
- database table:
dmd_ncsoconcession
- key fields:
id
: the primary keyvmpp
/vmpp_id
: thevppid
of the correspondingDMDVmpp
object- this is set by reconciling the
drug
andpack_size
againstDMDVmpp.nm
- this is set by reconciling the
drug
: name of the drug according to the NCSO websitepack_size
: size of packdate
: date of concession
- database table: