I would like to run a report that lists all prescriptions written for a time period (last year, for example).
I went to the example queries page. But, the closest example will do report for a specified time period AND for a specific drug. I want to do it for ALL drugs.
Anyone know how to modify this to accomplish my goal?
SET @FromDate='2009-01-01' , @ToDate='2009-12-31';
SELECT PatNum, RxDate, Drug, Disp, Refills, ProvNum FROM rxpat
WHERE drug LIKE ('%Amoxicillin%') AND
RxDate BETWEEN @FromDate AND @ToDate;
Prescription report
-
- Posts: 361
- Joined: Mon Feb 25, 2008 3:09 am
Re: Prescription report
Try this
SET @FromDate='2017-01-01' , @ToDate='2017-12-31';
SELECT PatNum, RxDate, Drug, Disp, Refills, ProvNum
FROM rxpat
WHERE RxDate BETWEEN @FromDate AND @ToDate;
drtmz
SET @FromDate='2017-01-01' , @ToDate='2017-12-31';
SELECT PatNum, RxDate, Drug, Disp, Refills, ProvNum
FROM rxpat
WHERE RxDate BETWEEN @FromDate AND @ToDate;
drtmz
-
- Posts: 28
- Joined: Tue Jun 24, 2014 9:15 pm
Re: Prescription report
That worked! Thanks!