If there's a solution within the list group, we'd be GREATLY
appreciative as well.
Thanks.
Robin A. Poirier
Sr. Applications Analyst
Howard County General Hospital
rpoi...@hcgh.org
PH: 410-720-8736
FX: 410-740-7565
-----Original Message-----
From: meditech-...@mtusers.com
[mailto:meditech-...@mtusers.com] On Behalf Of
ISD...@stjosephs.org
Sent: Friday, August 01, 2008 9:49 AM
To: medit...@mtusers.com
Subject: [MEDITECH-L] NPR:Need help with elapsed time of computed fields
Good Morning,
We are Magic 5.62, I have a report written in ADM.PAT adm.pat.events.
The
report shows the time the patient was registered in the ER to the time
the
patient was transferred to the Inpatient floor. I'm trying to create an
elapsed time field but it's not working. This is what I've done. I
have 4
computed fields on a detail line as follows:
xx.regd
DAT=FREE
LEN=8
VAL=IF{@event.code="ENREGER" @event.date}
xx.regt
DAT=FREE
LEN=4
VAL=IF{@event.code="ENREGER" @event.time}
xx.trand
DATE=FREE
LEN=8
VAL=IF{@event.code="TFRADMIN" @event.date}
xx.trant
DAT=FREE
LEN=4
VAL=IF{@event.code="TFRADMIN" @event.time}
All the above returns the proper date and time. I then created the
following time elapsed field:
xx.elapsed.time
DAT=FREE
LEN=15
VAL=%Z.elapsed.time(@xx.trand,@xx.trant,@xx.regd,@xx.regt,"hh Hrs mm
Mins")
Can you not use computed fields in elapsed time fields or can anyone
tell me
what I'm doing wrong.
Thank You,
Laura Wasielewski
St Josephs Hospital
Elmira, Ny
====================================
Keep up to date on recent announcements about MUSE by visiting the
meditech-l web site at MTUsers.net and go to the tab labeled "MUSE -
Dallas 05/08"
If you want to ask a question from the meditech-l users who will be
attending MUSE or share something about MUSE with each other, you can
post messages on the web site on the tab "MUSE - Dallas 05/08"
====================================
Keep up to date on recent announcements about MUSE by visiting the meditech-l web site at MTUsers.net and go to the tab labeled "MUSE - Dallas 05/08"
If you want to ask a question from the meditech-l users who will be attending MUSE or share something about MUSE with each other, you can post messages on the web site on the tab "MUSE - Dallas 05/08"
I haven't tried this, but this should work. . .
xx.regd
DAT=FREE
LEN=8
VAL=""^/REGD,IF{@event.code="ENREGER" @event.date^/REGD}
xx.regt
DAT=FREE
LEN=4
VAL=""^/REGT,IF{@event.code="ENREGER" @event.time^/REGT}
xx.trand
DATE=FREE
LEN=8
VAL=""^/TRAND,IF{@event.code="TFRADMIN" @event.date^/TRAND}
xx.trant
DAT=FREE
LEN=4
VAL=""^/TRANT,IF{@event.code="TFRADMIN" @event.time^/TRANT}
xx.elapsed.time
DAT=FREE
LEN=15
VAL=%Z.elapsed.time(/TRAND,/TRANT,/REGD,/REGT,"hh Hrs mm Mins")
John-Mark Freve
Application Analyst
Rush Oak Park Hospital
Oak Park, IL
708.660.5002
"Poirier, Robin" <rpoi...@hcgh.org>
Sent by: meditech-...@mtusers.com
08/01/2008 03:10 PM
To
<ISD...@stjosephs.org>, <medit...@mtusers.com>
cc
Subject
Re: [MEDITECH-L] NPR:Need help with elapsed time of computed fields
Donald F. Stewart
Sr. Programmer Analyst
(706)647-8111 x1696
dfst...@urmc.org
Upson Regional Medical Center
801 W. Gordon St.
Thomaston, GA 30286
====================================
====================================
====================================
--
This message has been scanned by the Vigilar Atlas for spam and viruses,
and is believed to be safe and clean.
--
This message has been scanned by the Vigilar Atlas for spam and viruses, and is believed to be safe and clean.
%Z.elapsed.time(@xx.trand,@xx.trant,@xx.regd,@xx.regt,"hh Hrs mm Mins")
then there's no way Magic will be able to run Z.elapsed.time.
That being said, Z.elapsed.time is picky about it's arguments. Dates need
to be YYYYMMDD and times need to be HHMM. I ran into a situation before
where whatever I was doing would drop the a leading zero for the hour so
0315 became just 315. Z.elapsed.time returns nil if it gets that kind of
input.
John-Mark Freve
Application Analyst
Rush Oak Park Hospital
Oak Park, IL
708.660.5002
"Stewart, Donald" <dfst...@urmc.org>
Sent by: meditech-...@mtusers.com
08/04/2008 07:49 AM
To
<JohnMar...@rsh.net>, "Poirier, Robin" <rpoi...@hcgh.org>
cc
xx.los1
DAT=FREE
FONT=b
JFY=L
LEN=14
VAL=IF{@status$3="DIS"
%Z.elapsed.time(@discharge.date,@discharge.time,@admit.d
VAL=ate,@admit.time,"hh Hrs mm Mins")}
xx.los2
DAT=FREE
FONT=b
JFY=L
LEN=14
VAL=IF{@status$3'="DIS"
%Z.elapsed.time(@.today,@.now,@event.eff.date,@event.ef
VAL=f.time,"hh Hrs mm Mins")}
----------------------------------------------------------
I have also used the field numbers for the 4 elements for the
elapsed.time calculation, like this:
VAL=%Z.elapsed.time(/V[13],/V[14],/V[3],/V[4],"hh.mm")
----------------------------------------------------------
Good Luck,
Your Z.elapsed.time should run then, given that you are correctly
referencing your computed fields.
Another way may be to reference your computed fields via their field
identifiers. In C/S, this would be /R.V[n] where n corresponds to the field
number. I think in MAGIC it is /R[n] (don't quote me on that, it's been a
while).
So your elapsed time ends up being something along the lines of
VAL=%Z.elapsed.time(/R.V[15],/R.V[16],/R.V[13],/R.V[14],"hh.hh")
(or whatever format you end up with)
Mitch