Total admissions ICU/Med: Difference between revisions

From CCMDB Wiki
Jump to navigation Jump to search
TOstryzniuk (talk | contribs)
mNo edit summary
Line 31: Line 31:
== SQL ==
== SQL ==
To generate a per-unit count in Access paste the following:  
To generate a per-unit count in Access paste the following:  
<pre>
SELECT s_Locations.Location, s_Locations.Active, Count(L_Log.D_ID) AS CountOfD_ID, Min(L_Log.R_AdmDate) AS MinOfR_AdmDate, Max(L_Log.R_DisDate) AS MaxOfR_DisDate
SELECT s_Locations.Location, s_Locations.Active, Count(L_Log.D_ID) AS CountOfD_ID, Min(L_Log.R_AdmDate) AS MinOfR_AdmDate, Max(L_Log.R_DisDate) AS MaxOfR_DisDate
FROM s_Locations LEFT JOIN L_Log ON s_Locations.Location = L_Log.R_Location
FROM s_Locations LEFT JOIN L_Log ON s_Locations.Location = L_Log.R_Location
GROUP BY s_Locations.Location, s_Locations.Active
GROUP BY s_Locations.Location, s_Locations.Active
ORDER BY s_Locations.Location;
ORDER BY s_Locations.Location;
 
</pre>




[[Category: Reporting]]
[[Category: Reporting]]
[[Category: Statistical Analysis]]
[[Category: Statistical Analysis]]

Revision as of 16:03, 5 December 2018

Total number of encounters in the ICU and Medicine in Database: CCMDB.

This article is tagged to be reviewed periodically. The next scheduled review is on 2018-10-16.

Database Total Records current to date
Critical Care 117,452 Mar 9.18
Medicine 158,973 Mar 9.18
TOTAL 277,425 Mar 9.18

Data Collection Start Dates for each Hospital in Region Go to: Site and Location table

SQL

To generate a per-unit count in Access paste the following:

SELECT s_Locations.Location, s_Locations.Active, Count(L_Log.D_ID) AS CountOfD_ID, Min(L_Log.R_AdmDate) AS MinOfR_AdmDate, Max(L_Log.R_DisDate) AS MaxOfR_DisDate
FROM s_Locations LEFT JOIN L_Log ON s_Locations.Location = L_Log.R_Location
GROUP BY s_Locations.Location, s_Locations.Active
ORDER BY s_Locations.Location;