#1 Error when running certain examples

closed
nobody
None
5
2007-02-12
2007-02-10
1710573
No

C:\Documents and Settings\lidq3ee\Tim\mxquery-bin-0.2\examples>java -jar mxquery
.jar xqueryp.xq
Executing Query:
'(: DESCIPTION: Uses XQueryP to increment the price of each item of '$x' by 10%
and to add a comment. :)

declare execution sequential;
declare variable $x
:= <bib><item><price>1.45</price></item><item><price>2.32</price></item>
</bib>;
declare variable $index := 1;

<result>
{
while (exists($x/item[$index]))
return
{
declare $item := $x/item[$index];
do replace value of $item/price with $item/price*1.1;
do insert <info>price changed</info> into $item;
set $index := $index + 1;
$item
}
}</result>'
Exception in thread "main" java.lang.NoSuchMethodError: java.lang.String.contain
s(Ljava/lang/CharSequence;)Z
at ch.ethz.mxquery.model.MXQueryDateTime.<init>(Unknown Source)
at ch.ethz.mxquery.parser.Parser.isDateTime(Unknown Source)
at ch.ethz.mxquery.parser.Parser.ElementContentChars(Unknown Source)
at ch.ethz.mxquery.parser.Parser.DirElemContent(Unknown Source)
at ch.ethz.mxquery.parser.Parser.DirElemConstructor(Unknown Source)
at ch.ethz.mxquery.parser.Parser.DirectConstructor(Unknown Source)
at ch.ethz.mxquery.parser.Parser.Constructor(Unknown Source)
at ch.ethz.mxquery.parser.Parser.PrimaryExpr(Unknown Source)
at ch.ethz.mxquery.parser.Parser.FilterExpr(Unknown Source)
at ch.ethz.mxquery.parser.Parser.StepExpr(Unknown Source)
at ch.ethz.mxquery.parser.Parser.RelativePathExpr(Unknown Source)
at ch.ethz.mxquery.parser.Parser.PathExpr(Unknown Source)
at ch.ethz.mxquery.parser.Parser.ValueExpr(Unknown Source)
at ch.ethz.mxquery.parser.Parser.UnionExpr(Unknown Source)
at ch.ethz.mxquery.parser.Parser.MultiplicativeExpr(Unknown Source)
at ch.ethz.mxquery.parser.Parser.AdditiveExpr(Unknown Source)
at ch.ethz.mxquery.parser.Parser.RangeExpr(Unknown Source)
at ch.ethz.mxquery.parser.Parser.ComparisonExpr(Unknown Source)
at ch.ethz.mxquery.parser.Parser.AndExpr(Unknown Source)
at ch.ethz.mxquery.parser.Parser.OrExpr(Unknown Source)
at ch.ethz.mxquery.parser.Parser.ExprSingle(Unknown Source)
at ch.ethz.mxquery.parser.Parser.SourceExpr(Unknown Source)
at ch.ethz.mxquery.parser.Parser.InsertExpr(Unknown Source)
at ch.ethz.mxquery.parser.Parser.ExprSingle(Unknown Source)
at ch.ethz.mxquery.parser.Parser.Expr(Unknown Source)
at ch.ethz.mxquery.parser.Parser.SequentialExpr(Unknown Source)
at ch.ethz.mxquery.parser.Parser.BlockExpr(Unknown Source)
at ch.ethz.mxquery.parser.Parser.PrimaryExpr(Unknown Source)
at ch.ethz.mxquery.parser.Parser.FilterExpr(Unknown Source)
at ch.ethz.mxquery.parser.Parser.StepExpr(Unknown Source)
at ch.ethz.mxquery.parser.Parser.RelativePathExpr(Unknown Source)
at ch.ethz.mxquery.parser.Parser.PathExpr(Unknown Source)
at ch.ethz.mxquery.parser.Parser.ValueExpr(Unknown Source)
at ch.ethz.mxquery.parser.Parser.UnionExpr(Unknown Source)
at ch.ethz.mxquery.parser.Parser.MultiplicativeExpr(Unknown Source)
at ch.ethz.mxquery.parser.Parser.AdditiveExpr(Unknown Source)
at ch.ethz.mxquery.parser.Parser.RangeExpr(Unknown Source)
at ch.ethz.mxquery.parser.Parser.ComparisonExpr(Unknown Source)
at ch.ethz.mxquery.parser.Parser.AndExpr(Unknown Source)
at ch.ethz.mxquery.parser.Parser.OrExpr(Unknown Source)
at ch.ethz.mxquery.parser.Parser.ExprSingle(Unknown Source)
at ch.ethz.mxquery.parser.Parser.WhileExpr(Unknown Source)
at ch.ethz.mxquery.parser.Parser.ExprSingle(Unknown Source)
at ch.ethz.mxquery.parser.Parser.Expr(Unknown Source)
at ch.ethz.mxquery.parser.Parser.EnclosedExpr(Unknown Source)
at ch.ethz.mxquery.parser.Parser.CommonContent(Unknown Source)
at ch.ethz.mxquery.parser.Parser.DirElemContent(Unknown Source)
at ch.ethz.mxquery.parser.Parser.DirElemConstructor(Unknown Source)
at ch.ethz.mxquery.parser.Parser.DirectConstructor(Unknown Source)
at ch.ethz.mxquery.parser.Parser.Constructor(Unknown Source)
at ch.ethz.mxquery.parser.Parser.PrimaryExpr(Unknown Source)
at ch.ethz.mxquery.parser.Parser.FilterExpr(Unknown Source)
at ch.ethz.mxquery.parser.Parser.StepExpr(Unknown Source)
at ch.ethz.mxquery.parser.Parser.RelativePathExpr(Unknown Source)
at ch.ethz.mxquery.parser.Parser.PathExpr(Unknown Source)
at ch.ethz.mxquery.parser.Parser.ValueExpr(Unknown Source)
at ch.ethz.mxquery.parser.Parser.UnionExpr(Unknown Source)
at ch.ethz.mxquery.parser.Parser.MultiplicativeExpr(Unknown Source)
at ch.ethz.mxquery.parser.Parser.AdditiveExpr(Unknown Source)
at ch.ethz.mxquery.parser.Parser.RangeExpr(Unknown Source)
at ch.ethz.mxquery.parser.Parser.ComparisonExpr(Unknown Source)
at ch.ethz.mxquery.parser.Parser.AndExpr(Unknown Source)
at ch.ethz.mxquery.parser.Parser.OrExpr(Unknown Source)
at ch.ethz.mxquery.parser.Parser.ExprSingle(Unknown Source)
at ch.ethz.mxquery.parser.Parser.Expr(Unknown Source)
at ch.ethz.mxquery.parser.Parser.SequentialExpr(Unknown Source)
at ch.ethz.mxquery.parser.Parser.SequentialExpr(Unknown Source)
at ch.ethz.mxquery.parser.Parser.QueryBody(Unknown Source)
at ch.ethz.mxquery.parser.Parser.MainModule(Unknown Source)
at ch.ethz.mxquery.parser.Parser.Module(Unknown Source)
at ch.ethz.mxquery.parser.Parser.parse(Unknown Source)
at ch.ethz.mxquery.core.XQueryRuntime.prepareQuery(Unknown Source)
at ch.ethz.mxquery.example.MXQuery.prepareQuery(Unknown Source)
at ch.ethz.mxquery.example.MXQuery.main(Unknown Source)

C:\Documents and Settings\lidq3ee\Tim\mxquery-bin-0.2\examples>java -version
java version "1.4.2_05"
Java(TM) 2 Runtime Environment, Standard Edition (build 1.4.2_05-b04)
Java HotSpot(TM) Client VM (build 1.4.2_05-b04, mixed mode)

C:\Documents and Settings\lidq3ee\Tim\mxquery-bin-0.2\examples>

Discussion

  • Logged In: YES
    user_id=1641989
    Originator: NO

    Problem wass related to a Java 1.5 method. Released new version of mxquery (0.2.1) that fixes this problem

     
    • status: open --> closed