<?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: Documentation for searchV2(String query) how to type a query ? in Dropbox API Support &amp; Feedback</title>
    <link>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Documentation-for-searchV2-String-query-how-to-type-a-query/m-p/392859#M21665</link>
    <description>&lt;P&gt;Thanks Greg. It did the trick.&lt;/P&gt;</description>
    <pubDate>Tue, 28 Jan 2020 07:44:44 GMT</pubDate>
    <dc:creator>CCra</dc:creator>
    <dc:date>2020-01-28T07:44:44Z</dc:date>
    <item>
      <title>Documentation for searchV2(String query) how to type a query ?</title>
      <link>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Documentation-for-searchV2-String-query-how-to-type-a-query/m-p/392521#M21657</link>
      <description>&lt;P&gt;I have been using older dropboxapiv2 (java) to search "Files" for 2 years. Today it started to malfunction due to a dropbox server side "malformed query" error. While I assume it is again a Dropbox development malfunction, I also would like to upgrade the dropboxapiv2 I am using to version 3.1.3 . It seems there is now a search method searchV2(String query) ,but I could not find any documentation about how to write a search query for dropbox search in api.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Can anybody help ?&lt;/P&gt;
&lt;P&gt;with errors below is my code for, now deprecated, search method&lt;/P&gt;
&lt;PRE&gt;public List&amp;lt;SearchMatch&amp;gt; findFile(String code) {
	try {
		SearchResult sr = dbxClient.files().search("/drawings/",code);
		List&amp;lt;SearchMatch&amp;gt; sm = sr.getMatches();
		List&amp;lt;SearchMatch&amp;gt; rmlist = new ArrayList&amp;lt;SearchMatch&amp;gt;();
		for (SearchMatch searchMatch : sm) {
			if (!fileMidir(searchMatch.getMetadata())) {
				rmlist.add(searchMatch);
			}
		}
		for (SearchMatch searchMatch : rmlist) {
			sm.remove(searchMatch);
		}
		
		return sm;
		
	} catch (DbxException e) {
		e.printStackTrace();
	}
	return null;
}
public boolean fileMidir(Metadata metadata){
	if (metadata instanceof FolderMetadata) {
		return false;
	}else {
		return true;
	}
}&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 27 Jan 2020 11:18:56 GMT</pubDate>
      <guid>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Documentation-for-searchV2-String-query-how-to-type-a-query/m-p/392521#M21657</guid>
      <dc:creator>CCra</dc:creator>
      <dc:date>2020-01-27T11:18:56Z</dc:date>
    </item>
    <item>
      <title>Re: Documentation for searchV2(String query) how to type a query ?</title>
      <link>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Documentation-for-searchV2-String-query-how-to-type-a-query/m-p/392540#M21659</link>
      <description>&lt;P&gt;BTW, the error is old path name for search "/drawings/" now should be "/drawings". If anybody can help me with searchV2 -how to write a query- (for path specifying and other options), I would appreciate it very much.&lt;/P&gt;</description>
      <pubDate>Mon, 27 Jan 2020 10:21:49 GMT</pubDate>
      <guid>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Documentation-for-searchV2-String-query-how-to-type-a-query/m-p/392540#M21659</guid>
      <dc:creator>CCra</dc:creator>
      <dc:date>2020-01-27T10:21:49Z</dc:date>
    </item>
    <item>
      <title>Re: Documentation for searchV2(String query) how to type a query ?</title>
      <link>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Documentation-for-searchV2-String-query-how-to-type-a-query/m-p/392679#M21664</link>
      <description>&lt;P&gt;To use the new search method in the Java SDK, you can start by supplying your "query", which is the string you want to search for, to the&amp;nbsp;&lt;A href="https://dropbox.github.io/dropbox-sdk-java/api-docs/v3.1.x/com/dropbox/core/v2/files/DbxUserFilesRequests.html#searchV2Builder-java.lang.String-" target="_self"&gt;searchV2Builder&lt;/A&gt; method to get a&amp;nbsp;&lt;A href="https://dropbox.github.io/dropbox-sdk-java/api-docs/v3.1.x/com/dropbox/core/v2/files/SearchV2Builder.html" target="_self"&gt;SearchV2Builder&lt;/A&gt;.&lt;/P&gt;
&lt;P&gt;Then you can use the&amp;nbsp;&lt;A href="https://dropbox.github.io/dropbox-sdk-java/api-docs/v3.1.x/com/dropbox/core/v2/files/SearchV2Builder.html#withOptions-com.dropbox.core.v2.files.SearchOptions-" target="_self"&gt;SearchV2Builder.withOptions&lt;/A&gt;&amp;nbsp;method to add other optional settings, such as the path to search in, by passing it a&amp;nbsp;&lt;A href="https://dropbox.github.io/dropbox-sdk-java/api-docs/v3.1.x/com/dropbox/core/v2/files/SearchOptions.html" target="_self"&gt;SearchOptions&lt;/A&gt; object.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Then you can use&amp;nbsp;&lt;A href="https://dropbox.github.io/dropbox-sdk-java/api-docs/v3.1.x/com/dropbox/core/v2/files/SearchV2Builder.html#start--" target="_self"&gt;SearchV2Builder.start&lt;/A&gt; to perform the search.&lt;/P&gt;</description>
      <pubDate>Mon, 27 Jan 2020 17:03:20 GMT</pubDate>
      <guid>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Documentation-for-searchV2-String-query-how-to-type-a-query/m-p/392679#M21664</guid>
      <dc:creator>Greg-DB</dc:creator>
      <dc:date>2020-01-27T17:03:20Z</dc:date>
    </item>
    <item>
      <title>Re: Documentation for searchV2(String query) how to type a query ?</title>
      <link>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Documentation-for-searchV2-String-query-how-to-type-a-query/m-p/392859#M21665</link>
      <description>&lt;P&gt;Thanks Greg. It did the trick.&lt;/P&gt;</description>
      <pubDate>Tue, 28 Jan 2020 07:44:44 GMT</pubDate>
      <guid>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Documentation-for-searchV2-String-query-how-to-type-a-query/m-p/392859#M21665</guid>
      <dc:creator>CCra</dc:creator>
      <dc:date>2020-01-28T07:44:44Z</dc:date>
    </item>
  </channel>
</rss>

