<?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 Search by TEXT with Lucene in Alfresco Archive</title>
    <link>https://connect.hyland.com/t5/alfresco-archive/search-by-text-with-lucene/m-p/252023#M205153</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Hi,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I have implemented with Java and Alfresco's Api some methods to upload files.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;When I search by text (TEXT:\"text") in pdf files there are no problem. But when I search in txt files, Alfresco don't give me results. I search it with the web client, and with the node browser too, but the search with txt files don't work. The only difference between the pdf and the txt files is the content type: application/pdf vs. plain/text&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Anyone knows what's the problem? The search works different with txt and pdf files? When I upload a txt file with the alfresco api, the search works. This problem only occurs when I upload the txt with my methods. But the pdf works! And are the same methods. I don't understand &lt;img id="smileysurprised" class="emoticon emoticon-smileysurprised" src="https://connect.hyland.com/i/smilies/16x16_smiley-surprised.png" alt="Smiley Surprised" title="Smiley Surprised" /&gt;(&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I put here the most important metadata of both files. First, uploading with alfresco web client. The second with my methods.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;{&lt;/SPAN&gt;&lt;A href="http://www.alfresco.org/model/content/1.0}name" rel="nofollow noopener noreferrer"&gt;http://www.alfresco.org/model/content/1.0}name&lt;/A&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;expediente 2.txt&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;{&lt;/SPAN&gt;&lt;A href="http://www.alfresco.org/model/system/1.0}node-dbid" rel="nofollow noopener noreferrer"&gt;http://www.alfresco.org/model/system/1.0}node-dbid&lt;/A&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;1953&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;{&lt;/SPAN&gt;&lt;A href="http://www.alfresco.org/model/system/1.0}store-identifier" rel="nofollow noopener noreferrer"&gt;http://www.alfresco.org/model/system/1.0}store-identifier&lt;/A&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;SpacesStore&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;{&lt;/SPAN&gt;&lt;A href="http://www.alfresco.org/model/system/1.0}node-uuid" rel="nofollow noopener noreferrer"&gt;http://www.alfresco.org/model/system/1.0}node-uuid&lt;/A&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;c7dae1de-1231-4b66-9e52-2e15739215d0&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;{&lt;/SPAN&gt;&lt;A href="http://www.alfresco.org/model/content/1.0}content" rel="nofollow noopener noreferrer"&gt;http://www.alfresco.org/model/content/1.0}content&lt;/A&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; contentUrl=store://2010/11/8/18/56/9862e934-e320-4748-a139-ae3a9bcf4c16.bin|mimetype=text/plain|size=44|encoding=UTF-8|locale=en_US_&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;{&lt;/SPAN&gt;&lt;A href="http://www.alfresco.org/model/content/1.0}title" rel="nofollow noopener noreferrer"&gt;http://www.alfresco.org/model/content/1.0}title&lt;/A&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;expediente 2.txt&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;{&lt;/SPAN&gt;&lt;A href="http://www.alfresco.org/model/system/1.0}store-protocol" rel="nofollow noopener noreferrer"&gt;http://www.alfresco.org/model/system/1.0}store-protocol&lt;/A&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;workspace&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;———-&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;{&lt;/SPAN&gt;&lt;A href="http://www.alfresco.org/model/content/1.0}name" rel="nofollow noopener noreferrer"&gt;http://www.alfresco.org/model/content/1.0}name&lt;/A&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;UDS B2.txt&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;{&lt;/SPAN&gt;&lt;A href="http://www.alfresco.org/model/system/1.0}node-dbid" rel="nofollow noopener noreferrer"&gt;http://www.alfresco.org/model/system/1.0}node-dbid&lt;/A&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;1954&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;{&lt;/SPAN&gt;&lt;A href="http://www.alfresco.org/model/system/1.0}store-identifier" rel="nofollow noopener noreferrer"&gt;http://www.alfresco.org/model/system/1.0}store-identifier&lt;/A&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;SpacesStore&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;{&lt;/SPAN&gt;&lt;A href="http://www.alfresco.org/model/system/1.0}node-uuid" rel="nofollow noopener noreferrer"&gt;http://www.alfresco.org/model/system/1.0}node-uuid&lt;/A&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;ad5c00f1-1900-4c2c-b9c9-1e90e8eeabd0&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;{&lt;/SPAN&gt;&lt;A href="http://www.alfresco.org/model/content/1.0}content" rel="nofollow noopener noreferrer"&gt;http://www.alfresco.org/model/content/1.0}content&lt;/A&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; contentUrl=store://2010/11/8/19/4/2603c9f8-03a4-4710-9080-55ae67919b3a.bin|mimetype=text/plain|size=44|encoding=UTF-8|locale=es_ES_&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;{&lt;/SPAN&gt;&lt;A href="http://www.alfresco.org/model/system/1.0}store-protocol" rel="nofollow noopener noreferrer"&gt;http://www.alfresco.org/model/system/1.0}store-protocol&lt;/A&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;workspace&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;{&lt;/SPAN&gt;&lt;A href="http://www.alfresco.org/model/content/1.0}doc_extension" rel="nofollow noopener noreferrer"&gt;http://www.alfresco.org/model/content/1.0}doc_extension&lt;/A&gt;&lt;BR /&gt;&lt;SPAN&gt;{&lt;/SPAN&gt;&lt;A href="http://www.alfresco.org/model/content/1.0}doc_contentType" rel="nofollow noopener noreferrer"&gt;http://www.alfresco.org/model/content/1.0}doc_contentType&lt;/A&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;text/plain&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Thanks!&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 09 Nov 2010 08:32:03 GMT</pubDate>
    <dc:creator>spilby</dc:creator>
    <dc:date>2010-11-09T08:32:03Z</dc:date>
    <item>
      <title>Search by TEXT with Lucene</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/search-by-text-with-lucene/m-p/252023#M205153</link>
      <description>Hi,I have implemented with Java and Alfresco's Api some methods to upload files.When I search by text (TEXT:\"text") in pdf files there are no problem. But when I search in txt files, Alfresco don't give me results. I search it with the web client, and with the node browser too, but the search with</description>
      <pubDate>Tue, 09 Nov 2010 08:32:03 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/search-by-text-with-lucene/m-p/252023#M205153</guid>
      <dc:creator>spilby</dc:creator>
      <dc:date>2010-11-09T08:32:03Z</dc:date>
    </item>
    <item>
      <title>Re: Search by TEXT with Lucene</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/search-by-text-with-lucene/m-p/252024#M205154</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Hi,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;code for your method would be more helpful. So someone can find how do you do it or even to reproduce the problem on its own machine.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Thanks,&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;smicyk&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 09 Nov 2010 14:55:02 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/search-by-text-with-lucene/m-p/252024#M205154</guid>
      <dc:creator>smicyk</dc:creator>
      <dc:date>2010-11-09T14:55:02Z</dc:date>
    </item>
    <item>
      <title>Re: Search by TEXT with Lucene</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/search-by-text-with-lucene/m-p/252025#M205155</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Oks, here's my code:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;RepositoryServiceSoapBindingStub repositoryService = WebServiceFactory.getRepositoryService(); &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;String contentData = AlfrescoContentUtils.putContent(file, fileNameAlfresco);&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Reference ref = new Reference(store, cmFile.getId(), null);&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Predicate predicate = new Predicate(new Reference[] { ref }, null, null);&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;NamedValue[] fileProperties = AlfrescoServiceHelper.getFileNodeProperties(contentData, cmFile);&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;CMLUpdate update = new CMLUpdate(fileProperties, predicate, null);&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;CML cml = new CML();&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;cml.setUpdate(new CMLUpdate[] { update }); &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;UpdateResult[] updateResult = repositoryService.update(cml);&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;And this method:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;public static NamedValue[] getFileNodeProperties(String content, CMFile cmFile) {&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;ArrayList&amp;lt;NamedValue&amp;gt; propertiesArray = new ArrayList&amp;lt;NamedValue&amp;gt;();&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;propertiesArray.add(Utils.createNamedValue(Constants.PROP_CONTENT, content));&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;propertiesArray.add(Utils.createNamedValue(ArchivoConstants.DOC_EXTENSION, cmFile.getExtension()));&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;propertiesArray.add(Utils.createNamedValue("{&lt;/SPAN&gt;&lt;A href="http://www.alfresco.org/model/content/1.0}doc_contentType" rel="nofollow noopener noreferrer"&gt;http://www.alfresco.org/model/content/1.0}doc_contentType&lt;/A&gt;&lt;SPAN&gt;", cmFile.getContentType()));&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;propertiesArray.add(Utils.createNamedValue(Constants.PROP_NAME, cmFile.getName() + "." + cmFile.getExtension()));&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;NamedValue[] properties = new NamedValue[propertiesArray.size()];&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;return propertiesArray.toArray(properties);&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;}&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 10 Nov 2010 10:49:52 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/search-by-text-with-lucene/m-p/252025#M205155</guid>
      <dc:creator>spilby</dc:creator>
      <dc:date>2010-11-10T10:49:52Z</dc:date>
    </item>
    <item>
      <title>Re: Search by TEXT with Lucene</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/search-by-text-with-lucene/m-p/252026#M205156</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;As well as different mime types you also have one document in English and one in Spanish.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 10 Nov 2010 13:33:49 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/search-by-text-with-lucene/m-p/252026#M205156</guid>
      <dc:creator>mrogers</dc:creator>
      <dc:date>2010-11-10T13:33:49Z</dc:date>
    </item>
    <item>
      <title>Re: Search by TEXT with Lucene</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/search-by-text-with-lucene/m-p/252027#M205157</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;BLOCKQUOTE class="jive-quote"&gt;As well as different mime types you also have one document in English and one in Spanish.&lt;/BLOCKQUOTE&gt;&lt;BR /&gt;&lt;SPAN&gt;But if I search a word with international characters (for example, "hello"), why this search depends of language? Is possible? My problem is that I don't know how can I specify the language in my code, because I need to use the putContent webservice, and I can't find a NamedValue properties for the language. Anyone knows about this, please? &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;My code:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;EM&gt;&lt;BR /&gt;RepositoryServiceSoapBindingStub repositoryService = WebServiceFactory.getRepositoryService(); &lt;BR /&gt;&lt;BR /&gt;String contentData = AlfrescoContentUtils.putContent(file, fileNameAlfresco);&lt;BR /&gt;&lt;BR /&gt;Reference ref = new Reference(store, cmFile.getId(), null);&lt;BR /&gt;Predicate predicate = new Predicate(new Reference[] { ref }, null, null);&lt;BR /&gt;&lt;BR /&gt;NamedValue[] fileProperties = AlfrescoServiceHelper.getFileNodeProperties(contentData, cmFile);&lt;BR /&gt;&lt;BR /&gt;CMLUpdate update = new CMLUpdate(fileProperties, predicate, null);&lt;BR /&gt;CML cml = new CML();&lt;BR /&gt;cml.setUpdate(new CMLUpdate[] { update }); &lt;BR /&gt;&lt;BR /&gt;UpdateResult[] updateResult = repositoryService.update(cml);&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;And this method:&lt;BR /&gt;&lt;BR /&gt;public static NamedValue[] getFileNodeProperties(String content, CMFile cmFile) {&lt;BR /&gt;&lt;BR /&gt;ArrayList&amp;lt;NamedValue&amp;gt; propertiesArray = new ArrayList&amp;lt;NamedValue&amp;gt;();&lt;BR /&gt;&lt;BR /&gt;propertiesArray.add(Utils.createNamedValue(Constants.PROP_CONTENT, content));&lt;BR /&gt;propertiesArray.add(Utils.createNamedValue(ArchivoConstants.DOC_EXTENSION, cmFile.getExtension()));&lt;BR /&gt;propertiesArray.add(Utils.createNamedValue("{&lt;A href="http://www.alfresco.org/model/content/1.0}doc_contentType" rel="nofollow noopener noreferrer"&gt;http://www.alfresco.org/model/content/1.0}doc_contentType&lt;/A&gt;", cmFile.getContentType()));&lt;BR /&gt;propertiesArray.add(Utils.createNamedValue(Constants.PROP_NAME, cmFile.getName() + "." + cmFile.getExtension()));&lt;BR /&gt;&lt;BR /&gt;NamedValue[] properties = new NamedValue[propertiesArray.size()];&lt;BR /&gt;return propertiesArray.toArray(properties);&lt;BR /&gt;}&lt;/EM&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 18 Nov 2010 08:30:00 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/search-by-text-with-lucene/m-p/252027#M205157</guid>
      <dc:creator>spilby</dc:creator>
      <dc:date>2010-11-18T08:30:00Z</dc:date>
    </item>
    <item>
      <title>Re: Search by TEXT with Lucene</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/search-by-text-with-lucene/m-p/252028#M205158</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Thanks for the post. &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Hi guys, Im a newbie. Nice to join this forum.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 30 Nov 2010 02:05:09 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/search-by-text-with-lucene/m-p/252028#M205158</guid>
      <dc:creator>tracyk859</dc:creator>
      <dc:date>2010-11-30T02:05:09Z</dc:date>
    </item>
  </channel>
</rss>

