You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tapestry.apache.org by Dominik Kreutz <dk...@startext.de> on 2003/11/03 19:03:26 UTC

Contrib SqlTable and Oracle

Hello,

I am currently trying to get SqlTable working with Oracle-Database but
running into problems. Is the Contrib-SqlTable-Component tested with Oracle?

I get error messages during startup and when opening my webapp in the
browser.

While Tomcat starts up I get:
StandardManager[/MyWebApp] IOException while loading persisted sessions:
java.io.WriteAbortedException: writing aborted;
java.io.NotSerializableException:
org.apache.tapestry.contrib.table.model.sql.SimpleSqlTableDataSource
java.io.WriteAbortedException: writing aborted;
java.io.NotSerializableException:
org.apache.tapestry.contrib.table.model.sql.SimpleSqlTableDataSource

StandardManager[/MyWebApp] Exception loading sessions from persistent
storage
java.io.WriteAbortedException: writing aborted;
java.io.NotSerializableException:
org.apache.tapestry.contrib.table.model.sql.SimpleSqlTableDataSource
 at [...]
Caused by: java.io.NotSerializableException:
org.apache.tapestry.contrib.table.model.sql.SimpleSqlTableDataSource
 at [...]
ERROR sql.SqlTableModel  - Cannot get current page rows
java.sql.SQLException: ORA-00933: SQL command not properly ended
 at [...]
Caused by: java.io.NotSerializableException:
org.apache.tapestry.contrib.table.model.sql.SimpleSqlTableDataSource
 at [...]

When opening the webapp in the browser TablePages and TableColumns are shown
only (no Rows/Data) and Tomcat-console shows following:

INFO pageload.PageLoader  - Loaded page
org.apache.tapestry.html.BasePage@1ea763a[contrib:SimpleTableColumnPage]
with 16 components (maximum depth 3)
ERROR sql.SqlTableModel  - Cannot get current page rows
java.sql.SQLException: ORA-00933: SQL command not properly ended
	at oracle.jdbc.dbaccess.DBError.throwSqlException(DBError.java:134)
	at [...]
INFO engine.AbstractEngine  - End service


My TableModel looks like this:

	public ITableModel getTableModel()
	{
		SimpleSqlTableDataSource objDataSource = getDataSource();
		SqlTableColumnModel objColumnModel = getColumns();

		SqlTableModel tableModel = new SqlTableModel(objDataSource,
objColumnModel);
		return tableModel;
	}

	private SimpleSqlTableDataSource getDataSource()
	{
		SimpleSqlConnectionSource cs = new SimpleSqlConnectionSource(
									"jdbc:oracle:thin:@oraclehost:1521:oraclesid",
									"scott",
									"tiger");

		SimpleSqlTableDataSource ds = new SimpleSqlTableDataSource(cs, "EMP");

		return ds;
	}

	private SqlTableColumnModel getColumns()
	{
		SqlTableColumn nameCol = new SqlTableColumn("ENAME", "Employee Name",true)
;
		SqlTableColumn jobCol = new SqlTableColumn("JOB", "Job",true);

		SqlTableColumnModel stcm = new SqlTableColumnModel( new SqlTableColumn[]
{nameCol, jobCol} );

		return stcm;
	}

Best regards,

   Dominik

--
Dipl.-Inform. Dominik Kreutz
startext Unternehmensberatung GmbH, Kennedyallee 2, D-53175 Bonn
Tel.: +49 (0)228 959 96-23, Fax: +49 (0)228 959 96-66
http://www.startext.de


---------------------------------------------------------------------
To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tapestry-user-help@jakarta.apache.org


Re: Contrib SqlTable and Oracle

Posted by Mindbridge <mi...@yahoo.com>.
Hi,

No, it is not. It was tested in some circumstances with some databases, the
ones that could be tested at the time.
When it was added, people who use it have tested it as much as they can.
This still hasn't covered everything 100% though. So your feedback is very
valuable and will result in necessary modifications as soon as possible.
Please write me if you encounter further problems, or simply add them to the
bug database.

Best regards,
-mb

----- Original Message ----- 
From: "Dominik Kreutz" <dk...@startext.de>
To: <ta...@jakarta.apache.org>
Sent: Monday, November 03, 2003 8:03 PM
Subject: Contrib SqlTable and Oracle


> Hello,
>
> I am currently trying to get SqlTable working with Oracle-Database but
> running into problems. Is the Contrib-SqlTable-Component tested with
Oracle?
>
> I get error messages during startup and when opening my webapp in the
> browser.
>
> While Tomcat starts up I get:
> StandardManager[/MyWebApp] IOException while loading persisted sessions:
> java.io.WriteAbortedException: writing aborted;
> java.io.NotSerializableException:
> org.apache.tapestry.contrib.table.model.sql.SimpleSqlTableDataSource
> java.io.WriteAbortedException: writing aborted;
> java.io.NotSerializableException:
> org.apache.tapestry.contrib.table.model.sql.SimpleSqlTableDataSource
>
> StandardManager[/MyWebApp] Exception loading sessions from persistent
> storage
> java.io.WriteAbortedException: writing aborted;
> java.io.NotSerializableException:
> org.apache.tapestry.contrib.table.model.sql.SimpleSqlTableDataSource
>  at [...]
> Caused by: java.io.NotSerializableException:
> org.apache.tapestry.contrib.table.model.sql.SimpleSqlTableDataSource
>  at [...]
> ERROR sql.SqlTableModel  - Cannot get current page rows
> java.sql.SQLException: ORA-00933: SQL command not properly ended
>  at [...]
> Caused by: java.io.NotSerializableException:
> org.apache.tapestry.contrib.table.model.sql.SimpleSqlTableDataSource
>  at [...]
>
> When opening the webapp in the browser TablePages and TableColumns are
shown
> only (no Rows/Data) and Tomcat-console shows following:
>
> INFO pageload.PageLoader  - Loaded page
> org.apache.tapestry.html.BasePage@1ea763a[contrib:SimpleTableColumnPage]
> with 16 components (maximum depth 3)
> ERROR sql.SqlTableModel  - Cannot get current page rows
> java.sql.SQLException: ORA-00933: SQL command not properly ended
> at oracle.jdbc.dbaccess.DBError.throwSqlException(DBError.java:134)
> at [...]
> INFO engine.AbstractEngine  - End service
>
>
> My TableModel looks like this:
>
> public ITableModel getTableModel()
> {
> SimpleSqlTableDataSource objDataSource = getDataSource();
> SqlTableColumnModel objColumnModel = getColumns();
>
> SqlTableModel tableModel = new SqlTableModel(objDataSource,
> objColumnModel);
> return tableModel;
> }
>
> private SimpleSqlTableDataSource getDataSource()
> {
> SimpleSqlConnectionSource cs = new SimpleSqlConnectionSource(
> "jdbc:oracle:thin:@oraclehost:1521:oraclesid",
> "scott",
> "tiger");
>
> SimpleSqlTableDataSource ds = new SimpleSqlTableDataSource(cs, "EMP");
>
> return ds;
> }
>
> private SqlTableColumnModel getColumns()
> {
> SqlTableColumn nameCol = new SqlTableColumn("ENAME", "Employee Name",true)
> ;
> SqlTableColumn jobCol = new SqlTableColumn("JOB", "Job",true);
>
> SqlTableColumnModel stcm = new SqlTableColumnModel( new SqlTableColumn[]
> {nameCol, jobCol} );
>
> return stcm;
> }
>
> Best regards,
>
>    Dominik
>
> --
> Dipl.-Inform. Dominik Kreutz
> startext Unternehmensberatung GmbH, Kennedyallee 2, D-53175 Bonn
> Tel.: +49 (0)228 959 96-23, Fax: +49 (0)228 959 96-66
> http://www.startext.de
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: tapestry-user-help@jakarta.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tapestry-user-help@jakarta.apache.org