<?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 Calling a script from a macro in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Calling-a-script-from-a-macro/m-p/357938#M704997</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Check this link hope it helps you.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;A _jive_internal="true" href="https://community.qlik.com/docs/DOC-2784"&gt;http://community.qlik.com/docs/DOC-2784&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Jagan.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 18 Apr 2012 16:40:59 GMT</pubDate>
    <dc:creator>jagan</dc:creator>
    <dc:date>2012-04-18T16:40:59Z</dc:date>
    <item>
      <title>Calling a script from a macro</title>
      <link>https://community.qlik.com/t5/QlikView/Calling-a-script-from-a-macro/m-p/357937#M704996</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Everyone,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I need to provide a QV solution for the users which does the following:&lt;/P&gt;&lt;P&gt;1. gets a value from a selector (say VALUE)&lt;/P&gt;&lt;P&gt;2. deletes a set of rows from a sql server DB (delete from table where field = VALUE)&lt;/P&gt;&lt;P&gt;3. deletes the same set of data from the relevant qvd file&lt;/P&gt;&lt;P&gt;4. reloads the data.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;For doing so, I have thought I could use a button with a macro and I have found out how to connect to the sql server DB and delete the rows.&lt;/P&gt;&lt;P&gt;However, I don't know how to reflect these changes on the .qvd file as well as I don't see a way of calling the store command from within a macro. Is this possible?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Any other (maybe simpler) solution anyone can think of would be much appreciated.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks and Best Wishes,&lt;/P&gt;&lt;P&gt;Melania&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 18 Apr 2012 14:00:12 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Calling-a-script-from-a-macro/m-p/357937#M704996</guid>
      <dc:creator />
      <dc:date>2012-04-18T14:00:12Z</dc:date>
    </item>
    <item>
      <title>Calling a script from a macro</title>
      <link>https://community.qlik.com/t5/QlikView/Calling-a-script-from-a-macro/m-p/357938#M704997</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Check this link hope it helps you.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;A _jive_internal="true" href="https://community.qlik.com/docs/DOC-2784"&gt;http://community.qlik.com/docs/DOC-2784&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Jagan.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 18 Apr 2012 16:40:59 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Calling-a-script-from-a-macro/m-p/357938#M704997</guid>
      <dc:creator>jagan</dc:creator>
      <dc:date>2012-04-18T16:40:59Z</dc:date>
    </item>
    <item>
      <title>Calling a script from a macro</title>
      <link>https://community.qlik.com/t5/QlikView/Calling-a-script-from-a-macro/m-p/357939#M704998</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Jagan,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;that's cool, thanks a mil.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I also need to delete some data from the QVD file and I was wondering if it's possible to:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;1. delete the data from the QV logical tables in memory with something like&lt;/P&gt;&lt;P&gt;SET Result = ActiveDocument.DynamicUpdateCommand ("DELETE Table FACT Where FAC_id_extraction = 20120316114852")&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;and then &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;2. execute a store command to store the content of the table (after deletion) into the qvd file but I haven't ound any examples of calling a QV script from within a macro (whereas the opposite is quite common - i.e. calling a macro from a script). Is there any chance I can invoke a store command from within a macro? &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks a million,&lt;/P&gt;&lt;P&gt;Melania&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 18 Apr 2012 22:41:21 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Calling-a-script-from-a-macro/m-p/357939#M704998</guid>
      <dc:creator />
      <dc:date>2012-04-18T22:41:21Z</dc:date>
    </item>
    <item>
      <title>Calling a script from a macro</title>
      <link>https://community.qlik.com/t5/QlikView/Calling-a-script-from-a-macro/m-p/357940#M704999</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I don't think it is easier, but we can do this by saving the deleted records IDs in a CSV or Excel file in macro, and during reload exclude this values by using Except().&amp;nbsp; Check script below&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;DeletedIDs:&lt;/P&gt;&lt;P&gt;LOAD&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; FAC_id_extraction&lt;/P&gt;&lt;P&gt;FROM FileName;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;DATA:&lt;/P&gt;&lt;P&gt;LOAD&lt;/P&gt;&lt;P&gt;*&lt;/P&gt;&lt;P&gt;FROM FileName.qvd (qvd)&lt;/P&gt;&lt;P&gt;WHERE NOT EXISTS(FAC_id_extraction);&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;STORE DATA INTO FileName.qvd;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;DROP TABLE DeletedIDs;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Jagan.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 19 Apr 2012 05:43:44 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Calling-a-script-from-a-macro/m-p/357940#M704999</guid>
      <dc:creator>jagan</dc:creator>
      <dc:date>2012-04-19T05:43:44Z</dc:date>
    </item>
    <item>
      <title>Calling a script from a macro</title>
      <link>https://community.qlik.com/t5/QlikView/Calling-a-script-from-a-macro/m-p/357941#M705000</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Jagan,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I was thinking about calling the Releoad method from within the macro.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;However, this forces the re-execution of the entire reload script. Can I execute just a portion of the reload script and not the entire one?&lt;/P&gt;&lt;P&gt;If the answer is not, then I think I'll write a macro that does that:&lt;/P&gt;&lt;P&gt;- delete the rows from the SQL Server DB table&lt;/P&gt;&lt;P&gt;- execute a Reload from the macro&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I will also have to modify the script to perform an insert/delete/update operation (as explained in the QV reference manual - using qvd for incremental load - case 4).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I was just trying to avoid to re-execute the entire script just to align the content of a qvd file with the database table after a few rows have been deleted.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks a million and Best Wishes,&lt;/P&gt;&lt;P&gt;Melania&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 19 Apr 2012 10:02:41 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Calling-a-script-from-a-macro/m-p/357941#M705000</guid>
      <dc:creator />
      <dc:date>2012-04-19T10:02:41Z</dc:date>
    </item>
  </channel>
</rss>

