<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Create a specific message box in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Create-a-specific-message-box/m-p/736290#M676593</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello to everybody. &lt;/P&gt;&lt;P&gt;I have a next situation. I have to load tables with specific keys but frequently we have cases with missing fields, because the fields in the script of load statement are variables. &lt;/P&gt;&lt;P&gt;So, I’m searching for a solution about this problem and I want to create a message with&amp;nbsp; “which is the missing fields” in the layout.&amp;nbsp; &lt;/P&gt;&lt;P&gt;My idea for script is: &lt;/P&gt;&lt;TABLE&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD&gt;&lt;STRONG&gt;SET ErrorMode = 0;&lt;/STRONG&gt;&lt;/TD&gt;&lt;TD&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;&lt;STRONG&gt;LOAD * &lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;FROM Abc.QVD ;&amp;nbsp;&amp;nbsp; &lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&lt;BR /&gt;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;I think that I have to create a “IF” statement where ScriptError = 11 then ……… . &lt;/P&gt;&lt;P&gt;But I don’t know how to continue.&lt;/P&gt;&lt;P&gt;I’m not sure that is the right way, so please give me an advice &lt;IMG src="https://community.qlik.com/legacyfs/online/emoticons/happy.png" /&gt;. &lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 09 Jul 2014 07:05:26 GMT</pubDate>
    <dc:creator />
    <dc:date>2014-07-09T07:05:26Z</dc:date>
    <item>
      <title>Create a specific message box</title>
      <link>https://community.qlik.com/t5/QlikView/Create-a-specific-message-box/m-p/736290#M676593</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello to everybody. &lt;/P&gt;&lt;P&gt;I have a next situation. I have to load tables with specific keys but frequently we have cases with missing fields, because the fields in the script of load statement are variables. &lt;/P&gt;&lt;P&gt;So, I’m searching for a solution about this problem and I want to create a message with&amp;nbsp; “which is the missing fields” in the layout.&amp;nbsp; &lt;/P&gt;&lt;P&gt;My idea for script is: &lt;/P&gt;&lt;TABLE&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD&gt;&lt;STRONG&gt;SET ErrorMode = 0;&lt;/STRONG&gt;&lt;/TD&gt;&lt;TD&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;&lt;STRONG&gt;LOAD * &lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;FROM Abc.QVD ;&amp;nbsp;&amp;nbsp; &lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;&lt;BR /&gt;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;I think that I have to create a “IF” statement where ScriptError = 11 then ……… . &lt;/P&gt;&lt;P&gt;But I don’t know how to continue.&lt;/P&gt;&lt;P&gt;I’m not sure that is the right way, so please give me an advice &lt;IMG src="https://community.qlik.com/legacyfs/online/emoticons/happy.png" /&gt;. &lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 09 Jul 2014 07:05:26 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Create-a-specific-message-box/m-p/736290#M676593</guid>
      <dc:creator />
      <dc:date>2014-07-09T07:05:26Z</dc:date>
    </item>
    <item>
      <title>Re: Create a specific message box</title>
      <link>https://community.qlik.com/t5/QlikView/Create-a-specific-message-box/m-p/736291#M676594</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;DIV&gt;&lt;SPAN style="color: #333333; font-size: 14pt;"&gt;Hi, &lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #333333; font-size: 14pt;"&gt;ScriptErrorDetails does not survive reload or contains info about the last error only (I am using QV 11.2 SR5) . &lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt; &lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #333333; font-size: 14pt;"&gt;You have to take the information in it during script run. &lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #333333; font-size: 14pt;"&gt;ScriptErrorDetails keeps only the detail for the last error that occurred.&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt; &lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #333333; font-size: 14pt;"&gt;For example if you run the script below, you will have only the error detail about the missing txt file even though ScriptErrorCount will be 2.&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #333333; font-size: 14pt;"&gt;If you uncomment the last 3 lines the error detail about the Table not Found will also get saved - concatenated to the table ErrorDetailTable.&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt; &lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #333333; font-size: 14pt;"&gt;In similar way you have to save the value of &lt;SPAN style="color: #333333; font-size: 14pt;"&gt;ScriptErrorDetails &lt;/SPAN&gt;after each block of code where error may occur and you will have the info you want in the table ErrorDetailTable.&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt; &lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #333333; font-size: 14pt;"&gt; Note that it is written as '$(ScriptErrorDetails)'&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #333333; font-size: 14pt;"&gt;Hope this helps;&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt; &lt;/DIV&gt;&lt;DIV&gt; &lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #808080; font-size: 14pt;"&gt;&lt;STRONG&gt;&lt;EM&gt;ErrorMode&lt;/EM&gt;&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;SPAN style="font-size: 14pt;"&gt; =0;&lt;BR /&gt;&lt;BR /&gt;MapErrors:&lt;BR /&gt;&lt;/SPAN&gt;&lt;SPAN style="color: #0000ff; font-size: 14pt;"&gt;Mapping &lt;/SPAN&gt;&lt;SPAN style="color: #0000ff; font-size: 14pt;"&gt;&lt;STRONG&gt;LOAD&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;SPAN style="font-size: 14pt;"&gt; * &lt;/SPAN&gt;&lt;SPAN style="color: #0000ff; font-size: 14pt;"&gt;INLINE&lt;/SPAN&gt;&lt;SPAN style="font-size: 14pt;"&gt; &lt;/SPAN&gt;&lt;SPAN style="color: #800000; font-size: 14pt;"&gt;[&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; ErrorCode, Errors&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; 0, No error &lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1, General error &lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; 2, Syntax error &lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; 3, General ODBC error &lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; 4, General OLE DB error &lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; 5, General custom database error &lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; 6, General XML error &lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; 7, General HTML error &lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; 8, File not found &lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; 9, Database not found &lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; 10, Table not found &lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; 11, Field not found &lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; 12, File has wrong format &lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; 13, BIFF error &lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; 14, BIFF error encrypted &lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; 15, BIFF error unsupported version &lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; 16, Semantic error &lt;BR /&gt;&lt;BR /&gt;]&lt;/SPAN&gt;&lt;SPAN style="font-size: 14pt;"&gt;;&lt;BR /&gt;//this should return error - cannot find file user2.txt&lt;BR /&gt;Errors:&lt;BR /&gt;&lt;/SPAN&gt;&lt;SPAN style="color: #0000ff; font-size: 14pt;"&gt;&lt;STRONG&gt;LOAD&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;SPAN style="font-size: 14pt;"&gt; &lt;/SPAN&gt;&lt;SPAN style="color: #800000; font-size: 14pt;"&gt;ErrorCode&lt;/SPAN&gt;&lt;SPAN style="font-size: 14pt;"&gt;, &lt;/SPAN&gt;&lt;SPAN style="color: #800000; font-size: 14pt;"&gt;Errors&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="font-size: 14pt;"&gt;FROM&lt;BR /&gt;&lt;D&gt;&lt;BR /&gt;(&lt;/D&gt;&lt;/SPAN&gt;&lt;SPAN style="color: #0000ff; font-size: 14pt;"&gt;txt&lt;/SPAN&gt;&lt;SPAN style="font-size: 14pt;"&gt;, &lt;/SPAN&gt;&lt;SPAN style="color: #0000ff; font-size: 14pt;"&gt;codepage&lt;/SPAN&gt;&lt;SPAN style="font-size: 14pt;"&gt; &lt;/SPAN&gt;&lt;SPAN style="color: #0000ff; font-size: 14pt;"&gt;is&lt;/SPAN&gt;&lt;SPAN style="font-size: 14pt;"&gt; 1251, &lt;/SPAN&gt;&lt;SPAN style="color: #0000ff; font-size: 14pt;"&gt;embedded&lt;/SPAN&gt;&lt;SPAN style="font-size: 14pt;"&gt; &lt;/SPAN&gt;&lt;SPAN style="color: #0000ff; font-size: 14pt;"&gt;labels&lt;/SPAN&gt;&lt;SPAN style="font-size: 14pt;"&gt;, &lt;/SPAN&gt;&lt;SPAN style="color: #0000ff; font-size: 14pt;"&gt;delimiter&lt;/SPAN&gt;&lt;SPAN style="font-size: 14pt;"&gt; &lt;/SPAN&gt;&lt;SPAN style="color: #0000ff; font-size: 14pt;"&gt;is&lt;/SPAN&gt;&lt;SPAN style="font-size: 14pt;"&gt; ' ', &lt;/SPAN&gt;&lt;SPAN style="color: #0000ff; font-size: 14pt;"&gt;msq&lt;/SPAN&gt;&lt;SPAN style="font-size: 14pt;"&gt;); &lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;DIV&gt; &lt;/DIV&gt;&lt;DIV&gt;//this will create table to keep the info about the last error that has occurred&lt;BR /&gt;ErrorDetailTable:&lt;BR /&gt;&lt;SPAN style="color: #0000ff; font-size: 14pt;"&gt;&lt;STRONG&gt;LOAD&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;SPAN style="font-size: 14pt;"&gt; &lt;/SPAN&gt;&lt;SPAN style="color: #0000ff; font-size: 14pt;"&gt;ApplyMap&lt;/SPAN&gt;&lt;SPAN style="font-size: 14pt;"&gt;('MapErrors','$(ScriptError)') &lt;/SPAN&gt;&lt;SPAN style="color: #0000ff; font-size: 14pt;"&gt;as&lt;/SPAN&gt;&lt;SPAN style="font-size: 14pt;"&gt; &lt;/SPAN&gt;&lt;SPAN style="color: #800000; font-size: 14pt;"&gt;ErrorType&lt;/SPAN&gt;&lt;SPAN style="font-size: 14pt;"&gt;,&lt;BR /&gt; '$(ScriptErrorDetails)' &lt;/SPAN&gt;&lt;SPAN style="color: #0000ff; font-size: 14pt;"&gt;as&lt;/SPAN&gt;&lt;SPAN style="font-size: 14pt;"&gt; &lt;/SPAN&gt;&lt;SPAN style="color: #800000; font-size: 14pt;"&gt;ErrorDetails&lt;/SPAN&gt;&lt;SPAN style="font-size: 14pt;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;SPAN style="color: #0000ff; font-size: 14pt;"&gt;AutoGenerate&lt;/SPAN&gt;&lt;SPAN style="font-size: 14pt;"&gt;(1);&lt;BR /&gt;&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="font-size: 14pt;"&gt;//this should give another error - Table not found, no other details here&lt;/SPAN&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #000000; font-size: 14pt;"&gt;DROP TABLE TTT;&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="font-size: 14pt;"&gt;//uncomment this to save the information about the second error as well&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="font-size: 14pt;"&gt;//LOAD &lt;/SPAN&gt;&lt;SPAN style="font-size: 14pt;"&gt;ApplyMap&lt;/SPAN&gt;&lt;SPAN style="font-size: 14pt;"&gt;('MapErrors','$(ScriptError)') &lt;/SPAN&gt;&lt;SPAN style="font-size: 14pt;"&gt;as&lt;/SPAN&gt;&lt;SPAN style="font-size: 14pt;"&gt; &lt;/SPAN&gt;&lt;SPAN style="font-size: 14pt;"&gt;ErrorType&lt;/SPAN&gt;&lt;SPAN style="font-size: 14pt;"&gt;,&lt;BR /&gt;// '$(ScriptErrorDetails)' &lt;/SPAN&gt;&lt;SPAN style="font-size: 14pt;"&gt;as&lt;/SPAN&gt;&lt;SPAN style="font-size: 14pt;"&gt; &lt;/SPAN&gt;&lt;SPAN style="font-size: 14pt;"&gt;ErrorDetails&lt;/SPAN&gt;&lt;SPAN style="font-size: 14pt;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;SPAN style="font-size: 14pt;"&gt;//AutoGenerate(1);&lt;/SPAN&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 10 Jul 2014 13:40:48 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Create-a-specific-message-box/m-p/736291#M676594</guid>
      <dc:creator>iliyansomlev</dc:creator>
      <dc:date>2014-07-10T13:40:48Z</dc:date>
    </item>
  </channel>
</rss>

