![]() This is not intended as a recipe, it is intended to hint at the potential of what you can do with Iguana when you start to think outside the box. If you like clean code like me you can remove every legacy reference, and still revert at anytime using the Iguana milestones. This is the mapping for the (fictional) legacy system, which has a very dodgy database structure: This could all be achieved in a single channel with multiple calls to db. If you are introducing a new system and phasing out a legacy system with a different database structure you could use a second VMD file to map to the legacy system. In fact we recommend it as best practice to use different VMD files to separate the message structure (VMD Message Grammar) and the database table mappings (VMD Table Grammar) – particularly for more complex systems. This example shows a single message mapped to two databases using a separate VMD file to map to the legacy system.Īn example of the power and flexibility of Iguana is that you can use different VMD files for hl7.parse() and db.tables(). Using multiple VMD files to map to different databasesĪnother scenario would be migrating from a legacy system, in this case you have multiple databases and multiple messages. The resulting code would look something like this: This example code uses the same VMD file for hl7.parse() and db.tables(): Also if some messages use different versions of HL7 you can tailor the VMDs to use that specific version of HL7. By using a separate table schema VMD and multiple HL7 messages VMDs (one for each message type) we create a structure that better reflects what the organization does. Generally it is best practice to structure code to reflect business process. Many organizations need to map various different HL7 messages to a single database. It is best practice to use different VMD files to separate the message structure (VMD Message Grammar) and the database table mappings (VMD Table Grammar). We recommend using different VMD files for the message structure and the table mapping. ![]() Use different VMD files for message and table mapping This section includes examples for keeping messages and table mapping separated, and the another for separating the structure of two databases. If you have any questions about using Chameleon please contact us at Using Multiple VMD files For example you may want to use one VMD for messages and another for database table structures, or you can use two VMD files to map to two different databases. Using multiple VMD files in a single channel is a useful technique for separating different uses of VMD files. ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |