<?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 Re: How to execute query from Qlikview load script in order to fetch data from SAP in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/How-to-execute-query-from-Qlikview-load-script-in-order-to-fetch/m-p/1226107#M391336</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Can you please post your script&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 21 Feb 2017 14:19:22 GMT</pubDate>
    <dc:creator>aarkay29</dc:creator>
    <dc:date>2017-02-21T14:19:22Z</dc:date>
    <item>
      <title>How to execute query from Qlikview load script in order to fetch data from SAP</title>
      <link>https://community.qlik.com/t5/QlikView/How-to-execute-query-from-Qlikview-load-script-in-order-to-fetch/m-p/1226103#M391332</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Dear Community Users,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have been given a SAP query from SAP team, and the objective is to run the SAP query from Qlikview load script and fetch the data.&lt;/P&gt;&lt;P&gt;Below is the query, when i run this query in Qlikview with connection information. am getting Script Error.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'courier new', courier;"&gt;SELECT distinct b.objectvalue as ebeln&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'courier new', courier;"&gt;FROM CDPOS b,&lt;/SPAN&gt;&lt;SPAN style="font-family: 'courier new', courier;"&gt; CDHDR a&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'courier new', courier;"&gt;WHERE b.objectclas&amp;nbsp;&amp;nbsp;&amp;nbsp; = ‘EINKBELEG’&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'courier new', courier;"&gt;AND&amp;nbsp; b.tabname = ‘EKES’&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'courier new', courier;"&gt;And&amp;nbsp;&amp;nbsp; b.objectvalue = a.objectvalue&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'courier new', courier;"&gt;AND&amp;nbsp; b.changenr = a.changenr &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: 'courier new', courier;"&gt;AND&amp;nbsp; a.objectclas = ‘EINKBELEG’&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 11.0pt; font-family: 'Calibri',sans-serif;"&gt;&lt;SPAN style="font-family: 'courier new', courier;"&gt;AND&amp;nbsp; a.udate&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;gt;= &amp;amp;LastRunDate&lt;/SPAN&gt;&amp;nbsp; ;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Appreciate your Help.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;P&gt;Balamuralidharan T &lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 20 Feb 2017 10:23:55 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-to-execute-query-from-Qlikview-load-script-in-order-to-fetch/m-p/1226103#M391332</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2017-02-20T10:23:55Z</dc:date>
    </item>
    <item>
      <title>Re: How to execute query from Qlikview load script in order to fetch data from SAP</title>
      <link>https://community.qlik.com/t5/QlikView/How-to-execute-query-from-Qlikview-load-script-in-order-to-fetch/m-p/1226104#M391333</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;What does you connect statement say during script run? Do you get a successful connection? Is it the SELECT statement that really cause the "Script Error"?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You quotes in the SQL above seems off. They are a back-tick as start and forward-tick as end ... which seems odd. I don't know much about SAP but I am pretty sure that single qutoes; straight/vertical like this &lt;STRONG&gt;'&lt;/STRONG&gt;&amp;nbsp; is what you need to use:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&lt;SPAN style="font-weight: inherit; font-style: inherit; font-family: 'courier new', courier;"&gt;SELECT distinct b.objectvalue as ebeln&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&lt;SPAN style="font-weight: inherit; font-style: inherit; font-family: 'courier new', courier;"&gt;FROM CDPOS b,&lt;/SPAN&gt;&lt;SPAN style="font-weight: inherit; font-style: inherit; font-family: 'courier new', courier;"&gt; CDHDR a&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&lt;SPAN style="font-weight: inherit; font-style: inherit; font-family: 'courier new', courier;"&gt;WHERE b.objectclas&amp;nbsp;&amp;nbsp;&amp;nbsp; = 'EINKBELEG'&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&lt;SPAN style="font-weight: inherit; font-style: inherit; font-family: 'courier new', courier;"&gt;AND&amp;nbsp; b.tabname = 'EKES'&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&lt;SPAN style="font-weight: inherit; font-style: inherit; font-family: 'courier new', courier;"&gt;And&amp;nbsp;&amp;nbsp; b.objectvalue = a.objectvalue&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&lt;SPAN style="font-weight: inherit; font-style: inherit; font-family: 'courier new', courier;"&gt;AND&amp;nbsp; b.changenr = a.changenr&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&lt;SPAN style="font-weight: inherit; font-style: inherit; font-family: 'courier new', courier;"&gt;AND&amp;nbsp; a.objectclas = 'EINKBELEG'&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&lt;SPAN style="font-weight: inherit; font-style: inherit; font-size: 11pt; font-family: Calibri, sans-serif;"&gt;&lt;SPAN style="font-weight: inherit; font-style: inherit; font-size: 14.6667px; font-family: 'courier new', courier;"&gt;AND&amp;nbsp; a.udate&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;gt;= &amp;amp;LastRunDate&lt;/SPAN&gt;&amp;nbsp; ;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 20 Feb 2017 15:39:34 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-to-execute-query-from-Qlikview-load-script-in-order-to-fetch/m-p/1226104#M391333</guid>
      <dc:creator>petter</dc:creator>
      <dc:date>2017-02-20T15:39:34Z</dc:date>
    </item>
    <item>
      <title>Re: How to execute query from Qlikview load script in order to fetch data from SAP</title>
      <link>https://community.qlik.com/t5/QlikView/How-to-execute-query-from-Qlikview-load-script-in-order-to-fetch/m-p/1226105#M391334</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P style="font-size: 13.3333px;"&gt;&lt;SPAN style="font-size: 10pt;"&gt;&lt;STRONG&gt;Try this:&lt;BR /&gt;&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13.3333px;"&gt;&lt;SPAN style="font-size: 10pt;"&gt;&lt;STRONG&gt;LOAD OBJECTVALUE AS EBELN&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13.3333px;"&gt;&lt;SPAN style="font-size: 10pt;"&gt;&lt;STRONG&gt;;&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13.3333px;"&gt;&lt;SPAN style="font-size: 10pt;"&gt;&lt;STRONG&gt;SQL SUBSELECT OBEJECTVALUE FROM CDPOS&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13.3333px;"&gt;&lt;SPAN style="font-size: 10pt;"&gt;&lt;STRONG&gt;WHERE&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13.3333px;"&gt;&lt;SPAN style="font-size: 10pt;"&gt;&lt;STRONG&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; OBJECTCLAS='EINKBELEG' AND TABNAME='EKES' AND OBJECTVALUE CHANGENR&amp;nbsp; IN ( SELECT OBJECTVALUE CHANGENR FROM CDHDR WHERE UDATE &amp;gt;= '$(LastRunDate)' );&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13.3333px;"&gt;&lt;SPAN style="font-size: 10pt;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="font-size: 13.3333px;"&gt;&lt;SPAN style="font-size: 10pt;"&gt;Make sure that &lt;SPAN style="font-size: 13.3333px;"&gt;LastRunDate&lt;/SPAN&gt; is in YYYYMMDD format and also I believe that OBJECTID is the name for field OBJECTVALUE in SAP TABLE CDPOS and CDHDR. &lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 20 Feb 2017 16:01:57 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-to-execute-query-from-Qlikview-load-script-in-order-to-fetch/m-p/1226105#M391334</guid>
      <dc:creator>aarkay29</dc:creator>
      <dc:date>2017-02-20T16:01:57Z</dc:date>
    </item>
    <item>
      <title>Re: How to execute query from Qlikview load script in order to fetch data from SAP</title>
      <link>https://community.qlik.com/t5/QlikView/How-to-execute-query-from-Qlikview-load-script-in-order-to-fetch/m-p/1226106#M391335</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Aar Kay, Thanks for your reply. I did execute the query which you recommended but still am getting the script error.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Yes, am able to connect the SAP.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Please find below the snapshot of Error message,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;IMG alt="Error Message.JPG" class="jive-image image-1" src="/legacyfs/online/153901_Error Message.JPG" style="height: 267px; width: 620px;" /&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;P&gt;Balamuralidharan T&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 21 Feb 2017 11:57:37 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-to-execute-query-from-Qlikview-load-script-in-order-to-fetch/m-p/1226106#M391335</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2017-02-21T11:57:37Z</dc:date>
    </item>
    <item>
      <title>Re: How to execute query from Qlikview load script in order to fetch data from SAP</title>
      <link>https://community.qlik.com/t5/QlikView/How-to-execute-query-from-Qlikview-load-script-in-order-to-fetch/m-p/1226107#M391336</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Can you please post your script&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 21 Feb 2017 14:19:22 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/How-to-execute-query-from-Qlikview-load-script-in-order-to-fetch/m-p/1226107#M391336</guid>
      <dc:creator>aarkay29</dc:creator>
      <dc:date>2017-02-21T14:19:22Z</dc:date>
    </item>
  </channel>
</rss>

