You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@turbine.apache.org by brian <br...@westpole.com> on 2003/09/19 00:39:08 UTC
problem doing inserts using Criteria and Peer
I am trying to do an insert using :
Criteria crit = new Criteria();
crit.add(EventPeer.EVNT_EVTY_ID,"1");
Object o = EventPeer.doInsert(crit);
But I get a "java.lang.nullPointerException" and this is what I get
when I print out the Criteria object:
Criteria:: event.EVNT_EVTY_ID<=>(event.EVNT_EVTY_ID='1'):
Current Query SQL (may not be complete or applicable): SELECT FROM
event WHERE (event.EVNT_EVTY_ID='1')
I understand that this a select statement but I am following the
directions from the turbine site under "working with peers" for doing
inserts am I doing this correctly?
Thanks,
Brian
Re: problem doing inserts using Criteria and Peer
Posted by Wei He <we...@ldeo.columbia.edu>.
Hi Brian,
The tables should be defined with idMethod attribute for each of the
table you want to use
key generation.
database>
<table name="RDF" idMethod="native">
<column name="RDF_ID" required="true" autoIncrement="true"
primaryKey="true" type="INTEGER"/>
<column name="TITLE" size="255" type="VARCHAR"/>
<column name="BODY" size="255" type="VARCHAR"/>
<column name="URL" size="255" type="VARCHAR"/>
<column name="AUTHOR" size="255" type="VARCHAR"/>
<column name="DEPT" size="255" type="VARCHAR"/>
</table>
...
...
</database>
This should solve your problem.
Wei
brian wrote:
>Sorry,Here it is:
><!--
>==================================================================== -->
><!--
>-->
><!-- T U R B I N E P R O J E C T S C H E M A
>-->
><!--
>-->
><!--
>==================================================================== -->
><!-- This is an example Turbine project schema.
>-->
><!--
>==================================================================== -->
>
><database>
> <table name="RDF">
> <column name="RDF_ID" required="true" autoIncrement="true"
>primaryKey="true" type="INTEGER"/>
> <column name="TITLE" size="255" type="VARCHAR"/>
> <column name="BODY" size="255" type="VARCHAR"/>
> <column name="URL" size="255" type="VARCHAR"/>
> <column name="AUTHOR" size="255" type="VARCHAR"/>
> <column name="DEPT" size="255" type="VARCHAR"/>
> </table>
> <table name="event">
> <column name="evnt_id" required="true" autoIncrement="true"
>primaryKey="true" type="INTEGER"/>
> <column name="evnt_wrkq_id" size="255" type="INTEGER"/>
> <column name="evnt_evty_id" size="255" type="INTEGER"/>
> <column name="evnt_loan_id" size="255" type="INTEGER"/>
> <column name="evnt_wkfl_id" size="255" type="INTEGER"/>
> </table>
> <table name="event_type">
> <column name="evty_id" required="true" autoIncrement="false"
>primaryKey="true" type="INTEGER"/>
> <column name="evty_desc" size="255" type="VARCHAR"/>
> </table>
> <table name="workflow">
> <column name="wkfl_id" required="true" autoIncrement="false"
>primaryKey="true" type="INTEGER"/>
> <column name="wkfl_status" size="255" type="INTEGER"/>
> <column name="wkfl_wftp_id" size="255" type="INTEGER"/>
> <column name="wkfl_loan_id" size="255" type="INTEGER"/>
> <column name="wkfl_evnt_id" size="255" type="INTEGER"/>
> </table>
> <table name="workque">
> <column name="wrkq_id" required="true" autoIncrement="false"
>primaryKey="true" type="INTEGER"/>
> <column name="wrkq_wkgp_id" size="255" type="INTEGER"/>
> <column name="wrkq_wrkr_id" size="255" type="INTEGER"/>
> </table>
> <table name="worker">
> <column name="wrkr_id" required="true" autoIncrement="false"
>primaryKey="true" type="INTEGER"/>
> <column name="wrkr_desc" size="255" type="VARCHAR"/>
> </table>
> <table name="workgroup">
> <column name="wkgp_id" required="true" autoIncrement="false"
>primaryKey="true" type="INTEGER"/>
> <column name="wkgp_desc" size="255" type="VARCHAR"/>
> </table>
> <table name="task">
> <column name="task_id" required="true" autoIncrement="false"
>primaryKey="true" type="INTEGER"/>
> <column name="task_tktp_id" size="255" type="INTEGER"/>
> <column name="task_wrkq_id" size="255" type="INTEGER"/>
> <column name="task_wkfl_id" size="255" type="INTEGER"/>
> <column name="task_evnt_id" size="255" type="INTEGER"/>
> <column name="task_status" size="255" type="VARCHAR"/>
> </table>
> <table name="task_type">
> <column name="tktp_id" required="true" autoIncrement="false"
>primaryKey="true" type="INTEGER"/>
> <column name="tktp_desc" size="255" type="VARCHAR"/>
> <column name="tktp_wkgp_id" size="255" type="INTEGER"/>
> <column name="tktp_wftp_id" size="255" type="INTEGER"/>
> </table>
> <table name="workflow_type">
> <column name="wftp_id" required="true" autoIncrement="false"
>primaryKey="true" type="INTEGER"/>
> <column name="wftp_desc" size="255" type="VARCHAR"/>
> </table>
> <table name="loan">
> <column name="loan_id" required="true" autoIncrement="false"
>primaryKey="true" type="INTEGER"/>
> <column name="loan_lntp_id" size="255" type="INTEGER"/>
> <column name="loan_evnt_id" size="255" type="INTEGER"/>
> </table>
> <table name="loan_type">
> <column name="lntp_id" required="true" autoIncrement="false"
>primaryKey="true" type="INTEGER"/>
> <column name="lntp_desc" size="255" type="VARCHAR"/>
> </table>
></database>
>
>-----Original Message-----
>From: Scott Eade [mailto:seade@backstagetech.com.au]
>Sent: Friday, September 19, 2003 11:31 PM
>To: Turbine Users List
>Subject: Re: problem doing inserts using Criteria and Peer
>
>brian wrote:
>
>
>
>>Here is my schema:
>>#
>>-----------------------------------------------------------------------
>># RDF
>>#
>>-----------------------------------------------------------------------
>>drop table if exists RDF;
>>
>>CREATE TABLE RDF
>>(
>> RDF_ID INTEGER NOT NULL AUTO_INCREMENT,
>> TITLE VARCHAR (255),
>> BODY VARCHAR (255),
>> URL VARCHAR (255),
>> AUTHOR VARCHAR (255),
>> DEPT VARCHAR (255),
>> PRIMARY KEY(RDF_ID)
>>);
>>
>>
>>
>>
>I meant your xml schema file - this is where the ID method is defined.
>
>Scott
>
>
>
Re: problem doing inserts using Criteria and Peer
Posted by Wei He <we...@ldeo.columbia.edu>.
Hi Brian,
The tables should be defined with idMethod attribute for each of the
table you want to use
key generation.
database>
<table name="RDF" idMethod="native">
<column name="RDF_ID" required="true" autoIncrement="true"
primaryKey="true" type="INTEGER"/>
<column name="TITLE" size="255" type="VARCHAR"/>
<column name="BODY" size="255" type="VARCHAR"/>
<column name="URL" size="255" type="VARCHAR"/>
<column name="AUTHOR" size="255" type="VARCHAR"/>
<column name="DEPT" size="255" type="VARCHAR"/>
</table>
...
...
</database>
This should solve your problem.
Wei
brian wrote:
>Sorry,Here it is:
><!--
>==================================================================== -->
><!--
>-->
><!-- T U R B I N E P R O J E C T S C H E M A
>-->
><!--
>-->
><!--
>==================================================================== -->
><!-- This is an example Turbine project schema.
>-->
><!--
>==================================================================== -->
>
><database>
> <table name="RDF">
> <column name="RDF_ID" required="true" autoIncrement="true"
>primaryKey="true" type="INTEGER"/>
> <column name="TITLE" size="255" type="VARCHAR"/>
> <column name="BODY" size="255" type="VARCHAR"/>
> <column name="URL" size="255" type="VARCHAR"/>
> <column name="AUTHOR" size="255" type="VARCHAR"/>
> <column name="DEPT" size="255" type="VARCHAR"/>
> </table>
> <table name="event">
> <column name="evnt_id" required="true" autoIncrement="true"
>primaryKey="true" type="INTEGER"/>
> <column name="evnt_wrkq_id" size="255" type="INTEGER"/>
> <column name="evnt_evty_id" size="255" type="INTEGER"/>
> <column name="evnt_loan_id" size="255" type="INTEGER"/>
> <column name="evnt_wkfl_id" size="255" type="INTEGER"/>
> </table>
> <table name="event_type">
> <column name="evty_id" required="true" autoIncrement="false"
>primaryKey="true" type="INTEGER"/>
> <column name="evty_desc" size="255" type="VARCHAR"/>
> </table>
> <table name="workflow">
> <column name="wkfl_id" required="true" autoIncrement="false"
>primaryKey="true" type="INTEGER"/>
> <column name="wkfl_status" size="255" type="INTEGER"/>
> <column name="wkfl_wftp_id" size="255" type="INTEGER"/>
> <column name="wkfl_loan_id" size="255" type="INTEGER"/>
> <column name="wkfl_evnt_id" size="255" type="INTEGER"/>
> </table>
> <table name="workque">
> <column name="wrkq_id" required="true" autoIncrement="false"
>primaryKey="true" type="INTEGER"/>
> <column name="wrkq_wkgp_id" size="255" type="INTEGER"/>
> <column name="wrkq_wrkr_id" size="255" type="INTEGER"/>
> </table>
> <table name="worker">
> <column name="wrkr_id" required="true" autoIncrement="false"
>primaryKey="true" type="INTEGER"/>
> <column name="wrkr_desc" size="255" type="VARCHAR"/>
> </table>
> <table name="workgroup">
> <column name="wkgp_id" required="true" autoIncrement="false"
>primaryKey="true" type="INTEGER"/>
> <column name="wkgp_desc" size="255" type="VARCHAR"/>
> </table>
> <table name="task">
> <column name="task_id" required="true" autoIncrement="false"
>primaryKey="true" type="INTEGER"/>
> <column name="task_tktp_id" size="255" type="INTEGER"/>
> <column name="task_wrkq_id" size="255" type="INTEGER"/>
> <column name="task_wkfl_id" size="255" type="INTEGER"/>
> <column name="task_evnt_id" size="255" type="INTEGER"/>
> <column name="task_status" size="255" type="VARCHAR"/>
> </table>
> <table name="task_type">
> <column name="tktp_id" required="true" autoIncrement="false"
>primaryKey="true" type="INTEGER"/>
> <column name="tktp_desc" size="255" type="VARCHAR"/>
> <column name="tktp_wkgp_id" size="255" type="INTEGER"/>
> <column name="tktp_wftp_id" size="255" type="INTEGER"/>
> </table>
> <table name="workflow_type">
> <column name="wftp_id" required="true" autoIncrement="false"
>primaryKey="true" type="INTEGER"/>
> <column name="wftp_desc" size="255" type="VARCHAR"/>
> </table>
> <table name="loan">
> <column name="loan_id" required="true" autoIncrement="false"
>primaryKey="true" type="INTEGER"/>
> <column name="loan_lntp_id" size="255" type="INTEGER"/>
> <column name="loan_evnt_id" size="255" type="INTEGER"/>
> </table>
> <table name="loan_type">
> <column name="lntp_id" required="true" autoIncrement="false"
>primaryKey="true" type="INTEGER"/>
> <column name="lntp_desc" size="255" type="VARCHAR"/>
> </table>
></database>
>
>-----Original Message-----
>From: Scott Eade [mailto:seade@backstagetech.com.au]
>Sent: Friday, September 19, 2003 11:31 PM
>To: Turbine Users List
>Subject: Re: problem doing inserts using Criteria and Peer
>
>brian wrote:
>
>
>
>>Here is my schema:
>>#
>>-----------------------------------------------------------------------
>># RDF
>>#
>>-----------------------------------------------------------------------
>>drop table if exists RDF;
>>
>>CREATE TABLE RDF
>>(
>> RDF_ID INTEGER NOT NULL AUTO_INCREMENT,
>> TITLE VARCHAR (255),
>> BODY VARCHAR (255),
>> URL VARCHAR (255),
>> AUTHOR VARCHAR (255),
>> DEPT VARCHAR (255),
>> PRIMARY KEY(RDF_ID)
>>);
>>
>>
>>
>>
>I meant your xml schema file - this is where the ID method is defined.
>
>Scott
>
>
>
---------------------------------------------------------------------
To unsubscribe, e-mail: turbine-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: turbine-user-help@jakarta.apache.org
RE: problem doing inserts using Criteria and Peer
Posted by brian <br...@westpole.com>.
Sorry,Here it is:
<!--
==================================================================== -->
<!--
-->
<!-- T U R B I N E P R O J E C T S C H E M A
-->
<!--
-->
<!--
==================================================================== -->
<!-- This is an example Turbine project schema.
-->
<!--
==================================================================== -->
<database>
<table name="RDF">
<column name="RDF_ID" required="true" autoIncrement="true"
primaryKey="true" type="INTEGER"/>
<column name="TITLE" size="255" type="VARCHAR"/>
<column name="BODY" size="255" type="VARCHAR"/>
<column name="URL" size="255" type="VARCHAR"/>
<column name="AUTHOR" size="255" type="VARCHAR"/>
<column name="DEPT" size="255" type="VARCHAR"/>
</table>
<table name="event">
<column name="evnt_id" required="true" autoIncrement="true"
primaryKey="true" type="INTEGER"/>
<column name="evnt_wrkq_id" size="255" type="INTEGER"/>
<column name="evnt_evty_id" size="255" type="INTEGER"/>
<column name="evnt_loan_id" size="255" type="INTEGER"/>
<column name="evnt_wkfl_id" size="255" type="INTEGER"/>
</table>
<table name="event_type">
<column name="evty_id" required="true" autoIncrement="false"
primaryKey="true" type="INTEGER"/>
<column name="evty_desc" size="255" type="VARCHAR"/>
</table>
<table name="workflow">
<column name="wkfl_id" required="true" autoIncrement="false"
primaryKey="true" type="INTEGER"/>
<column name="wkfl_status" size="255" type="INTEGER"/>
<column name="wkfl_wftp_id" size="255" type="INTEGER"/>
<column name="wkfl_loan_id" size="255" type="INTEGER"/>
<column name="wkfl_evnt_id" size="255" type="INTEGER"/>
</table>
<table name="workque">
<column name="wrkq_id" required="true" autoIncrement="false"
primaryKey="true" type="INTEGER"/>
<column name="wrkq_wkgp_id" size="255" type="INTEGER"/>
<column name="wrkq_wrkr_id" size="255" type="INTEGER"/>
</table>
<table name="worker">
<column name="wrkr_id" required="true" autoIncrement="false"
primaryKey="true" type="INTEGER"/>
<column name="wrkr_desc" size="255" type="VARCHAR"/>
</table>
<table name="workgroup">
<column name="wkgp_id" required="true" autoIncrement="false"
primaryKey="true" type="INTEGER"/>
<column name="wkgp_desc" size="255" type="VARCHAR"/>
</table>
<table name="task">
<column name="task_id" required="true" autoIncrement="false"
primaryKey="true" type="INTEGER"/>
<column name="task_tktp_id" size="255" type="INTEGER"/>
<column name="task_wrkq_id" size="255" type="INTEGER"/>
<column name="task_wkfl_id" size="255" type="INTEGER"/>
<column name="task_evnt_id" size="255" type="INTEGER"/>
<column name="task_status" size="255" type="VARCHAR"/>
</table>
<table name="task_type">
<column name="tktp_id" required="true" autoIncrement="false"
primaryKey="true" type="INTEGER"/>
<column name="tktp_desc" size="255" type="VARCHAR"/>
<column name="tktp_wkgp_id" size="255" type="INTEGER"/>
<column name="tktp_wftp_id" size="255" type="INTEGER"/>
</table>
<table name="workflow_type">
<column name="wftp_id" required="true" autoIncrement="false"
primaryKey="true" type="INTEGER"/>
<column name="wftp_desc" size="255" type="VARCHAR"/>
</table>
<table name="loan">
<column name="loan_id" required="true" autoIncrement="false"
primaryKey="true" type="INTEGER"/>
<column name="loan_lntp_id" size="255" type="INTEGER"/>
<column name="loan_evnt_id" size="255" type="INTEGER"/>
</table>
<table name="loan_type">
<column name="lntp_id" required="true" autoIncrement="false"
primaryKey="true" type="INTEGER"/>
<column name="lntp_desc" size="255" type="VARCHAR"/>
</table>
</database>
-----Original Message-----
From: Scott Eade [mailto:seade@backstagetech.com.au]
Sent: Friday, September 19, 2003 11:31 PM
To: Turbine Users List
Subject: Re: problem doing inserts using Criteria and Peer
brian wrote:
>Here is my schema:
>#
>-----------------------------------------------------------------------
># RDF
>#
>-----------------------------------------------------------------------
>drop table if exists RDF;
>
>CREATE TABLE RDF
>(
> RDF_ID INTEGER NOT NULL AUTO_INCREMENT,
> TITLE VARCHAR (255),
> BODY VARCHAR (255),
> URL VARCHAR (255),
> AUTHOR VARCHAR (255),
> DEPT VARCHAR (255),
> PRIMARY KEY(RDF_ID)
>);
>
>
I meant your xml schema file - this is where the ID method is defined.
Scott
--
Scott Eade
Backstage Technologies Pty. Ltd.
http://www.backstagetech.com.au
---------------------------------------------------------------------
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
RE: problem doing inserts using Criteria and Peer
Posted by brian <br...@westpole.com>.
Sorry,Here it is:
<!--
==================================================================== -->
<!--
-->
<!-- T U R B I N E P R O J E C T S C H E M A
-->
<!--
-->
<!--
==================================================================== -->
<!-- This is an example Turbine project schema.
-->
<!--
==================================================================== -->
<database>
<table name="RDF">
<column name="RDF_ID" required="true" autoIncrement="true"
primaryKey="true" type="INTEGER"/>
<column name="TITLE" size="255" type="VARCHAR"/>
<column name="BODY" size="255" type="VARCHAR"/>
<column name="URL" size="255" type="VARCHAR"/>
<column name="AUTHOR" size="255" type="VARCHAR"/>
<column name="DEPT" size="255" type="VARCHAR"/>
</table>
<table name="event">
<column name="evnt_id" required="true" autoIncrement="true"
primaryKey="true" type="INTEGER"/>
<column name="evnt_wrkq_id" size="255" type="INTEGER"/>
<column name="evnt_evty_id" size="255" type="INTEGER"/>
<column name="evnt_loan_id" size="255" type="INTEGER"/>
<column name="evnt_wkfl_id" size="255" type="INTEGER"/>
</table>
<table name="event_type">
<column name="evty_id" required="true" autoIncrement="false"
primaryKey="true" type="INTEGER"/>
<column name="evty_desc" size="255" type="VARCHAR"/>
</table>
<table name="workflow">
<column name="wkfl_id" required="true" autoIncrement="false"
primaryKey="true" type="INTEGER"/>
<column name="wkfl_status" size="255" type="INTEGER"/>
<column name="wkfl_wftp_id" size="255" type="INTEGER"/>
<column name="wkfl_loan_id" size="255" type="INTEGER"/>
<column name="wkfl_evnt_id" size="255" type="INTEGER"/>
</table>
<table name="workque">
<column name="wrkq_id" required="true" autoIncrement="false"
primaryKey="true" type="INTEGER"/>
<column name="wrkq_wkgp_id" size="255" type="INTEGER"/>
<column name="wrkq_wrkr_id" size="255" type="INTEGER"/>
</table>
<table name="worker">
<column name="wrkr_id" required="true" autoIncrement="false"
primaryKey="true" type="INTEGER"/>
<column name="wrkr_desc" size="255" type="VARCHAR"/>
</table>
<table name="workgroup">
<column name="wkgp_id" required="true" autoIncrement="false"
primaryKey="true" type="INTEGER"/>
<column name="wkgp_desc" size="255" type="VARCHAR"/>
</table>
<table name="task">
<column name="task_id" required="true" autoIncrement="false"
primaryKey="true" type="INTEGER"/>
<column name="task_tktp_id" size="255" type="INTEGER"/>
<column name="task_wrkq_id" size="255" type="INTEGER"/>
<column name="task_wkfl_id" size="255" type="INTEGER"/>
<column name="task_evnt_id" size="255" type="INTEGER"/>
<column name="task_status" size="255" type="VARCHAR"/>
</table>
<table name="task_type">
<column name="tktp_id" required="true" autoIncrement="false"
primaryKey="true" type="INTEGER"/>
<column name="tktp_desc" size="255" type="VARCHAR"/>
<column name="tktp_wkgp_id" size="255" type="INTEGER"/>
<column name="tktp_wftp_id" size="255" type="INTEGER"/>
</table>
<table name="workflow_type">
<column name="wftp_id" required="true" autoIncrement="false"
primaryKey="true" type="INTEGER"/>
<column name="wftp_desc" size="255" type="VARCHAR"/>
</table>
<table name="loan">
<column name="loan_id" required="true" autoIncrement="false"
primaryKey="true" type="INTEGER"/>
<column name="loan_lntp_id" size="255" type="INTEGER"/>
<column name="loan_evnt_id" size="255" type="INTEGER"/>
</table>
<table name="loan_type">
<column name="lntp_id" required="true" autoIncrement="false"
primaryKey="true" type="INTEGER"/>
<column name="lntp_desc" size="255" type="VARCHAR"/>
</table>
</database>
-----Original Message-----
From: Scott Eade [mailto:seade@backstagetech.com.au]
Sent: Friday, September 19, 2003 11:31 PM
To: Turbine Users List
Subject: Re: problem doing inserts using Criteria and Peer
brian wrote:
>Here is my schema:
>#
>-----------------------------------------------------------------------
># RDF
>#
>-----------------------------------------------------------------------
>drop table if exists RDF;
>
>CREATE TABLE RDF
>(
> RDF_ID INTEGER NOT NULL AUTO_INCREMENT,
> TITLE VARCHAR (255),
> BODY VARCHAR (255),
> URL VARCHAR (255),
> AUTHOR VARCHAR (255),
> DEPT VARCHAR (255),
> PRIMARY KEY(RDF_ID)
>);
>
>
I meant your xml schema file - this is where the ID method is defined.
Scott
--
Scott Eade
Backstage Technologies Pty. Ltd.
http://www.backstagetech.com.au
---------------------------------------------------------------------
To unsubscribe, e-mail: turbine-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: turbine-user-help@jakarta.apache.org
Re: problem doing inserts using Criteria and Peer
Posted by Scott Eade <se...@backstagetech.com.au>.
brian wrote:
>Here is my schema:
>#
>-----------------------------------------------------------------------
># RDF
>#
>-----------------------------------------------------------------------
>drop table if exists RDF;
>
>CREATE TABLE RDF
>(
> RDF_ID INTEGER NOT NULL AUTO_INCREMENT,
> TITLE VARCHAR (255),
> BODY VARCHAR (255),
> URL VARCHAR (255),
> AUTHOR VARCHAR (255),
> DEPT VARCHAR (255),
> PRIMARY KEY(RDF_ID)
>);
>
>
I meant your xml schema file - this is where the ID method is defined.
Scott
--
Scott Eade
Backstage Technologies Pty. Ltd.
http://www.backstagetech.com.au
Re: problem doing inserts using Criteria and Peer
Posted by Scott Eade <se...@backstagetech.com.au>.
brian wrote:
>Here is my schema:
>#
>-----------------------------------------------------------------------
># RDF
>#
>-----------------------------------------------------------------------
>drop table if exists RDF;
>
>CREATE TABLE RDF
>(
> RDF_ID INTEGER NOT NULL AUTO_INCREMENT,
> TITLE VARCHAR (255),
> BODY VARCHAR (255),
> URL VARCHAR (255),
> AUTHOR VARCHAR (255),
> DEPT VARCHAR (255),
> PRIMARY KEY(RDF_ID)
>);
>
>
I meant your xml schema file - this is where the ID method is defined.
Scott
--
Scott Eade
Backstage Technologies Pty. Ltd.
http://www.backstagetech.com.au
---------------------------------------------------------------------
To unsubscribe, e-mail: turbine-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: turbine-user-help@jakarta.apache.org
RE: problem doing inserts using Criteria and Peer
Posted by brian <br...@westpole.com>.
Here is my schema:
#
-----------------------------------------------------------------------
# RDF
#
-----------------------------------------------------------------------
drop table if exists RDF;
CREATE TABLE RDF
(
RDF_ID INTEGER NOT NULL AUTO_INCREMENT,
TITLE VARCHAR (255),
BODY VARCHAR (255),
URL VARCHAR (255),
AUTHOR VARCHAR (255),
DEPT VARCHAR (255),
PRIMARY KEY(RDF_ID)
);
#
-----------------------------------------------------------------------
# event
#
-----------------------------------------------------------------------
drop table if exists event;
CREATE TABLE event
(
evnt_id INTEGER NOT NULL AUTO_INCREMENT,
evnt_wrkq_id INTEGER (255),
evnt_evty_id INTEGER (255),
evnt_loan_id INTEGER (255),
evnt_wkfl_id INTEGER (255),
PRIMARY KEY(evnt_id)
);
#
-----------------------------------------------------------------------
# event_type
#
-----------------------------------------------------------------------
drop table if exists event_type;
CREATE TABLE event_type
(
evty_id INTEGER NOT NULL,
evty_desc VARCHAR (255),
PRIMARY KEY(evty_id)
);
#
-----------------------------------------------------------------------
# workflow
#
-----------------------------------------------------------------------
drop table if exists workflow;
CREATE TABLE workflow
(
wkfl_id INTEGER NOT NULL,
wkfl_status INTEGER (255),
wkfl_wftp_id INTEGER (255),
wkfl_loan_id INTEGER (255),
wkfl_evnt_id INTEGER (255),
PRIMARY KEY(wkfl_id)
);
#
-----------------------------------------------------------------------
# workque
#
-----------------------------------------------------------------------
drop table if exists workque;
CREATE TABLE workque
(
wrkq_id INTEGER NOT NULL,
wrkq_wkgp_id INTEGER (255),
wrkq_wrkr_id INTEGER (255),
PRIMARY KEY(wrkq_id)
);
#
-----------------------------------------------------------------------
# worker
#
-----------------------------------------------------------------------
drop table if exists worker;
CREATE TABLE worker
(
wrkr_id INTEGER NOT NULL,
wrkr_desc VARCHAR (255),
PRIMARY KEY(wrkr_id)
);
#
-----------------------------------------------------------------------
# workgroup
#
-----------------------------------------------------------------------
drop table if exists workgroup;
CREATE TABLE workgroup
(
wkgp_id INTEGER NOT NULL,
wkgp_desc VARCHAR (255),
PRIMARY KEY(wkgp_id)
);
#
-----------------------------------------------------------------------
# task
#
-----------------------------------------------------------------------
drop table if exists task;
CREATE TABLE task
(
task_id INTEGER NOT NULL,
task_tktp_id INTEGER (255),
task_wrkq_id INTEGER (255),
task_wkfl_id INTEGER (255),
task_evnt_id INTEGER (255),
task_status VARCHAR (255),
PRIMARY KEY(task_id)
);
#
-----------------------------------------------------------------------
# task_type
#
-----------------------------------------------------------------------
drop table if exists task_type;
CREATE TABLE task_type
(
tktp_id INTEGER NOT NULL,
tktp_desc VARCHAR (255),
tktp_wkgp_id INTEGER (255),
tktp_wftp_id INTEGER (255),
PRIMARY KEY(tktp_id)
);
#
-----------------------------------------------------------------------
# workflow_type
#
-----------------------------------------------------------------------
drop table if exists workflow_type;
CREATE TABLE workflow_type
(
wftp_id INTEGER NOT NULL,
wftp_desc VARCHAR (255),
PRIMARY KEY(wftp_id)
);
#
-----------------------------------------------------------------------
# loan
#
-----------------------------------------------------------------------
drop table if exists loan;
CREATE TABLE loan
(
loan_id INTEGER NOT NULL,
loan_lntp_id INTEGER (255),
loan_evnt_id INTEGER (255),
PRIMARY KEY(loan_id)
);
#
-----------------------------------------------------------------------
# loan_type
#
-----------------------------------------------------------------------
drop table if exists loan_type;
CREATE TABLE loan_type
(
lntp_id INTEGER NOT NULL,
lntp_desc VARCHAR (255),
PRIMARY KEY(lntp_id)
);
-----Original Message-----
From: Scott Eade [mailto:seade@backstagetech.com.au]
Sent: Friday, September 19, 2003 3:53 PM
To: Turbine Users List
Subject: Re: problem doing inserts using Criteria and Peer
Then I suggest that your schema is incorrect in that it is not
configuring the id method correctly. Please post your schema
so that we can comment on this.
Scott
brian wrote:
>I tried that method already and it just returns null because the
eventID
>on the Event object isn't set when the other information is saved.
>
>Brian
>
>-----Original Message-----
>From: Scott Eade [mailto:seade@backstagetech.com.au]
>Sent: Friday, September 19, 2003 12:16 AM
>To: Turbine Users List
>Subject: Re: problem doing inserts using Criteria and Peer
>
>brian wrote:
>
>
>
>>I looked but I didn't see a method for retrieving the auto generated
>>value from an insert statement. Is there a way to do this when the
data
>>is saved this way?
>>
>>
>Try:
>
>Event event = new Event();
>event.save();
>int eventId = event.getEventId();
>
>
>Scott
>
>
--
Scott Eade
Backstage Technologies Pty. Ltd.
http://www.backstagetech.com.au
---------------------------------------------------------------------
To unsubscribe, e-mail: turbine-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: turbine-user-help@jakarta.apache.org
RE: problem doing inserts using Criteria and Peer
Posted by brian <br...@westpole.com>.
Here is my schema:
#
-----------------------------------------------------------------------
# RDF
#
-----------------------------------------------------------------------
drop table if exists RDF;
CREATE TABLE RDF
(
RDF_ID INTEGER NOT NULL AUTO_INCREMENT,
TITLE VARCHAR (255),
BODY VARCHAR (255),
URL VARCHAR (255),
AUTHOR VARCHAR (255),
DEPT VARCHAR (255),
PRIMARY KEY(RDF_ID)
);
#
-----------------------------------------------------------------------
# event
#
-----------------------------------------------------------------------
drop table if exists event;
CREATE TABLE event
(
evnt_id INTEGER NOT NULL AUTO_INCREMENT,
evnt_wrkq_id INTEGER (255),
evnt_evty_id INTEGER (255),
evnt_loan_id INTEGER (255),
evnt_wkfl_id INTEGER (255),
PRIMARY KEY(evnt_id)
);
#
-----------------------------------------------------------------------
# event_type
#
-----------------------------------------------------------------------
drop table if exists event_type;
CREATE TABLE event_type
(
evty_id INTEGER NOT NULL,
evty_desc VARCHAR (255),
PRIMARY KEY(evty_id)
);
#
-----------------------------------------------------------------------
# workflow
#
-----------------------------------------------------------------------
drop table if exists workflow;
CREATE TABLE workflow
(
wkfl_id INTEGER NOT NULL,
wkfl_status INTEGER (255),
wkfl_wftp_id INTEGER (255),
wkfl_loan_id INTEGER (255),
wkfl_evnt_id INTEGER (255),
PRIMARY KEY(wkfl_id)
);
#
-----------------------------------------------------------------------
# workque
#
-----------------------------------------------------------------------
drop table if exists workque;
CREATE TABLE workque
(
wrkq_id INTEGER NOT NULL,
wrkq_wkgp_id INTEGER (255),
wrkq_wrkr_id INTEGER (255),
PRIMARY KEY(wrkq_id)
);
#
-----------------------------------------------------------------------
# worker
#
-----------------------------------------------------------------------
drop table if exists worker;
CREATE TABLE worker
(
wrkr_id INTEGER NOT NULL,
wrkr_desc VARCHAR (255),
PRIMARY KEY(wrkr_id)
);
#
-----------------------------------------------------------------------
# workgroup
#
-----------------------------------------------------------------------
drop table if exists workgroup;
CREATE TABLE workgroup
(
wkgp_id INTEGER NOT NULL,
wkgp_desc VARCHAR (255),
PRIMARY KEY(wkgp_id)
);
#
-----------------------------------------------------------------------
# task
#
-----------------------------------------------------------------------
drop table if exists task;
CREATE TABLE task
(
task_id INTEGER NOT NULL,
task_tktp_id INTEGER (255),
task_wrkq_id INTEGER (255),
task_wkfl_id INTEGER (255),
task_evnt_id INTEGER (255),
task_status VARCHAR (255),
PRIMARY KEY(task_id)
);
#
-----------------------------------------------------------------------
# task_type
#
-----------------------------------------------------------------------
drop table if exists task_type;
CREATE TABLE task_type
(
tktp_id INTEGER NOT NULL,
tktp_desc VARCHAR (255),
tktp_wkgp_id INTEGER (255),
tktp_wftp_id INTEGER (255),
PRIMARY KEY(tktp_id)
);
#
-----------------------------------------------------------------------
# workflow_type
#
-----------------------------------------------------------------------
drop table if exists workflow_type;
CREATE TABLE workflow_type
(
wftp_id INTEGER NOT NULL,
wftp_desc VARCHAR (255),
PRIMARY KEY(wftp_id)
);
#
-----------------------------------------------------------------------
# loan
#
-----------------------------------------------------------------------
drop table if exists loan;
CREATE TABLE loan
(
loan_id INTEGER NOT NULL,
loan_lntp_id INTEGER (255),
loan_evnt_id INTEGER (255),
PRIMARY KEY(loan_id)
);
#
-----------------------------------------------------------------------
# loan_type
#
-----------------------------------------------------------------------
drop table if exists loan_type;
CREATE TABLE loan_type
(
lntp_id INTEGER NOT NULL,
lntp_desc VARCHAR (255),
PRIMARY KEY(lntp_id)
);
-----Original Message-----
From: Scott Eade [mailto:seade@backstagetech.com.au]
Sent: Friday, September 19, 2003 3:53 PM
To: Turbine Users List
Subject: Re: problem doing inserts using Criteria and Peer
Then I suggest that your schema is incorrect in that it is not
configuring the id method correctly. Please post your schema
so that we can comment on this.
Scott
brian wrote:
>I tried that method already and it just returns null because the
eventID
>on the Event object isn't set when the other information is saved.
>
>Brian
>
>-----Original Message-----
>From: Scott Eade [mailto:seade@backstagetech.com.au]
>Sent: Friday, September 19, 2003 12:16 AM
>To: Turbine Users List
>Subject: Re: problem doing inserts using Criteria and Peer
>
>brian wrote:
>
>
>
>>I looked but I didn't see a method for retrieving the auto generated
>>value from an insert statement. Is there a way to do this when the
data
>>is saved this way?
>>
>>
>Try:
>
>Event event = new Event();
>event.save();
>int eventId = event.getEventId();
>
>
>Scott
>
>
--
Scott Eade
Backstage Technologies Pty. Ltd.
http://www.backstagetech.com.au
---------------------------------------------------------------------
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
Re: problem doing inserts using Criteria and Peer
Posted by Scott Eade <se...@backstagetech.com.au>.
Then I suggest that your schema is incorrect in that it is not
configuring the id method correctly. Please post your schema
so that we can comment on this.
Scott
brian wrote:
>I tried that method already and it just returns null because the eventID
>on the Event object isn't set when the other information is saved.
>
>Brian
>
>-----Original Message-----
>From: Scott Eade [mailto:seade@backstagetech.com.au]
>Sent: Friday, September 19, 2003 12:16 AM
>To: Turbine Users List
>Subject: Re: problem doing inserts using Criteria and Peer
>
>brian wrote:
>
>
>
>>I looked but I didn't see a method for retrieving the auto generated
>>value from an insert statement. Is there a way to do this when the data
>>is saved this way?
>>
>>
>Try:
>
>Event event = new Event();
>event.save();
>int eventId = event.getEventId();
>
>
>Scott
>
>
--
Scott Eade
Backstage Technologies Pty. Ltd.
http://www.backstagetech.com.au
---------------------------------------------------------------------
To unsubscribe, e-mail: turbine-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: turbine-user-help@jakarta.apache.org
Re: problem doing inserts using Criteria and Peer
Posted by Scott Eade <se...@backstagetech.com.au>.
Then I suggest that your schema is incorrect in that it is not
configuring the id method correctly. Please post your schema
so that we can comment on this.
Scott
brian wrote:
>I tried that method already and it just returns null because the eventID
>on the Event object isn't set when the other information is saved.
>
>Brian
>
>-----Original Message-----
>From: Scott Eade [mailto:seade@backstagetech.com.au]
>Sent: Friday, September 19, 2003 12:16 AM
>To: Turbine Users List
>Subject: Re: problem doing inserts using Criteria and Peer
>
>brian wrote:
>
>
>
>>I looked but I didn't see a method for retrieving the auto generated
>>value from an insert statement. Is there a way to do this when the data
>>is saved this way?
>>
>>
>Try:
>
>Event event = new Event();
>event.save();
>int eventId = event.getEventId();
>
>
>Scott
>
>
--
Scott Eade
Backstage Technologies Pty. Ltd.
http://www.backstagetech.com.au
RE: problem doing inserts using Criteria and Peer
Posted by brian <br...@westpole.com>.
Is there a way to get the auto generated event id
When using this method?
Event event = new Event();
Event.setEventDesc("event description");
event.save();
event.getEventId() returns null because the event id is not updated
with the newly created event id when the save method is invoked.
brian
-----Original Message-----
From: brian [mailto:brian@westpole.com]
Sent: Friday, September 19, 2003 10:33 AM
To: 'Turbine Users List'
Subject: RE: problem doing inserts using Criteria and Peer
I tried that method already and it just returns null because the eventID
on the Event object isn't set when the other information is saved.
Brian
-----Original Message-----
From: Scott Eade [mailto:seade@backstagetech.com.au]
Sent: Friday, September 19, 2003 12:16 AM
To: Turbine Users List
Subject: Re: problem doing inserts using Criteria and Peer
brian wrote:
>I looked but I didn't see a method for retrieving the auto generated
>value from an insert statement. Is there a way to do this when the data
>is saved this way?
>
>
Try:
Event event = new Event();
event.save();
int eventId = event.getEventId();
Scott
--
Scott Eade
Backstage Technologies Pty. Ltd.
http://www.backstagetech.com.au
---------------------------------------------------------------------
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
RE: problem doing inserts using Criteria and Peer
Posted by brian <br...@westpole.com>.
Is there a way to get the auto generated event id
When using this method?
Event event = new Event();
Event.setEventDesc("event description");
event.save();
event.getEventId() returns null because the event id is not updated
with the newly created event id when the save method is invoked.
brian
-----Original Message-----
From: brian [mailto:brian@westpole.com]
Sent: Friday, September 19, 2003 10:33 AM
To: 'Turbine Users List'
Subject: RE: problem doing inserts using Criteria and Peer
I tried that method already and it just returns null because the eventID
on the Event object isn't set when the other information is saved.
Brian
-----Original Message-----
From: Scott Eade [mailto:seade@backstagetech.com.au]
Sent: Friday, September 19, 2003 12:16 AM
To: Turbine Users List
Subject: Re: problem doing inserts using Criteria and Peer
brian wrote:
>I looked but I didn't see a method for retrieving the auto generated
>value from an insert statement. Is there a way to do this when the data
>is saved this way?
>
>
Try:
Event event = new Event();
event.save();
int eventId = event.getEventId();
Scott
--
Scott Eade
Backstage Technologies Pty. Ltd.
http://www.backstagetech.com.au
---------------------------------------------------------------------
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
RE: problem doing inserts using Criteria and Peer
Posted by brian <br...@westpole.com>.
I tried that method already and it just returns null because the eventID
on the Event object isn't set when the other information is saved.
Brian
-----Original Message-----
From: Scott Eade [mailto:seade@backstagetech.com.au]
Sent: Friday, September 19, 2003 12:16 AM
To: Turbine Users List
Subject: Re: problem doing inserts using Criteria and Peer
brian wrote:
>I looked but I didn't see a method for retrieving the auto generated
>value from an insert statement. Is there a way to do this when the data
>is saved this way?
>
>
Try:
Event event = new Event();
event.save();
int eventId = event.getEventId();
Scott
--
Scott Eade
Backstage Technologies Pty. Ltd.
http://www.backstagetech.com.au
---------------------------------------------------------------------
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
RE: problem doing inserts using Criteria and Peer
Posted by brian <br...@westpole.com>.
I tried that method already and it just returns null because the eventID
on the Event object isn't set when the other information is saved.
Brian
-----Original Message-----
From: Scott Eade [mailto:seade@backstagetech.com.au]
Sent: Friday, September 19, 2003 12:16 AM
To: Turbine Users List
Subject: Re: problem doing inserts using Criteria and Peer
brian wrote:
>I looked but I didn't see a method for retrieving the auto generated
>value from an insert statement. Is there a way to do this when the data
>is saved this way?
>
>
Try:
Event event = new Event();
event.save();
int eventId = event.getEventId();
Scott
--
Scott Eade
Backstage Technologies Pty. Ltd.
http://www.backstagetech.com.au
---------------------------------------------------------------------
To unsubscribe, e-mail: turbine-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: turbine-user-help@jakarta.apache.org
Re: problem doing inserts using Criteria and Peer
Posted by Scott Eade <se...@backstagetech.com.au>.
brian wrote:
>I looked but I didn't see a method for retrieving the auto generated
>value from an insert statement. Is there a way to do this when the data
>is saved this way?
>
>
Try:
Event event = new Event();
event.save();
int eventId = event.getEventId();
Scott
--
Scott Eade
Backstage Technologies Pty. Ltd.
http://www.backstagetech.com.au
Re: problem doing inserts using Criteria and Peer
Posted by Scott Eade <se...@backstagetech.com.au>.
brian wrote:
>I looked but I didn't see a method for retrieving the auto generated
>value from an insert statement. Is there a way to do this when the data
>is saved this way?
>
>
Try:
Event event = new Event();
event.save();
int eventId = event.getEventId();
Scott
--
Scott Eade
Backstage Technologies Pty. Ltd.
http://www.backstagetech.com.au
---------------------------------------------------------------------
To unsubscribe, e-mail: turbine-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: turbine-user-help@jakarta.apache.org
RE: problem doing inserts using Criteria and Peer
Posted by brian <br...@westpole.com>.
I looked but I didn't see a method for retrieving the auto generated
value from an insert statement. Is there a way to do this when the data
is saved this way?
-----Original Message-----
From: Dave Everson [mailto:djeverson@mygolftrac.com]
Sent: Thursday, September 18, 2003 7:25 PM
To: Turbine Users List
Subject: Re: problem doing inserts using Criteria and Peer
try something like:
Event event = new Event();
event.setEvntEvtyId(1);
event.save();
----- Original Message -----
From: "brian" <br...@westpole.com>
To: <tu...@jakarta.apache.org>
Sent: Thursday, September 18, 2003 5:39 PM
Subject: problem doing inserts using Criteria and Peer
I am trying to do an insert using :
Criteria crit = new Criteria();
crit.add(EventPeer.EVNT_EVTY_ID,"1");
Object o = EventPeer.doInsert(crit);
But I get a "java.lang.nullPointerException" and this is what I get
when I print out the Criteria object:
Criteria:: event.EVNT_EVTY_ID<=>(event.EVNT_EVTY_ID='1'):
Current Query SQL (may not be complete or applicable): SELECT FROM
event WHERE (event.EVNT_EVTY_ID='1')
I understand that this a select statement but I am following the
directions from the turbine site under "working with peers" for doing
inserts am I doing this correctly?
Thanks,
Brian
---------------------------------------------------------------------
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
RE: problem doing inserts using Criteria and Peer
Posted by brian <br...@westpole.com>.
I looked but I didn't see a method for retrieving the auto generated
value from an insert statement. Is there a way to do this when the data
is saved this way?
-----Original Message-----
From: Dave Everson [mailto:djeverson@mygolftrac.com]
Sent: Thursday, September 18, 2003 7:25 PM
To: Turbine Users List
Subject: Re: problem doing inserts using Criteria and Peer
try something like:
Event event = new Event();
event.setEvntEvtyId(1);
event.save();
----- Original Message -----
From: "brian" <br...@westpole.com>
To: <tu...@jakarta.apache.org>
Sent: Thursday, September 18, 2003 5:39 PM
Subject: problem doing inserts using Criteria and Peer
I am trying to do an insert using :
Criteria crit = new Criteria();
crit.add(EventPeer.EVNT_EVTY_ID,"1");
Object o = EventPeer.doInsert(crit);
But I get a "java.lang.nullPointerException" and this is what I get
when I print out the Criteria object:
Criteria:: event.EVNT_EVTY_ID<=>(event.EVNT_EVTY_ID='1'):
Current Query SQL (may not be complete or applicable): SELECT FROM
event WHERE (event.EVNT_EVTY_ID='1')
I understand that this a select statement but I am following the
directions from the turbine site under "working with peers" for doing
inserts am I doing this correctly?
Thanks,
Brian
---------------------------------------------------------------------
To unsubscribe, e-mail: turbine-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: turbine-user-help@jakarta.apache.org
Re: problem doing inserts using Criteria and Peer
Posted by Dave Everson <dj...@mygolftrac.com>.
try something like:
Event event = new Event();
event.setEvntEvtyId(1);
event.save();
----- Original Message -----
From: "brian" <br...@westpole.com>
To: <tu...@jakarta.apache.org>
Sent: Thursday, September 18, 2003 5:39 PM
Subject: problem doing inserts using Criteria and Peer
I am trying to do an insert using :
Criteria crit = new Criteria();
crit.add(EventPeer.EVNT_EVTY_ID,"1");
Object o = EventPeer.doInsert(crit);
But I get a "java.lang.nullPointerException" and this is what I get
when I print out the Criteria object:
Criteria:: event.EVNT_EVTY_ID<=>(event.EVNT_EVTY_ID='1'):
Current Query SQL (may not be complete or applicable): SELECT FROM
event WHERE (event.EVNT_EVTY_ID='1')
I understand that this a select statement but I am following the
directions from the turbine site under "working with peers" for doing
inserts am I doing this correctly?
Thanks,
Brian
Re: problem doing inserts using Criteria and Peer
Posted by Dave Everson <dj...@mygolftrac.com>.
try something like:
Event event = new Event();
event.setEvntEvtyId(1);
event.save();
----- Original Message -----
From: "brian" <br...@westpole.com>
To: <tu...@jakarta.apache.org>
Sent: Thursday, September 18, 2003 5:39 PM
Subject: problem doing inserts using Criteria and Peer
I am trying to do an insert using :
Criteria crit = new Criteria();
crit.add(EventPeer.EVNT_EVTY_ID,"1");
Object o = EventPeer.doInsert(crit);
But I get a "java.lang.nullPointerException" and this is what I get
when I print out the Criteria object:
Criteria:: event.EVNT_EVTY_ID<=>(event.EVNT_EVTY_ID='1'):
Current Query SQL (may not be complete or applicable): SELECT FROM
event WHERE (event.EVNT_EVTY_ID='1')
I understand that this a select statement but I am following the
directions from the turbine site under "working with peers" for doing
inserts am I doing this correctly?
Thanks,
Brian
---------------------------------------------------------------------
To unsubscribe, e-mail: turbine-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: turbine-user-help@jakarta.apache.org