简体   繁体   English

从Pentaho报表设计器查询远程Oracle数据库时出错

[英]Error in querying a remote Oracle Database from Pentaho Report Designer

I'm trying to get some data from a remote Oracle Database, so I configured a new connection to the database and whn I press Test, it says that the connection was established succesfully, but when i tried a simple select query, Report Designer gives me an error: 我正在尝试从远程Oracle数据库获取一些数据,所以我配置了一个新的数据库连接,当我按下Test时,它表示连接已成功建立,但当我尝试一个简单的选择查询时,报表设计器给出我错了:

org.pentaho.reporting.engine.classic.core.ReportDataFactoryException: Failed at query: select * from fact_table;
at org.pentaho.reporting.engine.classic.core.modules.misc.datafactory.sql.SimpleSQLReportDataFactory.queryData(SimpleSQLReportDataFactory.java:258)
at org.pentaho.reporting.engine.classic.core.modules.misc.datafactory.sql.SQLReportDataFactory.queryData(SQLReportDataFactory.java:171)
at org.pentaho.reporting.ui.datasources.jdbc.ui.JdbcPreviewWorker.run(JdbcPreviewWorker.java:103)
at java.lang.Thread.run(Unknown Source)

ParentException: ParentException:

 java.sql.SQLException: ORA-00911: invalid character

at oracle.jdbc.driver.DatabaseError.throwSqlException(DatabaseError.java:125)
at oracle.jdbc.driver.T4CTTIoer.processError(T4CTTIoer.java:305)
at oracle.jdbc.driver.T4CTTIoer.processError(T4CTTIoer.java:272)
at oracle.jdbc.driver.T4C8Oall.receive(T4C8Oall.java:623)
at oracle.jdbc.driver.T4CStatement.doOall8(T4CStatement.java:112)
at oracle.jdbc.driver.T4CStatement.execute_for_describe(T4CStatement.java:351)
at oracle.jdbc.driver.OracleStatement.execute_maybe_describe(OracleStatement.java:896)
at oracle.jdbc.driver.T4CStatement.execute_maybe_describe(T4CStatement.java:383)
at oracle.jdbc.driver.OracleStatement.doExecuteWithTimeout(OracleStatement.java:986)
at oracle.jdbc.driver.OracleStatement.doScrollExecuteCommon(OracleStatement.java:3763)
at oracle.jdbc.driver.OracleStatement.doScrollStmtExecuteQuery(OracleStatement.java:3887)
at oracle.jdbc.driver.OracleStatement.executeQuery(OracleStatement.java:1131)
at org.pentaho.reporting.engine.classic.core.modules.misc.datafactory.sql.SimpleSQLReportDataFactory.parametrizeAndQuery(SimpleSQLReportDataFactory.java:422)
at org.pentaho.reporting.engine.classic.core.modules.misc.datafactory.sql.SimpleSQLReportDataFactory.queryData(SimpleSQLReportDataFactory.java:254)
at org.pentaho.reporting.engine.classic.core.modules.misc.datafactory.sql.SQLReportDataFactory.queryData(SQLReportDataFactory.java:171)
at org.pentaho.reporting.ui.datasources.jdbc.ui.JdbcPreviewWorker.run(JdbcPreviewWorker.java:103)
at java.lang.Thread.run(Unknown Source)

So how can I get this done? 那我该怎么做呢?

select * from fact_table; seems to be a valid query. 似乎是一个有效的查询。 Try to remove the semicolon at the end. 尝试最后删除分号。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM