Below are the database queries which are used to create this measure. These are run against a copy of the BSA prescribing data which we store in Google BigQuery. We're working on making our BigQuery tables publicly available at which point it will be possible to run and modify these queries yourself. But even where code and database queries are not directly useable by others we believe it is always preferable to make them public.
Description | Percentage SGLT-2 inhibitors items not prescribed as generic dapagliflozin tablets |
---|---|
Why it matters | Dapagliflozin is a sodium-glucose co-transporter 2 (SGLT-2) inhibitor commonly prescribed in type 2 diabetes, the treatment of chronic heart failure, and chronic kidney disease. Dapagliflozin lost its patent in August 2025. From September 2025 the NHS tariff price is likely to fall, as it will be based on the generic price, rather than the branded product. NICE guidance on the treatment of diabetes states that if 2 drugs in the same class are appropriate, choose the option with the lowest acquisition cost. Dapagliflozin is likely to have cost-saving opportunities when compared with other SGLT-2s.
Please note: OpenPrescribing.net measures have a consistent way of visualising measures, where 'lower is better' and therefore in this case we show the proportion of SGLT-2 inhibitors which are NOT prescribed as generic dapagliflozin tablets. |
Tags | Diabetes, Standard, Cost Saving |
Implies cost savings | No |
Authored by | richard.croker |
Checked by | andrew.brown |
Last reviewed | 18/08/2025 |
Next review due | 18/08/2027 |
History | View change history on GitHub → |
SELECT
CAST(month AS DATE) AS month,
practice AS practice_id,
SUM(p.items) AS numerator
FROM hscic.normalised_prescribing p INNER JOIN dmd.vmp vmp ON CONCAT(SUBSTR(p.bnf_code,0,9),'AA', SUBSTR(p.bnf_code,-2), SUBSTR(p.bnf_code,-2)) = vmp.bnf_code -- joins prescribing data to vmp table using generic BNF code
INNER JOIN dmd.vpi AS vpi ON vmp.id = vpi.vmp -- joins vmp to vpi table to get ingredient strengths (strnt_nmrtr_val)
INNER JOIN dmd.ont AS ont ON vmp.id = ont.vmp -- joins vmp to ont table to get formulation codes
INNER JOIN dmd.ontformroute AS route ON ont.form = route.cd -- joins ont table to ontform table to get formulation names
WHERE (vpi.ing = 783086004 AND NOT(LEFT(p.bnf_code,11) ='0601023AGAA' AND route.descr ='tablet.oral')) --Dapagliflozin propanediol monohydrate (except generic tablets for non-combination)
OR vpi.ing = 725664009 --Canagliflozin hemihydrate
OR vpi.ing = 703894008 --Empagliflozin
OR vpi.ing = 1162393006 --Ertugliflozin L-pyroglutamic acid
GROUP BY month, practice_id
SELECT
CAST(month AS DATE) AS month,
practice AS practice_id,
SUM(p.items) AS denominator
FROM hscic.normalised_prescribing p INNER JOIN dmd.vmp vmp ON CONCAT(SUBSTR(p.bnf_code,0,9),'AA', SUBSTR(p.bnf_code,-2), SUBSTR(p.bnf_code,-2)) = vmp.bnf_code -- joins prescribing data to vmp table using generic BNF code
INNER JOIN dmd.vpi AS vpi ON vmp.id = vpi.vmp -- joins vmp to vpi table to get ingredient strengths (strnt_nmrtr_val)
WHERE vpi.ing IN (725664009,783086004,703894008,1162393006) --Canagliflozin hemihydrate, Dapagliflozin propanediol monohydrate, Empagliflozin, Ertugliflozin L-pyroglutamic acid
GROUP BY month, practice_id