how many times was prescribed magnesium sulfate to patient 45304?
select count(*) from prescriptions where prescriptions.hadm_id in ( select admissions.hadm_id from admissions where admissions.subject_id = 45304 ) and prescriptions.drug = 'magnesium sulfate'