Java.lang.ArrayIndexOutOfBoundsException

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

Java.lang.ArrayIndexOutOfBoundsException

Nicolas F.
Administrator
Hello

OrbisGis 4.0 raise an error when I run the following SQL command :

create table secondary_roads_with_traffic as select secondary_roads_with_areaid.the_geom,flux_zones.num_zone,(flux_zones.vl/area_roads_count.roadcpt) as vl,
(flux_zones.pl/area_roads_count.roadcpt) as pl,speed FROM
 secondary_roads_with_areaid,hpm_flux_zones as flux_zones,area_roads_count WHERE
 flux_zones.num_zone=secondary_roads_with_areaid.NUMERO AND area_roads_count.num_zone=flux_zones.num_zone;

ERROR [Thread-15] (DefaultErrorManager.java:51) - Data access error:
org.gdms.driver.DriverException: java.lang.ArrayIndexOutOfBoundsException: 7
        at org.gdms.sql.engine.ExecutionGraph.execute(ExecutionGraph.scala:118)
        at org.gdms.sql.engine.SqlStatement.execute(SqlStatement.java:97)
        at org.orbisgis.core.ui.plugins.views.sqlConsole.actions.ExecuteScriptProcess.run(ExecuteScriptProcess.java:154)
        at org.orbisgis.core.background.Job.run(Job.java:77)
        at org.orbisgis.core.background.RunnableBackgroundJob.run(RunnableBackgroundJob.java:56)
        at java.lang.Thread.run(Thread.java:662)
Caused by: java.lang.ArrayIndexOutOfBoundsException: 7
        at org.gdms.sql.evaluator.FieldEvaluator$$anonfun$eval$4.apply(Evaluator.scala:180)
        at org.gdms.sql.evaluator.FieldEvaluator$$anonfun$eval$4.apply(Evaluator.scala:180)
        at org.gdms.sql.evaluator.Expression.evaluate(Expressions.scala:69)
        at org.gdms.sql.evaluator.EqualsEvaluator$$anonfun$eval$4.apply(BooleanEvaluators.scala:110)
        at org.gdms.sql.evaluator.EqualsEvaluator$$anonfun$eval$4.apply(BooleanEvaluators.scala:110)
        at org.gdms.sql.evaluator.Expression.evaluate(Expressions.scala:69)
        at org.gdms.sql.evaluator.AndEvaluator$$anonfun$eval$1.apply(BooleanEvaluators.scala:71)
        at org.gdms.sql.evaluator.AndEvaluator$$anonfun$eval$1.apply(BooleanEvaluators.scala:71)
        at org.gdms.sql.evaluator.Expression.evaluate(Expressions.scala:69)
        at org.gdms.sql.engine.commands.join.JoinCommand$$anonfun$1.apply(JoinCommand.scala:66)
        at org.gdms.sql.engine.commands.join.JoinCommand$$anonfun$1.apply(JoinCommand.scala:64)
        at org.gdms.sql.engine.commands.join.JoinCommand$$anonfun$doInnerJoin$1$$anonfun$apply$2.apply(JoinCommand.scala:74)
        at org.gdms.sql.engine.commands.join.JoinCommand$$anonfun$doInnerJoin$1$$anonfun$apply$2.apply(JoinCommand.scala:74)
        at scala.collection.immutable.Stream.flatMap(Stream.scala:213)
        at org.gdms.sql.engine.commands.join.JoinCommand$$anonfun$doInnerJoin$1.apply(JoinCommand.scala:74)
        at org.gdms.sql.engine.commands.join.JoinCommand$$anonfun$doInnerJoin$1.apply(JoinCommand.scala:74)
        at scala.collection.Iterator$$anon$21.hasNext(Iterator.scala:371)
        at scala.collection.Iterator$$anon$19.hasNext(Iterator.scala:334)
        at scala.collection.Iterator$class.foreach(Iterator.scala:660)
        at scala.collection.Iterator$$anon$19.foreach(Iterator.scala:333)
        at org.gdms.sql.engine.commands.QueryOutputCommand$$anonfun$doWork$1.apply(QueryOutputCommand.scala:64)
        at org.gdms.sql.engine.commands.QueryOutputCommand$$anonfun$doWork$1.apply(QueryOutputCommand.scala:64)
        at scala.collection.Iterator$class.foreach(Iterator.scala:660)
        at scala.collection.immutable.StreamIterator.foreach(Stream.scala:512)
        at org.gdms.sql.engine.commands.QueryOutputCommand.doWork(QueryOutputCommand.scala:64)
        at org.gdms.sql.engine.commands.QueryOutputCommand.doWork(QueryOutputCommand.scala:51)
        at org.gdms.sql.engine.commands.Command.execute(Command.scala:61)
        at org.gdms.sql.engine.commands.Command$$anonfun$execute$1.apply(Command.scala:61)
        at org.gdms.sql.engine.commands.Command$$anonfun$execute$1.apply(Command.scala:61)
        at scala.collection.Iterator$$anon$19.next(Iterator.scala:335)
        at scala.collection.Iterator$class.toStream(Iterator.scala:1024)
        at scala.collection.Iterator$$anon$19.toStream(Iterator.scala:333)
        at scala.collection.IterableLike$class.toStream(IterableLike.scala:284)
        at scala.collection.SeqViewLike$$anon$3.toStream(SeqViewLike.scala:77)
        at scala.collection.TraversableLike$class.toIterator(TraversableLike.scala:570)
        at scala.collection.SeqViewLike$$anon$3.toIterator(SeqViewLike.scala:77)
        at org.gdms.sql.engine.commands.Command.execute(Command.scala:61)
        at org.gdms.sql.engine.ExecutionGraph.execute(ExecutionGraph.scala:116)
        ... 5 more

The input files are uploaded

Thanks,
Reply | Threaded
Open this post in threaded view
|

Re: Java.lang.ArrayIndexOutOfBoundsException

Nicolas F.
Administrator
Hi,

Can you import the files and run the sql request and see if you have the same error message ?

Thank you

-Nicolas