<?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 promote the performance on querying filegeodatabase entries count?? in File Geodatabase API Questions</title>
    <link>https://community.esri.com/t5/file-geodatabase-api-questions/how-to-promote-the-performance-on-querying/m-p/515592#M848</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;The problem is in the SQL query: it seems, there is no planer/optimiser in FileGDBApi. To execute the original SQL (&lt;SPAN style="background-color: #ffffff;"&gt;$"SELECT count(*) FROM&amp;nbsp;TableName&amp;nbsp;WHERE OBJECTID=1 or OBJECTID=2") takes 4466 ms on my table but to execute this one is only 16 ms on first run and 1 ms on second run:&amp;nbsp;"SELECT Count(*) FROM Original WHERE OBJECTID IN (1, 2);"&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="background-color: #ffffff;"&gt;The full code:&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="background-color: #ffffff;"&gt; RowCollection rows = GDB.ExecuteSQL("SELECT Count(*) FROM Original WHERE OBJECTID IN (1, 2);");&lt;BR /&gt; foreach (Row row in rows) // Just to be generic.&lt;BR /&gt; {&lt;BR /&gt; int i = (int)row.GetDouble(0);&lt;BR /&gt; }&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="background-color: #ffffff;"&gt;Ákos Halmai&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 23 Oct 2018 10:10:05 GMT</pubDate>
    <dc:creator>ÁkosHalmai</dc:creator>
    <dc:date>2018-10-23T10:10:05Z</dc:date>
    <item>
      <title>How to promote the performance on querying filegeodatabase entries count??</title>
      <link>https://community.esri.com/t5/file-geodatabase-api-questions/how-to-promote-the-performance-on-querying/m-p/515583#M839</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;SPAN style="background-color: #ffffff;"&gt;Hi,&amp;nbsp;I tried to getting the count of some filegeodatabase rows&amp;nbsp;with&amp;nbsp;"File Geodatabase API 1.4", but the performance is very poor as following statements:&lt;/SPAN&gt;&lt;/P&gt;&lt;TABLE class="j-table jiveBorder" style="border: 1px solid #c6c6c6;" width="100%"&gt;&lt;THEAD&gt;&lt;TR style="background-color: #efefef;"&gt;&lt;TH&gt;The Source code&lt;/TH&gt;&lt;/TR&gt;&lt;/THEAD&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD&gt;&lt;P style="background-color: #ffffff; border: 0px; padding: 0px;"&gt;Geodatabase geodatabase = Geodatabase.Open(@"xxxxxx");&lt;/P&gt;&lt;P style="background-color: #ffffff; border: 0px; padding: 0px;"&gt;var countStatements = $"SELECT count(*) FROM blk WHERE OBJECTID=1 or OBJECTID=2";&lt;BR /&gt;var countRows = geodatabase.ExecuteSQL(countStatements);&lt;/P&gt;&lt;P style="background-color: #ffffff; border: 0px; padding: 0px;"&gt;var countEnumerator = countRows.GetEnumerator();&lt;/P&gt;&lt;P style="background-color: #ffffff; border: 0px; padding: 0px;"&gt;if(countRows != null)&lt;BR /&gt;{&lt;BR /&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;countEnumerator.MoveNext();&lt;BR /&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;count = (int)countEnumerator.Current.GetDouble(0);&lt;BR /&gt;}&lt;/P&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P style="background-color: #ffffff; border: 0px;"&gt;&lt;SPAN style="border: 0px; font-weight: inherit; font-size: 11pt;"&gt;It took about two seconds to getting the result. The performance is very poor!&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="background-color: #ffffff; border: 0px;"&gt;How can I promote the performance through query sql statements or the other approach?&lt;/P&gt;&lt;P style="background-color: #ffffff; border: 0px;"&gt;I’m very appreciate for your any help.&lt;/P&gt;&lt;P style="background-color: #ffffff; border: 0px;"&gt;&amp;nbsp;&lt;/P&gt;&lt;P style="background-color: #ffffff; border: 0px;"&gt;Thanks,&lt;/P&gt;&lt;P style="background-color: #ffffff; border: 0px;"&gt;&lt;SPAN style="border: 0px; font-weight: inherit; font-size: 11pt;"&gt;Casper. Lee&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 25 May 2018 02:02:44 GMT</pubDate>
      <guid>https://community.esri.com/t5/file-geodatabase-api-questions/how-to-promote-the-performance-on-querying/m-p/515583#M839</guid>
      <dc:creator>Leelin</dc:creator>
      <dc:date>2018-05-25T02:02:44Z</dc:date>
    </item>
    <item>
      <title>Re: How to promote the performance on querying filegeodatabase entries count??</title>
      <link>https://community.esri.com/t5/file-geodatabase-api-questions/how-to-promote-the-performance-on-querying/m-p/515584#M840</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;You state that 2 seconds if very poor performance.&amp;nbsp; What are you comparing that against?&amp;nbsp; Have you run an SQL query against a similar data set using a different DBMS or API and seen sub-second response times?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;There are several factors that can influence the time it takes for a query to return results.&amp;nbsp; Since you are working with the File Geodatabase API, you are obviously working with file geodatabases, which means the performance of the underlying storage can influence the time.&amp;nbsp; Is your data local or on a network share?&amp;nbsp; If local, what kind of local drives are you using?&amp;nbsp; Was something else running in the background that was generating disk I/O when you queried?&amp;nbsp; If the data is on a network share, what kind of latency do you have connecting to the network file server?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I suspect part of what you are experiencing is the cost of setting up the connection to the geodatabase.&amp;nbsp; If you run the SQL successively without tearing down your connection and creating a new one, does it still take 2 seconds?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 25 May 2018 13:55:22 GMT</pubDate>
      <guid>https://community.esri.com/t5/file-geodatabase-api-questions/how-to-promote-the-performance-on-querying/m-p/515584#M840</guid>
      <dc:creator>JoshuaBixby</dc:creator>
      <dc:date>2018-05-25T13:55:22Z</dc:date>
    </item>
    <item>
      <title>Re: How to promote the performance on querying filegeodatabase entries count??</title>
      <link>https://community.esri.com/t5/file-geodatabase-api-questions/how-to-promote-the-performance-on-querying/m-p/515585#M841</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Joshua，&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks for your replying, I'm trying to query some features from a&amp;nbsp;,gdb&amp;nbsp;file, the .gdb file size is about 330M on local. I tried to run an SQL query on a .shp file (the size is about 430M), it takes about 980 milliseconds. On the .shp querying side, the querying tool is "OLEDB".&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I also confused on the querying behaviors:&lt;/P&gt;&lt;P&gt;1. Why does querying the count of features is very slow?&amp;nbsp;&lt;/P&gt;&lt;P&gt;2. The performance is very poor when the iteration of queried features is moved to the last.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;My computer environment:&lt;/P&gt;&lt;P&gt;OS: Win10 x64&lt;/P&gt;&lt;P&gt;Hardware:&lt;/P&gt;&lt;P&gt;CPU: i7 4700,&lt;/P&gt;&lt;P&gt;Memory: 16G,&lt;/P&gt;&lt;P&gt;Hard disk: SSD 512G.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: black;"&gt;I also tried to create a new FGDB and import the data into the new FGDB, but the performance is still poor. It still took about 2 seconds.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: black;"&gt;Thanks,&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: black;"&gt;Casper. Lee&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 28 May 2018 06:15:04 GMT</pubDate>
      <guid>https://community.esri.com/t5/file-geodatabase-api-questions/how-to-promote-the-performance-on-querying/m-p/515585#M841</guid>
      <dc:creator>Leelin</dc:creator>
      <dc:date>2018-05-28T06:15:04Z</dc:date>
    </item>
    <item>
      <title>Re: How to promote the performance on querying filegeodatabase entries count??</title>
      <link>https://community.esri.com/t5/file-geodatabase-api-questions/how-to-promote-the-performance-on-querying/m-p/515586#M842</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;You answered some of my questions, i.e., you are working with file geodatabases on local storage.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Have you had a chance to re-run the query without closing out your connection to see how much of your run time may be related to overhead in creating the connection itself.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;In terms of comparing sizes of data sets, size on disk is only one aspect.&amp;nbsp; One needs to look at numbers of records, numbers of fields, types of fields, etc....&amp;nbsp; For a query where you are only looking at a specific field, the number of records could be a bigger factor than overall size of the data set.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Also, have you tried modifying your query to not select all fields, e.g., "SELECT count(OBJECTID) FROM blk WHERE OBJECTID=1 or OBJECTID=2".&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 28 May 2018 19:40:21 GMT</pubDate>
      <guid>https://community.esri.com/t5/file-geodatabase-api-questions/how-to-promote-the-performance-on-querying/m-p/515586#M842</guid>
      <dc:creator>JoshuaBixby</dc:creator>
      <dc:date>2018-05-28T19:40:21Z</dc:date>
    </item>
    <item>
      <title>Re: How to promote the performance on querying filegeodatabase entries count??</title>
      <link>https://community.esri.com/t5/file-geodatabase-api-questions/how-to-promote-the-performance-on-querying/m-p/515587#M843</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Joshua,&lt;/P&gt;&lt;P&gt;Thanks for your suggestion. Unfortunately, the performance is still poor when I tried to run the querying more time base on a opened connection as following statements:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;TABLE class="j-table jiveBorder" style="border: 1px solid #c6c6c6;" width="100%"&gt;&lt;THEAD&gt;&lt;TR style="background-color: #efefef;"&gt;&lt;TH&gt;Source code&lt;/TH&gt;&lt;/TR&gt;&lt;/THEAD&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD&gt;Geodatabase geodatabase = Geodatabase.Open(@"C:\test\testData.gdb");&lt;BR /&gt;var countStatements = $"SELECT count(OBJECTID) FROM blk WHERE OBJECTID=1 or OBJECTID=2";&lt;BR /&gt;var countRows = geodatabase.ExecuteSQL(countStatements);&lt;BR /&gt;var count = 0;&lt;BR /&gt;var countEnumerator = countRows.GetEnumerator();&lt;BR /&gt;var stop = Stopwatch.StartNew();&lt;BR /&gt;for (int i = 0; i &amp;lt; 2; i++)&lt;BR /&gt;{&lt;BR /&gt; countEnumerator.MoveNext();&lt;BR /&gt; count = (int)countEnumerator.Current.GetDouble(0);&lt;BR /&gt; Console.WriteLine(stop.ElapsedMilliseconds / 1000);&lt;BR /&gt; countEnumerator.Reset();&lt;BR /&gt;}&lt;BR /&gt;stop.Stop();&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The test result shown: 2 seconds and 4 seconds. It seems like without any changes.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The test data information:&lt;/P&gt;&lt;P&gt;File size: 330M&lt;/P&gt;&lt;P&gt;Records count: 415000&lt;/P&gt;&lt;P&gt;Fields count: 37&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Do you have the other suggestion? I'm very appreciate for your any help.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Casper. Lee&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 29 May 2018 02:17:35 GMT</pubDate>
      <guid>https://community.esri.com/t5/file-geodatabase-api-questions/how-to-promote-the-performance-on-querying/m-p/515587#M843</guid>
      <dc:creator>Leelin</dc:creator>
      <dc:date>2018-05-29T02:17:35Z</dc:date>
    </item>
    <item>
      <title>Re: How to promote the performance on querying filegeodatabase entries count??</title>
      <link>https://community.esri.com/t5/file-geodatabase-api-questions/how-to-promote-the-performance-on-querying/m-p/515588#M844</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Looking at your code, it appears to be timing the iteration over the enumerator, not the performance of the SQL.&amp;nbsp; I understand that you are interested in the performance of the whole code block, but it might be good to understand how each sub-part is working.&amp;nbsp; &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;What do you get from the following code (&lt;EM&gt;I haven't tested, but I think you can get what I am after if it doesn't work as-is&lt;/EM&gt;&lt;span class="lia-unicode-emoji" title=":disappointed_face:"&gt;😞&lt;/span&gt;&lt;/P&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;&lt;CODE&gt;var countStatements = $"SELECT count(OBJECTID) FROM blk WHERE OBJECTID=1 or OBJECTID=2";

var stop = Stopwatch.StartNew();
Geodatabase geodatabase = Geodatabase.Open(@"C:\test\testData.gdb");
stop.Stop()
Console.WriteLine(stop.ElapsedMilliseconds / 1000);

var stop = Stopwatch.StartNew();
var countRows = geodatabase.ExecuteSQL(countStatements);
stop.Stop()
Console.WriteLine(stop.ElapsedMilliseconds / 1000);

var stop = Stopwatch.StartNew();
var count = 0;
var countEnumerator = countRows.GetEnumerator();
for (int i = 0; i &amp;lt; 2; i++)
{
countEnumerator.MoveNext();
count = (int)countEnumerator.Current.GetDouble(0);
stop.Stop();
Console.WriteLine(stop.ElapsedMilliseconds / 1000);
}
countEnumerator.Reset();

var stop = Stopwatch.StartNew();
var count = 0;
for (int i = 0; i &amp;lt; 2; i++)
{
countEnumerator.MoveNext();
count = (int)countEnumerator.Current.GetDouble(0);
stop.Stop();
Console.WriteLine(stop.ElapsedMilliseconds / 1000);
}
countEnumerator.Reset();&lt;SPAN class="line-numbers-rows"&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/CODE&gt;&lt;/PRE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 11 Dec 2021 22:31:11 GMT</pubDate>
      <guid>https://community.esri.com/t5/file-geodatabase-api-questions/how-to-promote-the-performance-on-querying/m-p/515588#M844</guid>
      <dc:creator>JoshuaBixby</dc:creator>
      <dc:date>2021-12-11T22:31:11Z</dc:date>
    </item>
    <item>
      <title>Re: How to promote the performance on querying filegeodatabase entries count??</title>
      <link>https://community.esri.com/t5/file-geodatabase-api-questions/how-to-promote-the-performance-on-querying/m-p/515589#M845</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Joshua,&lt;/P&gt;&lt;P&gt;Thanks for your further information. I have successful run your code. I think you want to find out the place where the performance is poor. The following items are the test result:&lt;/P&gt;&lt;P&gt;1.&amp;nbsp;&amp;nbsp;&lt;CODE style="border: 0px; font-weight: inherit;"&gt;Geodatabase.Open(@"C:\test\testData.gdb");&lt;/CODE&gt;&lt;/P&gt;&lt;P&gt;&lt;CODE style="border: 0px; font-weight: inherit;"&gt;It takes 12 milliseconds.&lt;/CODE&gt;&lt;/P&gt;&lt;P&gt;&lt;CODE style="border: 0px; font-weight: inherit;"&gt;&lt;/CODE&gt;&lt;/P&gt;&lt;P&gt;&lt;CODE style="border: 0px; font-weight: inherit;"&gt;2.&amp;nbsp;&lt;/CODE&gt;&lt;CODE style="border: 0px; font-weight: inherit;"&gt;geodatabase.ExecuteSQL(countStatements);&lt;/CODE&gt;&lt;/P&gt;&lt;P&gt;&lt;CODE style="border: 0px; font-weight: inherit;"&gt;It takes 0 millisecond.&lt;/CODE&gt;&lt;/P&gt;&lt;P&gt;&lt;CODE style="border: 0px; font-weight: inherit;"&gt;&lt;/CODE&gt;&lt;/P&gt;&lt;P&gt;&lt;CODE style="border: 0px; font-weight: inherit;"&gt;3. The first time:&lt;/CODE&gt;&lt;/P&gt;&lt;P&gt;&lt;CODE style="border: 0px; font-weight: inherit;"&gt;for (int i = 0; i &amp;lt; 1; i++)&lt;BR /&gt;{&lt;BR /&gt; countEnumerator.MoveNext();&lt;BR /&gt; count = (int)countEnumerator.Current.GetDouble(0);&lt;BR /&gt; stop.Stop();&lt;BR /&gt; Console.WriteLine(stop.ElapsedMilliseconds / 1000);&lt;BR /&gt;}&lt;BR /&gt;&lt;/CODE&gt;&lt;/P&gt;&lt;P&gt;&lt;CODE style="border: 0px; font-weight: inherit;"&gt;It takes 2 seconds.&lt;/CODE&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;4. The second time:&lt;/P&gt;&lt;P&gt;&lt;CODE style="border: 0px; font-weight: inherit;"&gt;for (int i = 0; i &amp;lt; 1; i++)&lt;BR /&gt;{&lt;BR /&gt;countEnumerator.MoveNext();&lt;BR /&gt;count = (int)countEnumerator.Current.GetDouble(0);&lt;BR /&gt;stop.Stop();&lt;BR /&gt;Console.WriteLine(stop.ElapsedMilliseconds / 1000);&lt;BR /&gt;}&lt;BR /&gt;&lt;/CODE&gt;&lt;/P&gt;&lt;P&gt;&lt;CODE style="border: 0px; font-weight: inherit;"&gt;It takes 2 seconds.&lt;/CODE&gt;&lt;/P&gt;&lt;P&gt;&lt;CODE style="border: 0px; font-weight: inherit;"&gt;&lt;/CODE&gt;&lt;/P&gt;&lt;P&gt;&lt;CODE style="border: 0px; font-weight: inherit;"&gt;Base on the test result, I guess the iteration of enumerator is the main reason. I haven't any idea to resolve it.&amp;nbsp;&lt;SPAN style="background-color: #ffffff;"&gt;Do you have the other suggestion? I'm very appreciate for your any help.&lt;/SPAN&gt;&lt;/CODE&gt;&lt;/P&gt;&lt;P&gt;&lt;CODE style="border: 0px; font-weight: inherit;"&gt;&lt;/CODE&gt;&lt;/P&gt;&lt;P&gt;&lt;CODE style="border: 0px; font-weight: inherit;"&gt;&lt;SPAN style="background-color: #ffffff;"&gt;Thanks,&lt;/SPAN&gt;&lt;/CODE&gt;&lt;/P&gt;&lt;P&gt;&lt;CODE style="border: 0px; font-weight: inherit;"&gt;&lt;SPAN style="background-color: #ffffff;"&gt;Casper. Lee&lt;/SPAN&gt;&lt;/CODE&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 30 May 2018 02:16:31 GMT</pubDate>
      <guid>https://community.esri.com/t5/file-geodatabase-api-questions/how-to-promote-the-performance-on-querying/m-p/515589#M845</guid>
      <dc:creator>Leelin</dc:creator>
      <dc:date>2018-05-30T02:16:31Z</dc:date>
    </item>
    <item>
      <title>Re: How to promote the performance on querying filegeodatabase entries count??</title>
      <link>https://community.esri.com/t5/file-geodatabase-api-questions/how-to-promote-the-performance-on-querying/m-p/515590#M846</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Unfortunately, I don't work with the FileGDB API very much, I usually interact with file geodatabases through ArcPy.&amp;nbsp; I wish I had some great suggestion at this point, but I don't.&amp;nbsp; Hopefully some Esri staff that work on FileGDB API development see this and chime in.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 30 May 2018 13:58:34 GMT</pubDate>
      <guid>https://community.esri.com/t5/file-geodatabase-api-questions/how-to-promote-the-performance-on-querying/m-p/515590#M846</guid>
      <dc:creator>JoshuaBixby</dc:creator>
      <dc:date>2018-05-30T13:58:34Z</dc:date>
    </item>
    <item>
      <title>Re: How to promote the performance on querying filegeodatabase entries count??</title>
      <link>https://community.esri.com/t5/file-geodatabase-api-questions/how-to-promote-the-performance-on-querying/m-p/515591#M847</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Joshua,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thank you very much. Your suggestion help me to test File GeoDatabase reading/writing performance. I have opened another question to find other answers.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Casper. Lee&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 31 May 2018 02:57:09 GMT</pubDate>
      <guid>https://community.esri.com/t5/file-geodatabase-api-questions/how-to-promote-the-performance-on-querying/m-p/515591#M847</guid>
      <dc:creator>Leelin</dc:creator>
      <dc:date>2018-05-31T02:57:09Z</dc:date>
    </item>
    <item>
      <title>Re: How to promote the performance on querying filegeodatabase entries count??</title>
      <link>https://community.esri.com/t5/file-geodatabase-api-questions/how-to-promote-the-performance-on-querying/m-p/515592#M848</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;The problem is in the SQL query: it seems, there is no planer/optimiser in FileGDBApi. To execute the original SQL (&lt;SPAN style="background-color: #ffffff;"&gt;$"SELECT count(*) FROM&amp;nbsp;TableName&amp;nbsp;WHERE OBJECTID=1 or OBJECTID=2") takes 4466 ms on my table but to execute this one is only 16 ms on first run and 1 ms on second run:&amp;nbsp;"SELECT Count(*) FROM Original WHERE OBJECTID IN (1, 2);"&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="background-color: #ffffff;"&gt;The full code:&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="background-color: #ffffff;"&gt; RowCollection rows = GDB.ExecuteSQL("SELECT Count(*) FROM Original WHERE OBJECTID IN (1, 2);");&lt;BR /&gt; foreach (Row row in rows) // Just to be generic.&lt;BR /&gt; {&lt;BR /&gt; int i = (int)row.GetDouble(0);&lt;BR /&gt; }&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="background-color: #ffffff;"&gt;Ákos Halmai&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 23 Oct 2018 10:10:05 GMT</pubDate>
      <guid>https://community.esri.com/t5/file-geodatabase-api-questions/how-to-promote-the-performance-on-querying/m-p/515592#M848</guid>
      <dc:creator>ÁkosHalmai</dc:creator>
      <dc:date>2018-10-23T10:10:05Z</dc:date>
    </item>
  </channel>
</rss>

