FOCUS Clinic Record System Database Description

The database in Clinic Record System is a relational database. It contains several tables that store information about patients, reminders, appointment, labs and other related information.

Database Overview

OpenEMR default database

This system is based on OpenEMR. OpenEMR has already provided a default database, it contains tables and information that are ready for developers to use. For more detailed information about the default database structure, please visit OpenEMR documentation website by this link: OpenEMR Defualt Database Structure

New Added/Modified tables

There are several tables that are added or modified later in default OpenEMR database. Those tables can be found in this section. Table drugs and remind are new tables added to database, and tables prescriptions, procedure_order openemr_postcalendar_categories and openemr_postcalendar_events have new data imported.

Table drugs

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
CREATE TABLE `drugs` (
     `drug_id` int(11) NOT NULL AUTO_INCREMENT,
     `name` varchar(255) NOT NULL DEFAULT '',
     `dosage` varchar(200) NOT NULL,
     `ndc_number` varchar(20) NOT NULL DEFAULT '',
     `on_order` int(11) NOT NULL DEFAULT '0',
     `reorder_point` float NOT NULL DEFAULT '0',
     `max_level` float NOT NULL DEFAULT '0',
     `last_notify` date NOT NULL DEFAULT '0000-00-00',
     `reactions` text,
     `form` int(3) NOT NULL DEFAULT '0',
     `size` float unsigned NOT NULL DEFAULT '0',
     `unit` int(11) NOT NULL DEFAULT '0',
     `route` int(11) NOT NULL DEFAULT '0',
     `substitute` int(11) NOT NULL DEFAULT '0',
     `related_code` varchar(255) NOT NULL DEFAULT '' COMMENT 'may reference a related codes.code',
     `cyp_factor` float NOT NULL DEFAULT '0' COMMENT 'quantity representing a years supply',
     `active` tinyint(1) DEFAULT '1' COMMENT '0 = inactive, 1 = active',
     `allow_combining` tinyint(1) NOT NULL DEFAULT '0' COMMENT '1 = allow filling an order from multiple lots',
     `allow_multiple` tinyint(1) NOT NULL DEFAULT '1' COMMENT '1 = allow multiple lots at one warehouse',
   PRIMARY KEY (`drug_id`)
 ) ENGINE=MyISAM AUTO_INCREMENT=84111 DEFAULT CHARSET=utf8;

Table remind

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
CREATE TABLE `remind` (
     `rid` int(20) NOT NULL AUTO_INCREMENT,
     `eid` int(11) NOT NULL,
     `pid` int(20) NOT NULL,
     `fname` varchar(30) NOT NULL,
     `lname` varchar(40) NOT NULL,
     `encount` varchar(200) NOT NULL,
     `category` varchar(80) NOT NULL,
     `en_date` date NOT NULL,
     `duedate` date NOT NULL,
     `level` int(20) NOT NULL,
     `notes` varchar(220) NOT NULL,
     `status` varchar(20) NOT NULL,
  PRIMARY KEY (`rid`)
) ENGINE=InnoDB AUTO_INCREMENT=172 DEFAULT CHARSET=utf8;