Error creating array in JavaScript

If you see this error in JavaScript (for example in a BIRT report):

org.mozilla.javascript.EvaluatorException: error instantiating (): class java.sql.Array is interface or abstract

then don’t include the package java.sql (as in importPackage(Packages.java.sql);) because if you do, new Array() will find the SQL class first and it will fail.

2 Responses to Error creating array in JavaScript

  1. […] Error creating array in JavaScript « Dark Views […]

Leave a comment

This site uses Akismet to reduce spam. Learn how your comment data is processed.