<?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>Question Re: Optimization issue in Technology Q&amp;A</title>
    <link>https://community.sap.com/t5/technology-q-a/optimization-issue/qaa-p/13834254#M4865097</link>
    <description>&lt;P&gt;I got it working it was not trivial and there were a few exceptions under V12 one was mine I have an AES256 encrypted database. -- Thanks&lt;/P&gt;</description>
    <pubDate>Mon, 06 Aug 2012 01:27:48 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2012-08-06T01:27:48Z</dc:date>
    <item>
      <title>Optimization issue</title>
      <link>https://community.sap.com/t5/technology-q-a/optimization-issue/qaq-p/13834243</link>
      <description>&lt;P&gt;There are two sql statements in the text &lt;S&gt;please try using edit to see the first statement only the second one seems to appear and I do not know how to change the text to make both appear&lt;/S&gt;.&lt;/P&gt;
&lt;P&gt;I am performing a recursive update on a key column on a single table.  Only certain keys MOD(ind, 10) = 0 are valid in the recursive key indcopy (enforced by a check clause).  Would either of the following SQL statements eliminate the rows where MOD(ind, 10) &amp;lt;&amp;gt; 0 before attempting the inner joins?  I favor the first because in theory if the where is applied at the appropriate time neither join would ever be attempted.  I believe the second would only attempt the first join and not the second.  (Unless the optimizer recognizes the difference and performs the desired results (neither join) for both.)  This may be trivial in this case however I have other cases with large number of rows where multiple updates using a table scan and outer joins are required.  Whether or not the where clause in the first example is applied at the earliest opportunity is of considerable importance to me.  In the table ind rowupdkey is the primary key,  ind is a unique key and indcopy (child) is a foreign key to ind (parent).&lt;/P&gt;
&lt;DIV class="codehilite"&gt;&lt;PRE&gt;&lt;SPAN class="k"&gt;UPDATE&lt;/SPAN&gt; &lt;SPAN class="k"&gt;data&lt;/SPAN&gt;&lt;SPAN class="p"&gt;.&lt;/SPAN&gt;&lt;SPAN class="n"&gt;ind&lt;/SPAN&gt; &lt;SPAN class="k"&gt;AS&lt;/SPAN&gt; &lt;SPAN class="n"&gt;t&lt;/SPAN&gt;
   &lt;SPAN class="k"&gt;SET&lt;/SPAN&gt; &lt;SPAN class="n"&gt;t&lt;/SPAN&gt;&lt;SPAN class="p"&gt;.&lt;/SPAN&gt;&lt;SPAN class="n"&gt;indcopy&lt;/SPAN&gt; &lt;SPAN class="o"&gt;=&lt;/SPAN&gt; &lt;SPAN class="n"&gt;f&lt;/SPAN&gt;&lt;SPAN class="p"&gt;.&lt;/SPAN&gt;&lt;SPAN class="n"&gt;ind&lt;/SPAN&gt;
  &lt;SPAN class="k"&gt;FROM&lt;/SPAN&gt; &lt;SPAN class="p"&gt;(&lt;/SPAN&gt;&lt;SPAN class="n"&gt;deleted&lt;/SPAN&gt; &lt;SPAN class="k"&gt;AS&lt;/SPAN&gt; &lt;SPAN class="n"&gt;d&lt;/SPAN&gt; &lt;SPAN class="k"&gt;INNER&lt;/SPAN&gt; &lt;SPAN class="k"&gt;JOIN&lt;/SPAN&gt; &lt;SPAN class="k"&gt;data&lt;/SPAN&gt;&lt;SPAN class="p"&gt;.&lt;/SPAN&gt;&lt;SPAN class="n"&gt;ind&lt;/SPAN&gt; &lt;SPAN class="k"&gt;AS&lt;/SPAN&gt; &lt;SPAN class="n"&gt;f&lt;/SPAN&gt; &lt;SPAN class="k"&gt;ON&lt;/SPAN&gt; &lt;SPAN class="n"&gt;f&lt;/SPAN&gt;&lt;SPAN class="p"&gt;.&lt;/SPAN&gt;&lt;SPAN class="n"&gt;rowupdkey&lt;/SPAN&gt; &lt;SPAN class="o"&gt;=&lt;/SPAN&gt; &lt;SPAN class="n"&gt;d&lt;/SPAN&gt;&lt;SPAN class="p"&gt;.&lt;/SPAN&gt;&lt;SPAN class="n"&gt;rowupdkey&lt;/SPAN&gt;&lt;SPAN class="p"&gt;)&lt;/SPAN&gt;
 &lt;SPAN class="k"&gt;INNER&lt;/SPAN&gt; &lt;SPAN class="k"&gt;JOIN&lt;/SPAN&gt; &lt;SPAN class="k"&gt;data&lt;/SPAN&gt;&lt;SPAN class="p"&gt;.&lt;/SPAN&gt;&lt;SPAN class="n"&gt;ind&lt;/SPAN&gt; &lt;SPAN class="k"&gt;AS&lt;/SPAN&gt; &lt;SPAN class="n"&gt;t&lt;/SPAN&gt; &lt;SPAN class="k"&gt;ON&lt;/SPAN&gt; &lt;SPAN class="n"&gt;t&lt;/SPAN&gt;&lt;SPAN class="p"&gt;.&lt;/SPAN&gt;&lt;SPAN class="n"&gt;indcopy&lt;/SPAN&gt; &lt;SPAN class="o"&gt;=&lt;/SPAN&gt; &lt;SPAN class="n"&gt;d&lt;/SPAN&gt;&lt;SPAN class="p"&gt;.&lt;/SPAN&gt;&lt;SPAN class="n"&gt;ind&lt;/SPAN&gt;
 &lt;SPAN class="k"&gt;WHERE&lt;/SPAN&gt; &lt;SPAN class="k"&gt;MOD&lt;/SPAN&gt;&lt;SPAN class="p"&gt;(&lt;/SPAN&gt;&lt;SPAN class="n"&gt;d&lt;/SPAN&gt;&lt;SPAN class="p"&gt;.&lt;/SPAN&gt;&lt;SPAN class="n"&gt;ind&lt;/SPAN&gt;&lt;SPAN class="p"&gt;,&lt;/SPAN&gt; &lt;SPAN class="mi"&gt;10&lt;/SPAN&gt;&lt;SPAN class="p"&gt;)&lt;/SPAN&gt; &lt;SPAN class="o"&gt;=&lt;/SPAN&gt; &lt;SPAN class="mi"&gt;0&lt;/SPAN&gt;
 &lt;SPAN class="k"&gt;ORDER&lt;/SPAN&gt; &lt;SPAN class="k"&gt;BY&lt;/SPAN&gt; &lt;SPAN class="n"&gt;t&lt;/SPAN&gt;&lt;SPAN class="p"&gt;.&lt;/SPAN&gt;&lt;SPAN class="n"&gt;ind&lt;/SPAN&gt;&lt;SPAN class="p"&gt;;&lt;/SPAN&gt;

&lt;SPAN class="k"&gt;UPDATE&lt;/SPAN&gt; &lt;SPAN class="k"&gt;data&lt;/SPAN&gt;&lt;SPAN class="p"&gt;.&lt;/SPAN&gt;&lt;SPAN class="n"&gt;ind&lt;/SPAN&gt; &lt;SPAN class="k"&gt;AS&lt;/SPAN&gt; &lt;SPAN class="n"&gt;t&lt;/SPAN&gt;
   &lt;SPAN class="k"&gt;SET&lt;/SPAN&gt; &lt;SPAN class="n"&gt;t&lt;/SPAN&gt;&lt;SPAN class="p"&gt;.&lt;/SPAN&gt;&lt;SPAN class="n"&gt;indcopy&lt;/SPAN&gt; &lt;SPAN class="o"&gt;=&lt;/SPAN&gt; &lt;SPAN class="n"&gt;f&lt;/SPAN&gt;&lt;SPAN class="p"&gt;.&lt;/SPAN&gt;&lt;SPAN class="n"&gt;ind&lt;/SPAN&gt;
  &lt;SPAN class="k"&gt;FROM&lt;/SPAN&gt; &lt;SPAN class="p"&gt;(&lt;/SPAN&gt;&lt;SPAN class="n"&gt;deleted&lt;/SPAN&gt; &lt;SPAN class="k"&gt;AS&lt;/SPAN&gt; &lt;SPAN class="n"&gt;d&lt;/SPAN&gt;
         &lt;SPAN class="k"&gt;INNER&lt;/SPAN&gt; &lt;SPAN class="k"&gt;JOIN&lt;/SPAN&gt; &lt;SPAN class="k"&gt;data&lt;/SPAN&gt;&lt;SPAN class="p"&gt;.&lt;/SPAN&gt;&lt;SPAN class="n"&gt;ind&lt;/SPAN&gt; &lt;SPAN class="k"&gt;AS&lt;/SPAN&gt; &lt;SPAN class="n"&gt;f&lt;/SPAN&gt;
                 &lt;SPAN class="k"&gt;ON&lt;/SPAN&gt; &lt;SPAN class="k"&gt;MOD&lt;/SPAN&gt;&lt;SPAN class="p"&gt;(&lt;/SPAN&gt;&lt;SPAN class="n"&gt;d&lt;/SPAN&gt;&lt;SPAN class="p"&gt;.&lt;/SPAN&gt;&lt;SPAN class="n"&gt;ind&lt;/SPAN&gt;&lt;SPAN class="p"&gt;,&lt;/SPAN&gt; &lt;SPAN class="mi"&gt;10&lt;/SPAN&gt;&lt;SPAN class="p"&gt;)&lt;/SPAN&gt; &lt;SPAN class="o"&gt;=&lt;/SPAN&gt; &lt;SPAN class="mi"&gt;0&lt;/SPAN&gt; &lt;SPAN class="k"&gt;AND&lt;/SPAN&gt; &lt;SPAN class="n"&gt;f&lt;/SPAN&gt;&lt;SPAN class="p"&gt;.&lt;/SPAN&gt;&lt;SPAN class="n"&gt;rowupdkey&lt;/SPAN&gt; &lt;SPAN class="o"&gt;=&lt;/SPAN&gt; &lt;SPAN class="n"&gt;d&lt;/SPAN&gt;&lt;SPAN class="p"&gt;.&lt;/SPAN&gt;&lt;SPAN class="n"&gt;rowupdkey&lt;/SPAN&gt;&lt;SPAN class="p"&gt;)&lt;/SPAN&gt; 
 &lt;SPAN class="k"&gt;INNER&lt;/SPAN&gt; &lt;SPAN class="k"&gt;JOIN&lt;/SPAN&gt; &lt;SPAN class="k"&gt;data&lt;/SPAN&gt;&lt;SPAN class="p"&gt;.&lt;/SPAN&gt;&lt;SPAN class="n"&gt;ind&lt;/SPAN&gt; &lt;SPAN class="k"&gt;AS&lt;/SPAN&gt; &lt;SPAN class="n"&gt;t&lt;/SPAN&gt; &lt;SPAN class="k"&gt;ON&lt;/SPAN&gt; &lt;SPAN class="n"&gt;t&lt;/SPAN&gt;&lt;SPAN class="p"&gt;.&lt;/SPAN&gt;&lt;SPAN class="n"&gt;indcopy&lt;/SPAN&gt; &lt;SPAN class="o"&gt;=&lt;/SPAN&gt; &lt;SPAN class="n"&gt;d&lt;/SPAN&gt;&lt;SPAN class="p"&gt;.&lt;/SPAN&gt;&lt;SPAN class="n"&gt;ind&lt;/SPAN&gt;
 &lt;SPAN class="k"&gt;ORDER&lt;/SPAN&gt; &lt;SPAN class="k"&gt;BY&lt;/SPAN&gt; &lt;SPAN class="n"&gt;t&lt;/SPAN&gt;&lt;SPAN class="p"&gt;.&lt;/SPAN&gt;&lt;SPAN class="n"&gt;ind&lt;/SPAN&gt;&lt;SPAN class="p"&gt;;&lt;/SPAN&gt;
&lt;/PRE&gt;&lt;/DIV&gt;</description>
      <pubDate>Thu, 02 Aug 2012 08:58:06 GMT</pubDate>
      <guid>https://community.sap.com/t5/technology-q-a/optimization-issue/qaq-p/13834243</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2012-08-02T08:58:06Z</dc:date>
    </item>
    <item>
      <title>Re: Optimization issue</title>
      <link>https://community.sap.com/t5/technology-q-a/optimization-issue/qaa-p/13834244#M4865087</link>
      <description>&lt;P&gt;Have a look at this &lt;A href="http://sqlanywhere-forum.sap.com/questions/8843/optimization-in-functions-and-procedures"&gt;Question&lt;/A&gt; - it may help.&lt;/P&gt;</description>
      <pubDate>Thu, 02 Aug 2012 09:30:57 GMT</pubDate>
      <guid>https://community.sap.com/t5/technology-q-a/optimization-issue/qaa-p/13834244#M4865087</guid>
      <dc:creator>justin_willey</dc:creator>
      <dc:date>2012-08-02T09:30:57Z</dc:date>
    </item>
    <item>
      <title>Re: Optimization issue</title>
      <link>https://community.sap.com/t5/technology-q-a/optimization-issue/qaa-p/13834247#M4865090</link>
      <description>&lt;P&gt;Thanks for the edit Mark.&lt;/P&gt;</description>
      <pubDate>Fri, 03 Aug 2012 08:58:28 GMT</pubDate>
      <guid>https://community.sap.com/t5/technology-q-a/optimization-issue/qaa-p/13834247#M4865090</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2012-08-03T08:58:28Z</dc:date>
    </item>
    <item>
      <title>Re: Optimization issue</title>
      <link>https://community.sap.com/t5/technology-q-a/optimization-issue/qaa-p/13834248#M4865091</link>
      <description>&lt;P&gt;Thanks to Justin for the edit too.&lt;/P&gt;</description>
      <pubDate>Fri, 03 Aug 2012 09:02:20 GMT</pubDate>
      <guid>https://community.sap.com/t5/technology-q-a/optimization-issue/qaa-p/13834248#M4865091</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2012-08-03T09:02:20Z</dc:date>
    </item>
    <item>
      <title>Re: Optimization issue</title>
      <link>https://community.sap.com/t5/technology-q-a/optimization-issue/qaa-p/13834245#M4865088</link>
      <description>&lt;P&gt;In general, 'local predicates' are pushed on the table scans. In your example, the execution plan should have, in both examples, a scan on 'd'  with a local scan  predicate 'MOD(d.ind, 10) = 0'
as this predicate refers only to the table 'd'.&lt;/P&gt;
&lt;P&gt;Please note that your two statements are equivalent and the optimizer would rewrite them in a normal form before the query optimization process as:&lt;/P&gt;
&lt;DIV class="codehilite"&gt;&lt;PRE&gt;&lt;SPAN class="n"&gt;UPDATE&lt;/SPAN&gt; &lt;SPAN class="n"&gt;data&lt;/SPAN&gt;&lt;SPAN class="o"&gt;.&lt;/SPAN&gt;&lt;SPAN class="n"&gt;ind&lt;/SPAN&gt; &lt;SPAN class="n"&gt;AS&lt;/SPAN&gt; &lt;SPAN class="n"&gt;t&lt;/SPAN&gt;
   &lt;SPAN class="n"&gt;SET&lt;/SPAN&gt; &lt;SPAN class="n"&gt;t&lt;/SPAN&gt;&lt;SPAN class="o"&gt;.&lt;/SPAN&gt;&lt;SPAN class="n"&gt;indcopy&lt;/SPAN&gt; &lt;SPAN class="o"&gt;=&lt;/SPAN&gt; &lt;SPAN class="n"&gt;f&lt;/SPAN&gt;&lt;SPAN class="o"&gt;.&lt;/SPAN&gt;&lt;SPAN class="n"&gt;ind&lt;/SPAN&gt;
  &lt;SPAN class="n"&gt;FROM&lt;/SPAN&gt; &lt;SPAN class="n"&gt;deleted&lt;/SPAN&gt; &lt;SPAN class="n"&gt;AS&lt;/SPAN&gt; &lt;SPAN class="n"&gt;d&lt;/SPAN&gt;&lt;SPAN class="p"&gt;,&lt;/SPAN&gt;  &lt;SPAN class="n"&gt;data&lt;/SPAN&gt;&lt;SPAN class="o"&gt;.&lt;/SPAN&gt;&lt;SPAN class="n"&gt;ind&lt;/SPAN&gt; &lt;SPAN class="n"&gt;AS&lt;/SPAN&gt; &lt;SPAN class="n"&gt;f&lt;/SPAN&gt;&lt;SPAN class="p"&gt;,&lt;/SPAN&gt;  &lt;SPAN class="n"&gt;data&lt;/SPAN&gt;&lt;SPAN class="o"&gt;.&lt;/SPAN&gt;&lt;SPAN class="n"&gt;ind&lt;/SPAN&gt; &lt;SPAN class="n"&gt;AS&lt;/SPAN&gt; &lt;SPAN class="n"&gt;t&lt;/SPAN&gt; 
 &lt;SPAN class="n"&gt;WHERE&lt;/SPAN&gt; &lt;SPAN class="n"&gt;f&lt;/SPAN&gt;&lt;SPAN class="o"&gt;.&lt;/SPAN&gt;&lt;SPAN class="n"&gt;rowupdkey&lt;/SPAN&gt; &lt;SPAN class="o"&gt;=&lt;/SPAN&gt; &lt;SPAN class="n"&gt;d&lt;/SPAN&gt;&lt;SPAN class="o"&gt;.&lt;/SPAN&gt;&lt;SPAN class="n"&gt;rowupdkey&lt;/SPAN&gt; 
   &lt;SPAN class="ow"&gt;and&lt;/SPAN&gt; &lt;SPAN class="n"&gt;t&lt;/SPAN&gt;&lt;SPAN class="o"&gt;.&lt;/SPAN&gt;&lt;SPAN class="n"&gt;indcopy&lt;/SPAN&gt; &lt;SPAN class="o"&gt;=&lt;/SPAN&gt; &lt;SPAN class="n"&gt;d&lt;/SPAN&gt;&lt;SPAN class="o"&gt;.&lt;/SPAN&gt;&lt;SPAN class="n"&gt;ind&lt;/SPAN&gt;
   &lt;SPAN class="ow"&gt;and&lt;/SPAN&gt; &lt;SPAN class="n"&gt;MOD&lt;/SPAN&gt;&lt;SPAN class="p"&gt;(&lt;/SPAN&gt;&lt;SPAN class="n"&gt;d&lt;/SPAN&gt;&lt;SPAN class="o"&gt;.&lt;/SPAN&gt;&lt;SPAN class="n"&gt;ind&lt;/SPAN&gt;&lt;SPAN class="p"&gt;,&lt;/SPAN&gt; &lt;SPAN class="mi"&gt;10&lt;/SPAN&gt;&lt;SPAN class="p"&gt;)&lt;/SPAN&gt; &lt;SPAN class="o"&gt;=&lt;/SPAN&gt; &lt;SPAN class="mi"&gt;0&lt;/SPAN&gt;
 &lt;SPAN class="n"&gt;ORDER&lt;/SPAN&gt; &lt;SPAN class="n"&gt;BY&lt;/SPAN&gt; &lt;SPAN class="n"&gt;t&lt;/SPAN&gt;&lt;SPAN class="o"&gt;.&lt;/SPAN&gt;&lt;SPAN class="n"&gt;ind&lt;/SPAN&gt;&lt;SPAN class="p"&gt;;&lt;/SPAN&gt;
&lt;/PRE&gt;&lt;/DIV&gt;</description>
      <pubDate>Fri, 03 Aug 2012 10:24:34 GMT</pubDate>
      <guid>https://community.sap.com/t5/technology-q-a/optimization-issue/qaa-p/13834245#M4865088</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2012-08-03T10:24:34Z</dc:date>
    </item>
    <item>
      <title>Re: Optimization issue</title>
      <link>https://community.sap.com/t5/technology-q-a/optimization-issue/qaa-p/13834246#M4865089</link>
      <description>&lt;P&gt;Please post the long plans (i.e., select plan('&amp;lt;statement&amp;gt;') ) or graphical plans (i.e., use dbisql.exe and save the graphical plans in 'Plan Viewer') for your statements.&lt;/P&gt;</description>
      <pubDate>Fri, 03 Aug 2012 10:34:48 GMT</pubDate>
      <guid>https://community.sap.com/t5/technology-q-a/optimization-issue/qaa-p/13834246#M4865089</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2012-08-03T10:34:48Z</dc:date>
    </item>
    <item>
      <title>Re: Optimization issue</title>
      <link>https://community.sap.com/t5/technology-q-a/optimization-issue/qaa-p/13834249#M4865092</link>
      <description>&lt;P&gt;&lt;A href="https://sqlanywhere-forum.sap.com/users/236/pasha19/"&gt;@pasha19&lt;/A&gt;: See &lt;A href="http://sqlanywhere.blogspot.ca/2009/10/how-to-capture-graphical-plan.html"&gt;How To Capture A Graphical Plan&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 03 Aug 2012 11:43:00 GMT</pubDate>
      <guid>https://community.sap.com/t5/technology-q-a/optimization-issue/qaa-p/13834249#M4865092</guid>
      <dc:creator>Breck_Carter</dc:creator>
      <dc:date>2012-08-03T11:43:00Z</dc:date>
    </item>
    <item>
      <title>Re: Optimization issue</title>
      <link>https://community.sap.com/t5/technology-q-a/optimization-issue/qaa-p/13834250#M4865093</link>
      <description>&lt;P&gt;I have encountered this several times -- this statement operates within a trigger.  I would love to see a query plan eliminating the need to ask these questions.  I'm not sure you can get a query plan for a SQL statement operating in a trigger.  Thanks I have bookmarked the page for future reference when dealing with non-trigger SQL statements.&lt;/P&gt;</description>
      <pubDate>Sat, 04 Aug 2012 07:41:02 GMT</pubDate>
      <guid>https://community.sap.com/t5/technology-q-a/optimization-issue/qaa-p/13834250#M4865093</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2012-08-04T07:41:02Z</dc:date>
    </item>
    <item>
      <title>Re: Optimization issue</title>
      <link>https://community.sap.com/t5/technology-q-a/optimization-issue/qaa-p/13834251#M4865094</link>
      <description>&lt;P&gt;Thanks for the info.&lt;/P&gt;</description>
      <pubDate>Sat, 04 Aug 2012 07:42:14 GMT</pubDate>
      <guid>https://community.sap.com/t5/technology-q-a/optimization-issue/qaa-p/13834251#M4865094</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2012-08-04T07:42:14Z</dc:date>
    </item>
    <item>
      <title>Re: Optimization issue</title>
      <link>https://community.sap.com/t5/technology-q-a/optimization-issue/qaa-p/13834252#M4865095</link>
      <description>&lt;P&gt;See &lt;A href="http://sqlanywhere.blogspot.ca/2011/05/database-tracing-in-50-easy-steps.html"&gt;Database Tracing In 50 Easy Steps&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Sat, 04 Aug 2012 08:29:24 GMT</pubDate>
      <guid>https://community.sap.com/t5/technology-q-a/optimization-issue/qaa-p/13834252#M4865095</guid>
      <dc:creator>Breck_Carter</dc:creator>
      <dc:date>2012-08-04T08:29:24Z</dc:date>
    </item>
    <item>
      <title>Re: Optimization issue</title>
      <link>https://community.sap.com/t5/technology-q-a/optimization-issue/qaa-p/13834253#M4865096</link>
      <description>&lt;P&gt;Thanks again -- I'm investigating the option.&lt;/P&gt;</description>
      <pubDate>Sat, 04 Aug 2012 08:42:13 GMT</pubDate>
      <guid>https://community.sap.com/t5/technology-q-a/optimization-issue/qaa-p/13834253#M4865096</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2012-08-04T08:42:13Z</dc:date>
    </item>
    <item>
      <title>Re: Optimization issue</title>
      <link>https://community.sap.com/t5/technology-q-a/optimization-issue/qaa-p/13834254#M4865097</link>
      <description>&lt;P&gt;I got it working it was not trivial and there were a few exceptions under V12 one was mine I have an AES256 encrypted database. -- Thanks&lt;/P&gt;</description>
      <pubDate>Mon, 06 Aug 2012 01:27:48 GMT</pubDate>
      <guid>https://community.sap.com/t5/technology-q-a/optimization-issue/qaa-p/13834254#M4865097</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2012-08-06T01:27:48Z</dc:date>
    </item>
    <item>
      <title>Re: Optimization issue</title>
      <link>https://community.sap.com/t5/technology-q-a/optimization-issue/qaa-p/13834255#M4865098</link>
      <description>&lt;P&gt;Thanks Nica_SAP I believe now that I can get query plans for sql in triggers I should be able to solve this and other problems when I encounter them.&lt;/P&gt;</description>
      <pubDate>Mon, 06 Aug 2012 02:36:45 GMT</pubDate>
      <guid>https://community.sap.com/t5/technology-q-a/optimization-issue/qaa-p/13834255#M4865098</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2012-08-06T02:36:45Z</dc:date>
    </item>
    <item>
      <title>Re: Optimization issue</title>
      <link>https://community.sap.com/t5/technology-q-a/optimization-issue/qaa-p/13834256#M4865099</link>
      <description>&lt;P&gt;To view plans for statements in triggers (or any statement actually), enable request logging with SQL+PLAN This can be done via the server command line with the option "-zr SQL+PLAN", or call the system procedure sa_server_option( 'RequestLogging','SQL+PLAN'). The server will output this to the server messages window, but it can be captured using the command line option "-zo filename, or call sa_server_option( 'RequestLogFile','filename'). This will dump the short plan for each query.&lt;/P&gt;
&lt;P&gt;If the graphical plan is required, use Application Profiling. The easiest way to do this is to use the Application Profiling wizard. It is explained the the documentation here:
SQL Anywhere Server - SQL Usage
  Monitoring and improving database performance
    Improving database performance
      Application profiling
Application Prifiling Wizard&lt;/P&gt;</description>
      <pubDate>Tue, 07 Aug 2012 13:44:17 GMT</pubDate>
      <guid>https://community.sap.com/t5/technology-q-a/optimization-issue/qaa-p/13834256#M4865099</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2012-08-07T13:44:17Z</dc:date>
    </item>
  </channel>
</rss>

