I'm using Microsoft SQL 2000 server and microsoft's JDBC drivers. Is there is other simple way? Like executing a simple "INSERT ... INTO..." SQL command when I click on my button?
-----Original Message----- From: Geoff Howard [mailto:[EMAIL PROTECTED]] Sent: Wednesday, December 11, 2002 2:51 PM To: [EMAIL PROTECTED] Subject: RE: Add/Remove/Edit Sql entries with buttons (using ESQL) To be honest, I don't know how to do this using the regular Database*Actions as you are - you'll have to dig through the docs and search the archives of this list. I have used the modular database actions, which use input/output modules in general and a special series of auto-incr modules to handle each database's particular method. What DB are you using? Does it have a native auto-increment concept? Geoff > -----Original Message----- > From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]] > Sent: Wednesday, December 11, 2002 2:23 AM > To: [EMAIL PROTECTED] > Subject: RE: Add/Remove/Edit Sql entries with buttons (using ESQL) > > > I want to add an entry in my page when I click on : "<input > type="submit" value="Save" name="cocoon-action-Add"/>" And how can I > have an automatic ID? What is wrong in my page? Or in my Sitemap? > Where do I have to write witch connection to use? > > <map:actions> > <map:action name="add-dbentry" > src="org.apache.cocoon.acting.DatabaseAddAction" /> > <map:action name="del-dbentry" > src="org.apache.cocoon.acting.DatabaseDeleteAction" /> > <map:action name="upd-dbentry" > src="org.apache.cocoon.acting.DatabaseUpdateAction" /> > </map:actions> > ... > <map:action-sets> > <map:action-set name="dbentry"> > <map:act type="add-dbentry" action="Add" /> > <map:act type="del-dbentry" action="Delete" /> > <map:act type="upd-dbentry" action="Update" /> > </map:action-set> > </map:action-sets> > ... > <map:pipeline> > <map:match pattern="workflowmax/add-workflow"> > <map:generate type="serverpages" > src="workflowmax/documents/add-workflow.xsp"/> > <map:transform src="stylesheets/dynamic-page2html.xsl"/> > <map:act set="dbentry"/> > <map:serialize/> > </map:match> > </map:pipeline> > ----------------------------------------------------------- > <?xml version="1.0"?> > <xsp:page language="java" > xmlns:xsp="http://apache.org/xsp" > xmlns:esql="http://apache.org/cocoon/SQL/v2" > xmlns:xsp-request="http://apache.org/xsp/request/2.0"> > <page> > <title>Add a Workflow</title> > <content> > <form action="process-dbentry" method="POST"> > <input name="cocoon-action-Add" type="hidden" value="Add"/> > <para>Workflow ID: <input name="ID" type="text"/></para> > <para>Workflow Name: <input name="wfName" type="text"/></para> > <para>Workflow dispatch: <input name="Dispatcher1" > type="text"/></para> > <para>Workflow dispatch2: <input name="Dispatcher2" > type="text"/></para> > <para>Workflow dispatch3: <input name="Dispatcher3" > type="text"/></para> > > <input type="submit" value="Save" name="cocoon-action-Add"/> > </form> > </content> > </page> > </xsp:page> > > --------------------------------------------------------------------- > Please check that your question has not already been answered in the > FAQ before posting. <http://xml.apache.org/cocoon/faq/index.html> > > To unsubscribe, e-mail: <[EMAIL PROTECTED]> > For additional commands, e-mail: <[EMAIL PROTECTED]> > > > --------------------------------------------------------------------- Please check that your question has not already been answered in the FAQ before posting. <http://xml.apache.org/cocoon/faq/index.html> To unsubscribe, e-mail: <[EMAIL PROTECTED]> For additional commands, e-mail: <[EMAIL PROTECTED]> --------------------------------------------------------------------- Please check that your question has not already been answered in the FAQ before posting. <http://xml.apache.org/cocoon/faq/index.html> To unsubscribe, e-mail: <[EMAIL PROTECTED]> For additional commands, e-mail: <[EMAIL PROTECTED]>