Hi All,
I am talking about processors in crud.xpl.
crud.xpl is having request generator processor and sql
processor.I want to bring a value from request processor to sql processor.to be
even clear I will explain with my code.I want bring the value highlighted in
red from request processor to sql processor.How can we achive this.Any help
appreciated
Request Processor code
<p:processor name="oxf:request">
<p:input
name="config">
<config stream-type="xs:anyURI">
<include>/request/request-path</include>
<include>/request/content-type</include>
<include>/request/method</include>
<include>/request/headers/header[name = 'orbeon-username' or name =
'orbeon-roles']</include>
<include>/request/body</include>
</config>
</p:input>
<p:output
name="data" id="request"/>
</p:processor>
Sql processor code
<p:processor name="oxf:sql">
.
insert
into <xsl:value-of select="$table-name"/>
(created, last_modified, username, app, form, <xsl:if
test="$is-data">document_id,</xsl:if> deleted,
<xsl:if test="$is-attachment">file_name,
file_content</xsl:if>
<xsl:if test="not($is-attachment)">xml,</xsl:if>userid)
values
(
last_created,
<sql:param type="xs:dateTime"
select="/request/timestamp"/>,
<sql:param type="xs:string"
select="/request/username"/>,
<sql:param type="xs:string" select="/request/app"/>,
<sql:param
type="xs:string" select="/request/form"/>,
<xsl:if test="$is-data">
<sql:param type="xs:string"
select="/request/document-id"/>,
</xsl:if>
'N',
<xsl:if test="$is-attachment">
<sql:param type="xs:string"
select="/request/filename"/>,
<sql:param type="xs:anyURI" select="/request/body"/>
</xsl:if>
<xsl:if test="not($is-attachment)">
XMLType(<sql:param type="odt:xmlFragment"
sql-type="clob" select="/request/document/*"/>)
<!-- See comments above -->
<!--XMLType(<sql:param type="odt:xmlFragment"
sql-type="clob"
select="saxon:parse(/request/document)"/>)-->
</xsl:if>,
<sql:param type="xs:string" select="$ request/headers/header[name
= 'orbeon-username' or name = 'orbeon-roles']"/>
);
end;
Please do not print this email unless it is absolutely necessary.
The information contained in this electronic message and any attachments to this message are intended for the exclusive use of the addressee(s) and may contain proprietary, confidential or privileged information. If you are not the intended recipient, you should not disseminate, distribute or copy this e-mail. Please notify the sender immediately and destroy all copies of this message and any attachments.
WARNING: Computer viruses can be transmitted via email. The recipient should check this email and any attachments for the presence of viruses. The company accepts no liability for any damage caused by any virus transmitted by this email.
www.wipro.com
Free forum by Nabble | Edit this page |