The Main.RecentChanges page is failing on myxwiki (apparently all subwikis) and
I was able to get some information out of it.
The problem can be isolated to the query in this snippet, it works on my local
wiki installation with postgres but fails on the incubator.
{{velocity}}
$xwiki.searchDocuments(", XWikiRCSNodeInfo as ni where doc.id=ni.id.docId and
ni.id.version2=1 group by doc.space, doc.name order by max(ni.date) desc", 1, 0)
{{/velocity}}
This is the generated hql query I got from the logs on my local machine where
the query succeeds.
select distinct doc.space, doc.name, max(ni.date) from
com.xpn.xwiki.doc.XWikiDocument as doc , com.xpn.xwiki.doc.rcs.XWikiRCSNodeInfo
as ni where (doc.hidden <> true or doc.hidden is null) and doc.id=ni.id.docId
and ni.id.version2=1 group by doc.space, doc.name order by max(ni.date) desc
here is the query from the error message from trying to run the above snippet
(or the RecentChanges page)
select distinct doc.space, doc.name, max(ni.date) from XWikiDocument as doc ,
XWikiRCSNodeInfo as ni where (doc.hidden <> true or doc.hidden is null) and
doc.id=ni.id.docId and ni.id.version2=1 group by doc.space, doc.name order by
max(ni.date) desc
They appear to be functionally identical, maybe the query is different from 2.1
and is disagreeing with the mysql version on myxwiki, or perhaps something is
just misconfigured. It doesn't seem like the db is corrupt since it happens on
multiple subwikis.
The bottom part of the stack trace.
Caused by: com.xpn.xwiki.XWikiException: Error number 3223 in 3: Exception
while searching documents with SQL [select distinct doc.space, doc.name,
max(ni.date) from XWikiDocument as doc , XWikiRCSNodeInfo as ni where
(doc.hidden <> true or doc.hidden is null) and doc.id=ni.id.docId and
ni.id.version2=1 group by doc.space, doc.name order by max(ni.date) desc]
Wrapped Exception: could not execute query
at
com.xpn.xwiki.store.XWikiHibernateStore.searchGenericInternal(XWikiHibernateStore.java:2470)
at
com.xpn.xwiki.store.XWikiHibernateStore.searchDocumentReferencesInternal(XWikiHibernateStore.java:2426)
at
com.xpn.xwiki.store.XWikiHibernateStore.searchDocumentsNamesInternal(XWikiHibernateStore.java:2413)
at
com.xpn.xwiki.store.XWikiHibernateStore.searchDocumentsNames(XWikiHibernateStore.java:2190)
at
com.xpn.xwiki.store.XWikiHibernateStore.searchDocumentsNames(XWikiHibernateStore.java:2169)
at
com.xpn.xwiki.store.XWikiCacheStore.searchDocumentsNames(XWikiCacheStore.java:373)
at com.xpn.xwiki.api.XWiki.searchDocuments(XWiki.java:491)
at sun.reflect.GeneratedMethodAccessor279.invoke(Unknown Source)
at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at
org.apache.velocity.util.introspection.UberspectImpl$VelMethodImpl.doInvoke(UberspectImpl.java:389)
at
org.apache.velocity.util.introspection.UberspectImpl$VelMethodImpl.invoke(UberspectImpl.java:378)
at
org.apache.velocity.runtime.parser.node.ASTMethod.execute(ASTMethod.java:270)
... 80 more
Can't be too careful.
Caleb
_______________________________________________
devs mailing list
[email protected]
http://lists.xwiki.org/mailman/listinfo/devs