Return-Path: Delivered-To: apmail-jakarta-turbine-user-archive@jakarta.apache.org Received: (qmail 87368 invoked by uid 500); 17 Oct 2001 00:55:35 -0000 Mailing-List: contact turbine-user-help@jakarta.apache.org; run by ezmlm Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: Reply-To: turbine-user@jakarta.apache.org Delivered-To: mailing list turbine-user@jakarta.apache.org Received: (qmail 87349 invoked from network); 17 Oct 2001 00:55:34 -0000 Message-ID: From: Dan Finkelstein To: "'turbine-user@jakarta.apache.org'" Subject: RE: Torque: Oracle with idMethod as "native" Date: Tue, 16 Oct 2001 17:47:19 -0700 MIME-Version: 1.0 X-Mailer: Internet Mail Service (5.5.2650.21) Content-Type: text/plain; charset="iso-8859-1" X-Spam-Rating: 64.125.133.20 1.6.2 0/1000/N Hi -- I found out what the underlying problem was...in the move from "sequence" to "native" as the preferred default, a velocity template file wasn't updated. templates/om/MapBuild.vm should include these two lines after line 99: #elseif ($table.IdMethod == "native") tMap.setPrimaryKeyMethodInfo("$table.SequenceName"); Could something with write access please update the torque tree? Thanks, Dan -----Original Message----- From: Dan Finkelstein Sent: Monday, October 15, 2001 10:16 AM To: 'turbine-user@jakarta.apache.org' Subject: RE: Torque: Oracle with idMethod as "native" I tried this, but got the same error: java.sql.SQLException: ORA-00923: FROM keyword not found where expected at oracle.jdbc.dbaccess.DBError.throwSqlException(DBError.java:114) at oracle.jdbc.oci8.OCIDBAccess.check_error(OCIDBAccess.java:1503) at oracle.jdbc.oci8.OCIDBAccess.parseExecuteDescribe(OCIDBAccess.java:735) at oracle.jdbc.driver.OracleStatement.doExecuteQuery(OracleStatement.java:1600) at oracle.jdbc.driver.OracleStatement.doExecute(OracleStatement.java:1758) at oracle.jdbc.driver.OracleStatement.doExecuteWithTimeout(OracleStatement.java :1805) at oracle.jdbc.driver.OracleStatement.executeQuery(OracleStatement.java:410) at com.workingdogs.village.QueryDataSet.(QueryDataSet.java:112) at org.apache.torque.oid.SequenceIdGenerator.getIdAsVillageValue(SequenceIdGene rator.java:190) at org.apache.torque.oid.SequenceIdGenerator.getIdAsBigDecimal(SequenceIdGenera tor.java:126) at org.apache.torque.util.BasePeer.doInsert(BasePeer.java:793) at org.apache.torque.util.BasePeer.doInsert(BasePeer.java:695) at com.bluescope.pl.tables.BaseServerblobPeer.doInsert(BaseServerblobPeer.java: 128) at com.bluescope.pl.tables.BaseServerblobPeer.doInsert(BaseServerblobPeer.java: 114) at com.bluescope.pl.tables.BaseServerblobPeer.doInsert(BaseServerblobPeer.java: 348) at com.bluescope.pl.AssetPL.addServerBlob(AssetPL.java:192) at com.bluescope.pl.AssetPL.main(AssetPL.java:351) The sql request being passed to JDBC is "select null.nextval from dual" instead of "select company_seq.nextval from dual". It looks like the low-level code isn't able to retrieve COMPANY_SEQ -- Dan -----Original Message----- From: John McNally [mailto:jmcnally@collab.net] Sent: Friday, October 12, 2001 10:45 AM To: turbine-user@jakarta.apache.org Subject: Re: Torque: Oracle with idMethod as "native" have you tried specifying the idMethod directly on the table tag > Sure, here is how my xml schema for the COMPANY table. Thanks! > > > defaultIdMethod="native" > > > >
> primaryKey="true" type="INTEGER"/> > > > >
> > > > > --------------------------------------------------------------------- To unsubscribe, e-mail: turbine-user-unsubscribe@jakarta.apache.org For additional commands, e-mail: turbine-user-help@jakarta.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: turbine-user-unsubscribe@jakarta.apache.org For additional commands, e-mail: turbine-user-help@jakarta.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: turbine-user-unsubscribe@jakarta.apache.org For additional commands, e-mail: turbine-user-help@jakarta.apache.org