Hello all, About the discussion in this list (-> patient registration and the big vision to get a very flexible structure in it). I want to talk about the data structure here, not about the GUI realisation part.
Nearly all hospitals, counties, countries will have own ideas of storing demographic data. What is the situation right now? The situation is that every programmer what have the aim of integration taking the table care_person and add their own columns. Or even misusing given ones for their own use. For a wider perspective I will suggest an idea. An idea of having a better data structure... Please let's talk about it and give your comments to it: What is the requirement for a patient Table: -> The PID must be unique (is now realized of having an auto-increment primary key column) -> The date-field of the creation date (date_reg) -> Optional fields... First name, last name, phone number, street, PO-Box, ZIP.... What do you think about having now following structure? care_person: ID | date_reg | parent | value | data 1 | 1998-01-01 00:00:00 | -1 | PID | 1 2 | NULL | 1 | firstname | test 3 | NULL | 1 | lastname | nobody .. | ... | ... | ... | ... 10 | 1998-01-01 00:00:00 | -1 | PID | 1 11 | NULL | 10 | firstname | test person 2 12 | NULL | 10 | lastname | nobody 2 ... -> The content (firstname, lastname ...) will be described in an additionally table. Basic idea of this hierarchical structure: A non auto increment-identifier (column: PID) will point to the primary key (column: ID) of the table. If the parent has the value -1 it will describe the root. If you want all datas of this value pid 1 then you have to select this table to ID=parent. The last table it is not clear for me (for the moment). Idea is that every adaptation can insert there the possible values of the content table. Additionally to that even the attribute value like checkbox, input field, select box->and their possible values of it (maybe). This is quite an idea. Let me know what you think about. This change will affect nearly all kind of modules of care2x (my hope: basically the class_core -> but it is quite a lot of work to be done when it should work!) What I do not like in my idea are following issues: -> The primary key-value points to an key (It´s might be okay, but:) -> the data column should have a global data type and I do not like that idea. Any suggestions or ideas? Robert ------------------------------------------------------------------------- Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 _______________________________________________ Care2002-developers mailing list Care2002-developers@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/care2002-developers