1*d1766043SAndrew Rist/**************************************************************
2cdf0e10cSrcweir *
3*d1766043SAndrew Rist * Licensed to the Apache Software Foundation (ASF) under one
4*d1766043SAndrew Rist * or more contributor license agreements.  See the NOTICE file
5*d1766043SAndrew Rist * distributed with this work for additional information
6*d1766043SAndrew Rist * regarding copyright ownership.  The ASF licenses this file
7*d1766043SAndrew Rist * to you under the Apache License, Version 2.0 (the
8*d1766043SAndrew Rist * "License"); you may not use this file except in compliance
9*d1766043SAndrew Rist * with the License.  You may obtain a copy of the License at
10*d1766043SAndrew Rist *
11*d1766043SAndrew Rist *   http://www.apache.org/licenses/LICENSE-2.0
12*d1766043SAndrew Rist *
13*d1766043SAndrew Rist * Unless required by applicable law or agreed to in writing,
14*d1766043SAndrew Rist * software distributed under the License is distributed on an
15*d1766043SAndrew Rist * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
16*d1766043SAndrew Rist * KIND, either express or implied.  See the License for the
17*d1766043SAndrew Rist * specific language governing permissions and limitations
18*d1766043SAndrew Rist * under the License.
19*d1766043SAndrew Rist *
20*d1766043SAndrew Rist *************************************************************/
21*d1766043SAndrew Rist
22*d1766043SAndrew Rist
23cdf0e10cSrcweir#ifndef __com_sun_star_sdbc_CallableStatement_idl__
24cdf0e10cSrcweir#define __com_sun_star_sdbc_CallableStatement_idl__
25cdf0e10cSrcweir
26cdf0e10cSrcweir#ifndef __com_sun_star_sdbc_PreparedStatement_idl__
27cdf0e10cSrcweir#include <com/sun/star/sdbc/PreparedStatement.idl>
28cdf0e10cSrcweir#endif
29cdf0e10cSrcweir
30cdf0e10cSrcweir module com {  module sun {  module star {  module sdbc {
31cdf0e10cSrcweir
32cdf0e10cSrcweir published interface XRow;
33cdf0e10cSrcweir published interface XOutParameters;
34cdf0e10cSrcweir
35cdf0e10cSrcweir
36cdf0e10cSrcweir/** is used to execute SQL stored procedures.
37cdf0e10cSrcweir
38cdf0e10cSrcweir
39cdf0e10cSrcweir	<p>
40cdf0e10cSrcweir	SDBC provides a stored procedure SQL escape that allows stored procedures
41cdf0e10cSrcweir	to be called in a standard way for all RDBMSs. This escape syntax has one
42cdf0e10cSrcweir	form that includes a result parameter and one that does not. If used, the
43cdf0e10cSrcweir	result parameter must be registered as an OUT parameter. The other parameters
44cdf0e10cSrcweir	can be used for input, output, or both. Parameters are referred to sequentially,
45cdf0e10cSrcweir	by number. The first parameter is 1.
46cdf0e10cSrcweir	</p>
47cdf0e10cSrcweir	<p>
48cdf0e10cSrcweir	<code>{?=call&amp;lt;procedure-name&amp;gt;[&amp;lt;arg1&amp;gt;,&amp;lt;arg2&amp;gt;,...]}<br/>{call&amp;lt;procedure-name&amp;gt;[&amp;lt;arg1&amp;gt;,&amp;lt;arg2&amp;gt;,...]}
49cdf0e10cSrcweir	</code>
50cdf0e10cSrcweir	</p>
51cdf0e10cSrcweir	<p>
52cdf0e10cSrcweir	IN parameter values are set using the set methods inherited from
53cdf0e10cSrcweir	<type scope="com::sun::star::sdbc">PreparedStatement</type>
54cdf0e10cSrcweir	. The type of all
55cdf0e10cSrcweir	OUT parameters must be registered prior to executing the stored procedure;
56cdf0e10cSrcweir	their values are retrieved after execution via the
57cdf0e10cSrcweir	<code>get</code>
58cdf0e10cSrcweir	methods
59cdf0e10cSrcweir	provided by the
60cdf0e10cSrcweir	<type scope="com::sun::star::sdbc">XRow</type>
61cdf0e10cSrcweir	.
62cdf0e10cSrcweir	</p>
63cdf0e10cSrcweir	<p>
64cdf0e10cSrcweir	A
65cdf0e10cSrcweir	<code>CallableStatement</code>
66cdf0e10cSrcweir	can return one
67cdf0e10cSrcweir	<type scope="com::sun::star::sdbc">XResultSet</type>
68cdf0e10cSrcweir	or multiple
69cdf0e10cSrcweir	<type scope="com::sun::star::sdbc">ResultSet</type>
70cdf0e10cSrcweir	objects. Multiple
71cdf0e10cSrcweir	<code>ResultSet</code>
72cdf0e10cSrcweir	objects are
73cdf0e10cSrcweir	handled using operations inherited from
74cdf0e10cSrcweir	<type scope="com::sun::star::sdbc">XPreparedStatement</type>
75cdf0e10cSrcweir	.
76cdf0e10cSrcweir	</p>
77cdf0e10cSrcweir	<p>
78cdf0e10cSrcweir	For maximum portability, a call's
79cdf0e10cSrcweir	<type scope="com::sun::star::sdbc">ResultSet</type>
80cdf0e10cSrcweir	objects and
81cdf0e10cSrcweir	update counts should be processed prior to getting the values of output
82cdf0e10cSrcweir	parameters.
83cdf0e10cSrcweir	</p>
84cdf0e10cSrcweir*/
85cdf0e10cSrcweirpublished service CallableStatement
86cdf0e10cSrcweir{
87cdf0e10cSrcweir	service PreparedStatement;
88cdf0e10cSrcweir
89cdf0e10cSrcweir
90cdf0e10cSrcweir	/** is used for retrieve the values of OUT parameters.
91cdf0e10cSrcweir	 */
92cdf0e10cSrcweir	interface XRow;
93cdf0e10cSrcweir
94cdf0e10cSrcweir
95cdf0e10cSrcweir	/** is used to declare parameters as OUT parameters.
96cdf0e10cSrcweir	 */
97cdf0e10cSrcweir	interface XOutParameters;
98cdf0e10cSrcweir};
99cdf0e10cSrcweir
100cdf0e10cSrcweir//=============================================================================
101cdf0e10cSrcweir
102cdf0e10cSrcweir}; }; }; };
103cdf0e10cSrcweir
104cdf0e10cSrcweir/*===========================================================================
105cdf0e10cSrcweir===========================================================================*/
106cdf0e10cSrcweir#endif
107