[ 
https://issues.apache.org/jira/browse/SOLR-5804?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15085499#comment-15085499
 ] 

Andras Kalman commented on SOLR-5804:
-------------------------------------

Unfortunately this issue still exists in version 4.10.4. As a workaround you 
can use the xsl attribute of the XPathEntityProcessor's entity config with an 
xsl file, which strips the namespaces.

Description of the xsl attribute: 
https://wiki.apache.org/solr/DataImportHandler#Configuration_in_data-config.xml-1
Example of the xsl file: 
http://stackoverflow.com/questions/5268182/how-to-remove-namespaces-from-xml-using-xslt

> xpath with an namespace:attribute not working in XPathEntityProcessor
> ---------------------------------------------------------------------
>
>                 Key: SOLR-5804
>                 URL: https://issues.apache.org/jira/browse/SOLR-5804
>             Project: Solr
>          Issue Type: Improvement
>          Components: contrib - DataImportHandler
>    Affects Versions: 4.6
>            Reporter: Jan Mach
>              Labels: attributes, easytest, namespaces, xpath
>   Original Estimate: 3h
>  Remaining Estimate: 3h
>
> I would like to use attributes originaly with namespaces. E.g. i have two 
> main tags:
>    <dc:contributor xml:lang="cz">John Doe</dc:contributor>
>    <dc:contributor lang="en">Mark Tester</dc:contributor>
> Field definition, where I remove namespaces, is
>   <field column="attr_myTest" xpath="/metadata/contributor/@lang"/>
> The result of the extraction is (extracted only one attribute):
>   "attr_myTest": ["en"]
> but the expected result should be extracted all two attributes:
>   "attr_myTest": ["cz", "en"]
> I would like to ask you to implement a patch to be able to use attributes 
> with namespaces in original XML. For tag names removing namespaces works 
> fine. Thanks a lot!



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to