MAKEMSI quickly and reliably creates MSI files in a non-programmatic way
Have your say! Join the MAKEMSI discussion list or view archive! Suggest improvements. No question too simple or too complex.
[Bottom][Contents][Prev]: Compile[Next]: Column Macros
Have your say! Join the MAKEMSI discussion list or view archive! Suggest improvements. No question too simple or too complex.
\->Source Code->Commands->Column

The "Column" Command

Before MAKEMSI can refer to a table it needs to know some information about it. This applies to standard MSI tables or any that you might wish to create for your own uses.

This command defines a single table column for the table definition started by the "TableDefinition" command. Some information is recorded in "Column Macros" which you can refer to in your script.

The order of the columns is significant and should match that of the MSI tables being defined. Note that you must follow any MSI restrictions that are in place, for example primary fields must be defined first.

This command takes these parameters:

Note that the above information can be obtained by exporting existing tables with "ORCA" and looking at the first 3 lines (the IDT format is relatively obvious and is poorly documented in "MSI.CHM").

EXAMPLE

This example shows the definitions for the standard "Binary" and "File" tables:

<$TableDefinition "Binary">
   <$Column "Name"  TYPE="s72"  KEY="Y">  ;;Max 72 Characters
   <$Column "Data"  TYPE="v0">            ;;Binary field (unlimited length)
<$/TableDefinition>
<$TableDefinition "File">
   <$Column "File"        TYPE="s72"   KEY="Y">
   <$Column "Component_"  TYPE="s72">
   <$Column "FileName"    TYPE="l255">
   <$Column "FileSize"    TYPE="i4">
   <$Column "Version"     TYPE="S72">
   <$Column "Language"    TYPE="S20">
   <$Column "Attributes"  TYPE="I2">
   <$Column "Sequence"    TYPE="i2">
<$/TableDefinition>

;--- Define an internal MAKEMSI table ---------------------------------------
<$TableDefinition "MAKEMSI_FileSource">
   <$Column "File_"       TYPE="s72"   KEY="Y">
   <$Column "SourceFile"  TYPE="s255">
<$/TableDefinition>
<$TableCreate "MAKEMSI_FileSource">
<$Table "_Validation">
#(
   <$Row
            Table="MAKEMSI_FileSource"
           Column="File_"
         Nullable="N"
         KeyTable="File"
        KeyColumn="1"
         Category="Identifier"
      Description="Foreign key into the File table."
   >
#)
#(
   <$Row
            Table="MAKEMSI_FileSource"
           Column="SourceFile"
         Nullable="N"
         Category="Text"
      Description="Full name of source file."
   >
#)
<$/Table>


Microsoft awarded me an MVP (Most Valuable Professional award) in 2004, 2005, 2006, 2007, 2008 & 2009 for the Windows SDK (Windows Installer) area.Please email me any feedback, additional information or corrections.
See this page online (look for updates)

[Top][Contents][Prev]: Compile[Next]: Column Macros


MAKEMSI© is (C)opyright Dennis Bareis 2003-2008 (All rights reserved).
Saturday May 28 2022 at 3:11pm
Visit MAKEMSI's Home Page
Microsoft awarded me an MVP (Most Valuable Professional award) in 2004, 2005, 2006, 2007, 2008 & 2009 for the Windows SDK (Windows Installer) area.