Trying to use EnsureTable in Wix to fix Validation Errors

允我心安 提交于 2020-01-11 06:15:12

问题


I hit numerous errors in Wix 3.0 when I tried to use the msvbvm60.msm merge module:

C:\[...]: error LGHT0204 : ICE03: Table: Registry Column: Registry Missing specifications in _Validation Table (or Old Database)
C:\[...]: error LGHT0204 : ICE03: Table: Registry Column: Root Missing specifications in _Validation Table (or Old Database)
C:\[...]: error LGHT0204 : ICE03: Table: Registry Column: Key Missing specifications in _Validation Table (or Old Database)
C:\[...]: error LGHT0204 : ICE03: Table: Registry Column: Name Missing specifications in _Validation Table (or Old Database)
C:\[...]: error LGHT0204 : ICE03: Table: Registry Column: Value Missing specifications in _Validation Table (or Old Database)
C:\[...]: error LGHT0204 : ICE03: Table: Registry Column: Component_ Missing specifications in _Validation Table (or Old Database)
C:\[...]: error LGHT0204 : ICE03: Table: Extension Column: Extension Missing specifications in _Validation Table (or Old Database)
C:\[...]: error LGHT0204 : ICE03: Table: Extension Column: Component_ Missing specifications in _Validation Table (or Old Database)
C:\[...]: error LGHT0204 : ICE03: Table: Extension Column: ProgId_ Missing specifications in _Validation Table (or Old Database)
C:\[...]: error LGHT0204 : ICE03: Table: Extension Column: MIME_ Missing specifications in _Validation Table (or Old Database)
C:\[...]: error LGHT0204 : ICE03: Table: Extension Column: Feature_ Missing specifications in _Validation Table (or Old Database)
C:\[...]: error LGHT0204 : ICE03: Table: MIME Column: ContentType Missing specifications in _Validation Table (or Old Database)
C:\[...]: error LGHT0204 : ICE03: Table: MIME Column: Extension_ Missing specifications in _Validation Table (or Old Database)
C:\[...]: error LGHT0204 : ICE03: Table: MIME Column: CLSID Missing specifications in _Validation Table (or Old Database)
C:\[...]: error LGHT0204 : ICE03: Table: Class Column: CLSID Missing specifications in _Validation Table (or Old Database)
C:\[...]: error LGHT0204 : ICE03: Table: Class Column: Context Missing specifications in _Validation Table (or Old Database)
C:\[...]: error LGHT0204 : ICE03: Table: Class Column: Component_ Missing specifications in _Validation Table (or Old Database)
C:\[...]: error LGHT0204 : ICE03: Table: Class Column: ProgId_Default Missing specifications in _Validation Table (or Old Database)
C:\[...]: error LGHT0204 : ICE03: Table: Class Column: Description Missing specifications in _Validation Table (or Old Database)
C:\[...]: error LGHT0204 : ICE03: Table: Class Column: AppId_ Missing specifications in _Validation Table (or Old Database)
C:\[...]: error LGHT0204 : ICE03: Table: Class Column: FileTypeMask Missing specifications in _Validation Table (or Old Database)
C:\[...]: error LGHT0204 : ICE03: Table: Class Column: Icon_ Missing specifications in _Validation Table (or Old Database)
C:\[...]: error LGHT0204 : ICE03: Table: Class Column: IconIndex Missing specifications in _Validation Table (or Old Database)
C:\[...]: error LGHT0204 : ICE03: Table: Class Column: DefInprocHandler Missing specifications in _Validation Table (or Old Database)
C:\[...]: error LGHT0204 : ICE03: Table: Class Column: Argument Missing specifications in _Validation Table (or Old Database)
C:\[...]: error LGHT0204 : ICE03: Table: Class Column: Feature_ Missing specifications in _Validation Table (or Old Database)
C:\[...]: error LGHT0204 : ICE03: Table: Class Column: Attributes Missing specifications in _Validation Table (or Old Database)
C:\[...]: error LGHT0204 : ICE03: Table: ProgId Column: ProgId Missing specifications in _Validation Table (or Old Database)
C:\[...]: error LGHT0204 : ICE03: Table: ProgId Column: ProgId_Parent Missing specifications in _Validation Table (or Old Database)
C:\[...]: error LGHT0204 : ICE03: Table: ProgId Column: Class_ Missing specifications in _Validation Table (or Old Database)
C:\[...]: error LGHT0204 : ICE03: Table: ProgId Column: Description Missing specifications in _Validation Table (or Old Database)
C:\[...]: error LGHT0204 : ICE03: Table: ProgId Column: Icon_ Missing specifications in _Validation Table (or Old Database)
C:\[...]: error LGHT0204 : ICE03: Table: ProgId Column: IconIndex Missing specifications in _Validation Table (or Old Database)
C:\[...]: error LGHT0204 : ICE03: Table: Verb Column: Extension_ Missing specifications in _Validation Table (or Old Database)
C:\[...]: error LGHT0204 : ICE03: Table: Verb Column: Verb Missing specifications in _Validation Table (or Old Database)
C:\[...]: error LGHT0204 : ICE03: Table: Verb Column: Sequence Missing specifications in _Validation Table (or Old Database)
C:\[...]: error LGHT0204 : ICE03: Table: Verb Column: Command Missing specifications in _Validation Table (or Old Database)
C:\[...]: error LGHT0204 : ICE03: Table: Verb Column: Argument Missing specifications in _Validation Table (or Old Database)

I read somewhere that I could use EnsureTable to fix this, so I tried, as a test, adding <EnsureTable Id="Key" /> to Product. This caused me to get an error:

C:\Users...(28) : error LGHT0094 : Unresolved reference to symbol 'WixCustomTable:Key' in section 'Product:[GUID]'.

Any advice?


回答1:


EnsureTable/@Id should refer to the table you want to have pulled in. In your case, you need:

<EnsureTable Id="Registry"/>
<EnsureTable Id="Extension"/>
<EnsureTable Id="MIME"/>

and so on. What this does is ensure the WiX toolset pulls in its definition of the tables with the appropriate _Validation table entries before the Merge Module brings in its table definitions without the _Validation table entries.

PS: The root cause is that the Merge Module you are consuming is not built to spec. You might notify the people you acquired the Merge Module from that they are producing busted stuff (yes, I appreciate this is probably Microsoft).



来源:https://stackoverflow.com/questions/461907/trying-to-use-ensuretable-in-wix-to-fix-validation-errors

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!