After specifying the segment grammar, step 5 is to specify your application's view of the message data, the "table grammar". If the VMD file is being used to parse inbound messages, data will be mapped from specified fields in the HL7 message to the tables in the table grammar. If the VMD file is being used to generate HL7 outbound, data will be mapped from the tables in the table grammar to the fields in the outbound HL7 message.
To create a table:
Click the Table icon on the toolbar.
Right-click the Table in the Workspace and choose Rename Table. Rename the table Patient.
After you rename the table, the next step is to add it to the table grammar:
Click and drag the Patient table into the Table Grammar panel, and drop it under Message.
When you add the table to the table grammar you will notice an error icon, which indicates that the grammar root has not been set. Therefore, the next step is to set the grammar root.