小编Pan*_*kaj的帖子

在Xquery中分组和计数

听到的是XML.我想获得冠军的次数由出版作家的日期范围15/02/2012到24/02/2012顺序由最高到最低(数字标题).

<entries>
<entry>
    <id>1</id>
    <published>23/02/2012</published>
    <title>Title 1</title>
    <content type="html">This is title one</content>
    <author>
        <name>Pankaj</name>
    </author>
</entry>
<entry>
    <id>2</id>
    <published>22/02/2012</published>
    <title>Title 2</title>
    <content type="html">This is title two</content>
    <author>
        <name>Pankaj</name>
    </author>
</entry>
<entry>
    <id>3</id>
    <published>21/02/2012</published>
    <title>Title 3</title>
    <content type="html">This is title three</content>
    <author>
        <name>Rob</name>
    </author>
</entry>
<entry>
    <id>4</id>
    <published>20/02/2012</published>
    <title>Title 4</title>
    <content type="html">This is title four</content>
    <author>
        <name>Bob</name>
    </author>
</entry>
<entry>
    <id>5</id>
    <published>19/02/2012</published>
    <title>Title 1</title>
    <content type="html">This is title five</content>
    <author>
        <name>Pankaj</name>
    </author>
</entry>
Run Code Online (Sandbox Code Playgroud)

我试图从xquery获取输出:

<?xml …
Run Code Online (Sandbox Code Playgroud)

xquery marklogic

6
推荐指数
1
解决办法
3780
查看次数

在Marlogic中存储XML数据的最佳方式

我是Marklogic世界的新手.我的程序使用自定义Java应用程序每30秒查询一次Further.com获取XML数据源.结果以XML格式返回.Java应用程序使用XCC API(Marklogic API)将检索到的数据插入到单个XML文件中的ML中.数据大小每分钟6 MB,如果应用程序运行一天左右,数据量将以GB为单位增长.我不知道我需要做任何管理配置才能将大量数据放入MarkLogic中的单个XML文件中.有人可以验证我的方法,或建议我是否必须在管理员级别进行任何配置更改.XML的结构如下......

<?xml version="1.0" encoding="UTF-8"?>      
<moreovercontentdump>        
<article id="_6232903453">           
<description></description>
<author></author>       
<source_category>Local</source_category>    
<genre>General</genre>  
<publisher></publisher> 
<media_type>text</media_type>   
<docurl>http://www.ilrestodelcarlino.it</docurl>    
<harvest_time>Apr  4 2012  4:28PM</harvest_time>    
<valid_time>May 14 2012  4:27PM</valid_time>    
</article>
<article id="_6232903453">           
<description></description>
<author></author>       
<source_category>Local</source_category>    
<genre>General</genre>  
<publisher></publisher> 
<media_type>text</media_type>   
<docurl>http://www.ilrestodelcarlino.it</docurl>    
<harvest_time>Apr  4 2012  4:28PM</harvest_time>    
<valid_time>May 14 2012  4:27PM</valid_time>    
</article>
<article id="_6232903453">           
<description></description>
<author></author>       
<source_category>Local</source_category>    
<genre>General</genre>  
<publisher></publisher> 
<media_type>text</media_type>   
<docurl>http://www.ilrestodelcarlino.it</docurl>    
<harvest_time>Apr  4 2012  4:28PM</harvest_time>    
<valid_time>May 14 2012  4:27PM</valid_time>    
</article>
</moreovercontentdump>        
Run Code Online (Sandbox Code Playgroud)

marklogic

3
推荐指数
1
解决办法
286
查看次数

标签 统计

marklogic ×2

xquery ×1