sp_helptext sp_displayClinicRecordsbyclinicid
alter procedure sp_displayClinicRecordsbyclinicid
(
@id bigint,
@category char(1)
)
as
select id,ClinicName,
CONVERT(varchar(10), cast(Visitdate as datetime),101) Visitdate ,
CONVERT(varchar(19), cast(visitTime as datetime) ,101) visitTime ,
patient_first,patient_last,patient_address,patient_city,patient_state, CONVERT(varchar(10), cast(patient_dob as datetime),101) patient_dob,
precriber,prescriptionnum,CONVERT(varchar(10),cast(pharmacyfilldate as datetime) ,101) pharmacyfilldate,CONVERT(varchar(10),cast(prescriptionenddate as datetime) ,101) prescriptionenddate,drugname,drugformat,npi,dea,
licence,clinicid,Category,PatientFullname,Prescriber_first,Prescriber_last,Qty,Days
from tblClinicRecords where clinicid=@id and Category=@category