1*9b5730f6SAndrew Rist /**************************************************************
2cdf0e10cSrcweir  *
3*9b5730f6SAndrew Rist  * Licensed to the Apache Software Foundation (ASF) under one
4*9b5730f6SAndrew Rist  * or more contributor license agreements.  See the NOTICE file
5*9b5730f6SAndrew Rist  * distributed with this work for additional information
6*9b5730f6SAndrew Rist  * regarding copyright ownership.  The ASF licenses this file
7*9b5730f6SAndrew Rist  * to you under the Apache License, Version 2.0 (the
8*9b5730f6SAndrew Rist  * "License"); you may not use this file except in compliance
9*9b5730f6SAndrew Rist  * with the License.  You may obtain a copy of the License at
10*9b5730f6SAndrew Rist  *
11*9b5730f6SAndrew Rist  *   http://www.apache.org/licenses/LICENSE-2.0
12*9b5730f6SAndrew Rist  *
13*9b5730f6SAndrew Rist  * Unless required by applicable law or agreed to in writing,
14*9b5730f6SAndrew Rist  * software distributed under the License is distributed on an
15*9b5730f6SAndrew Rist  * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
16*9b5730f6SAndrew Rist  * KIND, either express or implied.  See the License for the
17*9b5730f6SAndrew Rist  * specific language governing permissions and limitations
18*9b5730f6SAndrew Rist  * under the License.
19*9b5730f6SAndrew Rist  *
20*9b5730f6SAndrew Rist  *************************************************************/
21*9b5730f6SAndrew Rist 
22*9b5730f6SAndrew Rist 
23cdf0e10cSrcweir 
24cdf0e10cSrcweir // MARKER(update_precomp.py): autogen include statement, do not remove
25cdf0e10cSrcweir #include "precompiled_connectivity.hxx"
26cdf0e10cSrcweir 
27cdf0e10cSrcweir #include "MacabPreparedStatement.hxx"
28cdf0e10cSrcweir #include "MacabAddressBook.hxx"
29cdf0e10cSrcweir #include "propertyids.hxx"
30cdf0e10cSrcweir #include <connectivity/dbexception.hxx>
31cdf0e10cSrcweir #include "connectivity/dbtools.hxx"
32cdf0e10cSrcweir #include "resource/macab_res.hrc"
33cdf0e10cSrcweir #include "resource/sharedresources.hxx"
34cdf0e10cSrcweir 
35cdf0e10cSrcweir using namespace connectivity::macab;
36cdf0e10cSrcweir using namespace com::sun::star::uno;
37cdf0e10cSrcweir using namespace com::sun::star::lang;
38cdf0e10cSrcweir using namespace com::sun::star::sdbc;
39cdf0e10cSrcweir using namespace com::sun::star::util;
40cdf0e10cSrcweir 
41cdf0e10cSrcweir IMPLEMENT_SERVICE_INFO(MacabPreparedStatement, "com.sun.star.sdbc.drivers.MacabPreparedStatement", "com.sun.star.sdbc.PreparedStatement");
42cdf0e10cSrcweir // -------------------------------------------------------------------------
checkAndResizeParameters(sal_Int32 nParams)43cdf0e10cSrcweir void MacabPreparedStatement::checkAndResizeParameters(sal_Int32 nParams) throw(SQLException)
44cdf0e10cSrcweir {
45cdf0e10cSrcweir 	if ( !m_aParameterRow.isValid() )
46cdf0e10cSrcweir 		m_aParameterRow = new OValueVector();
47cdf0e10cSrcweir 
48cdf0e10cSrcweir 	if (nParams < 1)
49cdf0e10cSrcweir 		::dbtools::throwInvalidIndexException(*(MacabPreparedStatement *) this,Any());
50cdf0e10cSrcweir 
51cdf0e10cSrcweir 	if (nParams >= (sal_Int32) (m_aParameterRow->get()).size())
52cdf0e10cSrcweir 		(m_aParameterRow->get()).resize(nParams);
53cdf0e10cSrcweir }
54cdf0e10cSrcweir // -------------------------------------------------------------------------
setMacabFields() const55cdf0e10cSrcweir void MacabPreparedStatement::setMacabFields() const throw(SQLException)
56cdf0e10cSrcweir {
57cdf0e10cSrcweir 	::vos::ORef<connectivity::OSQLColumns> xColumns;	// selected columns
58cdf0e10cSrcweir 
59cdf0e10cSrcweir 	xColumns = m_aSQLIterator.getSelectColumns();
60cdf0e10cSrcweir 	if (!xColumns.isValid())
61cdf0e10cSrcweir 	{
62cdf0e10cSrcweir 		::connectivity::SharedResources aResources;
63cdf0e10cSrcweir         const ::rtl::OUString sError( aResources.getResourceString(
64cdf0e10cSrcweir                 STR_INVALID_COLUMN_SELECTION
65cdf0e10cSrcweir              ) );
66cdf0e10cSrcweir 	    ::dbtools::throwGenericSQLException(sError,NULL);
67cdf0e10cSrcweir 	}
68cdf0e10cSrcweir 	m_xMetaData->setMacabFields(xColumns);
69cdf0e10cSrcweir }
70cdf0e10cSrcweir // -------------------------------------------------------------------------
resetParameters() const71cdf0e10cSrcweir void MacabPreparedStatement::resetParameters() const throw(SQLException)
72cdf0e10cSrcweir {
73cdf0e10cSrcweir 	m_nParameterIndex = 0;
74cdf0e10cSrcweir }
75cdf0e10cSrcweir // -------------------------------------------------------------------------
getNextParameter(::rtl::OUString & rParameter) const76cdf0e10cSrcweir void MacabPreparedStatement::getNextParameter(::rtl::OUString &rParameter) const throw(SQLException)
77cdf0e10cSrcweir {
78cdf0e10cSrcweir 	if (m_nParameterIndex >= (sal_Int32) (m_aParameterRow->get()).size())
79cdf0e10cSrcweir     {
80cdf0e10cSrcweir         ::connectivity::SharedResources aResources;
81cdf0e10cSrcweir         const ::rtl::OUString sError( aResources.getResourceString(
82cdf0e10cSrcweir                 STR_INVALID_PARA_COUNT
83cdf0e10cSrcweir              ) );
84cdf0e10cSrcweir 	    ::dbtools::throwGenericSQLException(sError,*(MacabPreparedStatement *) this);
85cdf0e10cSrcweir     }
86cdf0e10cSrcweir 
87cdf0e10cSrcweir 	rParameter = (m_aParameterRow->get())[m_nParameterIndex];
88cdf0e10cSrcweir 
89cdf0e10cSrcweir 	m_nParameterIndex++;
90cdf0e10cSrcweir }
91cdf0e10cSrcweir // -------------------------------------------------------------------------
MacabPreparedStatement(MacabConnection * _pConnection,const::rtl::OUString & sql)92cdf0e10cSrcweir MacabPreparedStatement::MacabPreparedStatement(
93cdf0e10cSrcweir 	MacabConnection* _pConnection,
94cdf0e10cSrcweir 	const ::rtl::OUString& sql)
95cdf0e10cSrcweir 	: MacabPreparedStatement_BASE(_pConnection),
96cdf0e10cSrcweir 	  m_sSqlStatement(sql),
97cdf0e10cSrcweir 	  m_bPrepared(sal_False),
98cdf0e10cSrcweir 	  m_nParameterIndex(0),
99cdf0e10cSrcweir 	  m_aParameterRow()
100cdf0e10cSrcweir {
101cdf0e10cSrcweir 
102cdf0e10cSrcweir }
103cdf0e10cSrcweir // -------------------------------------------------------------------------
~MacabPreparedStatement()104cdf0e10cSrcweir MacabPreparedStatement::~MacabPreparedStatement()
105cdf0e10cSrcweir {
106cdf0e10cSrcweir }
107cdf0e10cSrcweir // -------------------------------------------------------------------------
disposing()108cdf0e10cSrcweir void MacabPreparedStatement::disposing()
109cdf0e10cSrcweir {
110cdf0e10cSrcweir 	MacabPreparedStatement_BASE::disposing();
111cdf0e10cSrcweir 
112cdf0e10cSrcweir 	if (m_aParameterRow.isValid())
113cdf0e10cSrcweir 	{
114cdf0e10cSrcweir 		m_aParameterRow->get().clear();
115cdf0e10cSrcweir 		m_aParameterRow = NULL;
116cdf0e10cSrcweir 	}
117cdf0e10cSrcweir }
118cdf0e10cSrcweir // -------------------------------------------------------------------------
getMetaData()119cdf0e10cSrcweir Reference< XResultSetMetaData > SAL_CALL MacabPreparedStatement::getMetaData() throw(SQLException, RuntimeException)
120cdf0e10cSrcweir {
121cdf0e10cSrcweir 	::osl::MutexGuard aGuard( m_aMutex );
122cdf0e10cSrcweir 	checkDisposed(MacabCommonStatement_BASE::rBHelper.bDisposed);
123cdf0e10cSrcweir 
124cdf0e10cSrcweir 	if (!m_xMetaData.is())
125cdf0e10cSrcweir 	{
126cdf0e10cSrcweir 		const OSQLTables& xTabs = m_aSQLIterator.getTables();
127cdf0e10cSrcweir 		::rtl::OUString sTableName = MacabAddressBook::getDefaultTableName();
128cdf0e10cSrcweir 
129cdf0e10cSrcweir 		if(! xTabs.empty() )
130cdf0e10cSrcweir 		{
131cdf0e10cSrcweir 
132cdf0e10cSrcweir 			// can only deal with one table at a time
133cdf0e10cSrcweir 			if(xTabs.size() == 1 && !m_aSQLIterator.hasErrors() )
134cdf0e10cSrcweir 				sTableName = xTabs.begin()->first;
135cdf0e10cSrcweir 
136cdf0e10cSrcweir 		}
137cdf0e10cSrcweir 		m_xMetaData = new MacabResultSetMetaData(getOwnConnection(),sTableName);
138cdf0e10cSrcweir 		setMacabFields();
139cdf0e10cSrcweir 	}
140cdf0e10cSrcweir 	Reference< XResultSetMetaData > xMetaData = m_xMetaData.get();
141cdf0e10cSrcweir 	return xMetaData;
142cdf0e10cSrcweir }
143cdf0e10cSrcweir // -------------------------------------------------------------------------
close()144cdf0e10cSrcweir void SAL_CALL MacabPreparedStatement::close() throw(SQLException, RuntimeException)
145cdf0e10cSrcweir {
146cdf0e10cSrcweir 	::osl::MutexGuard aGuard( m_aMutex );
147cdf0e10cSrcweir 	checkDisposed(MacabCommonStatement_BASE::rBHelper.bDisposed);
148cdf0e10cSrcweir 
149cdf0e10cSrcweir 	// Reset last warning message
150cdf0e10cSrcweir 	try {
151cdf0e10cSrcweir 		clearWarnings ();
152cdf0e10cSrcweir 		MacabCommonStatement::close();
153cdf0e10cSrcweir 	}
154cdf0e10cSrcweir 	catch (SQLException &) {
155cdf0e10cSrcweir 		// If we get an error, ignore
156cdf0e10cSrcweir 	}
157cdf0e10cSrcweir 
158cdf0e10cSrcweir 	// Remove this Statement object from the Connection object's
159cdf0e10cSrcweir 	// list
160cdf0e10cSrcweir }
161cdf0e10cSrcweir // -------------------------------------------------------------------------
execute()162cdf0e10cSrcweir sal_Bool SAL_CALL MacabPreparedStatement::execute() throw(SQLException, RuntimeException)
163cdf0e10cSrcweir {
164cdf0e10cSrcweir 	::osl::MutexGuard aGuard( m_aMutex );
165cdf0e10cSrcweir 	checkDisposed(MacabCommonStatement_BASE::rBHelper.bDisposed);
166cdf0e10cSrcweir 
167cdf0e10cSrcweir 	Reference< XResultSet> xRS = MacabCommonStatement::executeQuery(m_sSqlStatement);
168cdf0e10cSrcweir 
169cdf0e10cSrcweir 	return xRS.is();
170cdf0e10cSrcweir }
171cdf0e10cSrcweir // -------------------------------------------------------------------------
executeUpdate()172cdf0e10cSrcweir sal_Int32 SAL_CALL MacabPreparedStatement::executeUpdate() throw(SQLException, RuntimeException)
173cdf0e10cSrcweir {
174cdf0e10cSrcweir 	::osl::MutexGuard aGuard( m_aMutex );
175cdf0e10cSrcweir 	checkDisposed(MacabCommonStatement_BASE::rBHelper.bDisposed);
176cdf0e10cSrcweir 
177cdf0e10cSrcweir 	// same as in statement with the difference that this statement also can contain parameter
178cdf0e10cSrcweir 	return 0;
179cdf0e10cSrcweir }
180cdf0e10cSrcweir // -------------------------------------------------------------------------
getConnection()181cdf0e10cSrcweir Reference< XConnection > SAL_CALL MacabPreparedStatement::getConnection() throw(SQLException, RuntimeException)
182cdf0e10cSrcweir {
183cdf0e10cSrcweir 	::osl::MutexGuard aGuard( m_aMutex );
184cdf0e10cSrcweir 	checkDisposed(MacabCommonStatement_BASE::rBHelper.bDisposed);
185cdf0e10cSrcweir 
186cdf0e10cSrcweir 	return (Reference< XConnection >) m_pConnection;
187cdf0e10cSrcweir }
188cdf0e10cSrcweir // -------------------------------------------------------------------------
executeQuery()189cdf0e10cSrcweir Reference< XResultSet > SAL_CALL MacabPreparedStatement::executeQuery() throw(SQLException, RuntimeException)
190cdf0e10cSrcweir {
191cdf0e10cSrcweir 	::osl::MutexGuard aGuard( m_aMutex );
192cdf0e10cSrcweir 	checkDisposed(MacabCommonStatement_BASE::rBHelper.bDisposed);
193cdf0e10cSrcweir 
194cdf0e10cSrcweir 	Reference< XResultSet > rs = MacabCommonStatement::executeQuery(m_sSqlStatement);
195cdf0e10cSrcweir 
196cdf0e10cSrcweir 	return rs;
197cdf0e10cSrcweir }
198cdf0e10cSrcweir // -------------------------------------------------------------------------
setNull(sal_Int32 parameterIndex,sal_Int32)199cdf0e10cSrcweir void SAL_CALL MacabPreparedStatement::setNull(sal_Int32 parameterIndex, sal_Int32) throw(SQLException, RuntimeException)
200cdf0e10cSrcweir {
201cdf0e10cSrcweir 	::osl::MutexGuard aGuard( m_aMutex );
202cdf0e10cSrcweir 	checkDisposed(MacabCommonStatement_BASE::rBHelper.bDisposed);
203cdf0e10cSrcweir 
204cdf0e10cSrcweir 	checkAndResizeParameters(parameterIndex);
205cdf0e10cSrcweir 
206cdf0e10cSrcweir 	(m_aParameterRow->get())[parameterIndex - 1].setNull();
207cdf0e10cSrcweir }
208cdf0e10cSrcweir // -------------------------------------------------------------------------
setObjectNull(sal_Int32,sal_Int32,const::rtl::OUString &)209cdf0e10cSrcweir void SAL_CALL MacabPreparedStatement::setObjectNull(sal_Int32, sal_Int32, const ::rtl::OUString&) throw(SQLException, RuntimeException)
210cdf0e10cSrcweir {
211cdf0e10cSrcweir 
212cdf0e10cSrcweir 
213cdf0e10cSrcweir 
214cdf0e10cSrcweir ::dbtools::throwFunctionNotSupportedException("setObjectNull", NULL);
215cdf0e10cSrcweir }
216cdf0e10cSrcweir // -------------------------------------------------------------------------
setBoolean(sal_Int32,sal_Bool)217cdf0e10cSrcweir void SAL_CALL MacabPreparedStatement::setBoolean(sal_Int32, sal_Bool) throw(SQLException, RuntimeException)
218cdf0e10cSrcweir {
219cdf0e10cSrcweir 
220cdf0e10cSrcweir 
221cdf0e10cSrcweir 
222cdf0e10cSrcweir ::dbtools::throwFunctionNotSupportedException("setBoolean", NULL);
223cdf0e10cSrcweir }
224cdf0e10cSrcweir // -------------------------------------------------------------------------
setByte(sal_Int32,sal_Int8)225cdf0e10cSrcweir void SAL_CALL MacabPreparedStatement::setByte(sal_Int32, sal_Int8) throw(SQLException, RuntimeException)
226cdf0e10cSrcweir {
227cdf0e10cSrcweir 
228cdf0e10cSrcweir 
229cdf0e10cSrcweir 
230cdf0e10cSrcweir ::dbtools::throwFunctionNotSupportedException("setByte", NULL);
231cdf0e10cSrcweir }
232cdf0e10cSrcweir // -------------------------------------------------------------------------
setShort(sal_Int32,sal_Int16)233cdf0e10cSrcweir void SAL_CALL MacabPreparedStatement::setShort(sal_Int32, sal_Int16) throw(SQLException, RuntimeException)
234cdf0e10cSrcweir {
235cdf0e10cSrcweir 
236cdf0e10cSrcweir 
237cdf0e10cSrcweir 
238cdf0e10cSrcweir ::dbtools::throwFunctionNotSupportedException("setShort", NULL);
239cdf0e10cSrcweir }
240cdf0e10cSrcweir // -------------------------------------------------------------------------
setInt(sal_Int32,sal_Int32)241cdf0e10cSrcweir void SAL_CALL MacabPreparedStatement::setInt(sal_Int32, sal_Int32) throw(SQLException, RuntimeException)
242cdf0e10cSrcweir {
243cdf0e10cSrcweir 
244cdf0e10cSrcweir 
245cdf0e10cSrcweir 
246cdf0e10cSrcweir ::dbtools::throwFunctionNotSupportedException("setInt", NULL);
247cdf0e10cSrcweir }
248cdf0e10cSrcweir // -------------------------------------------------------------------------
setLong(sal_Int32,sal_Int64)249cdf0e10cSrcweir void SAL_CALL MacabPreparedStatement::setLong(sal_Int32, sal_Int64) throw(SQLException, RuntimeException)
250cdf0e10cSrcweir {
251cdf0e10cSrcweir 
252cdf0e10cSrcweir 
253cdf0e10cSrcweir 
254cdf0e10cSrcweir ::dbtools::throwFunctionNotSupportedException("setLong", NULL);
255cdf0e10cSrcweir }
256cdf0e10cSrcweir // -------------------------------------------------------------------------
setFloat(sal_Int32,float)257cdf0e10cSrcweir void SAL_CALL MacabPreparedStatement::setFloat(sal_Int32, float) throw(SQLException, RuntimeException)
258cdf0e10cSrcweir {
259cdf0e10cSrcweir 
260cdf0e10cSrcweir 
261cdf0e10cSrcweir 
262cdf0e10cSrcweir ::dbtools::throwFunctionNotSupportedException("setFloat", NULL);
263cdf0e10cSrcweir }
264cdf0e10cSrcweir // -------------------------------------------------------------------------
setDouble(sal_Int32,double)265cdf0e10cSrcweir void SAL_CALL MacabPreparedStatement::setDouble(sal_Int32, double) throw(SQLException, RuntimeException)
266cdf0e10cSrcweir {
267cdf0e10cSrcweir 
268cdf0e10cSrcweir 
269cdf0e10cSrcweir 
270cdf0e10cSrcweir ::dbtools::throwFunctionNotSupportedException("setDouble", NULL);
271cdf0e10cSrcweir }
272cdf0e10cSrcweir // -------------------------------------------------------------------------
setString(sal_Int32 parameterIndex,const::rtl::OUString & x)273cdf0e10cSrcweir void SAL_CALL MacabPreparedStatement::setString(sal_Int32 parameterIndex, const ::rtl::OUString &x) throw(SQLException, RuntimeException)
274cdf0e10cSrcweir {
275cdf0e10cSrcweir 	::osl::MutexGuard aGuard( m_aMutex );
276cdf0e10cSrcweir 	checkDisposed(MacabCommonStatement_BASE::rBHelper.bDisposed);
277cdf0e10cSrcweir 
278cdf0e10cSrcweir 	checkAndResizeParameters(parameterIndex);
279cdf0e10cSrcweir 
280cdf0e10cSrcweir 	(m_aParameterRow->get())[parameterIndex - 1] = x;
281cdf0e10cSrcweir }
282cdf0e10cSrcweir // -------------------------------------------------------------------------
setBytes(sal_Int32,const Sequence<sal_Int8> &)283cdf0e10cSrcweir void SAL_CALL MacabPreparedStatement::setBytes(sal_Int32, const Sequence< sal_Int8 >&) throw(SQLException, RuntimeException)
284cdf0e10cSrcweir {
285cdf0e10cSrcweir 
286cdf0e10cSrcweir 
287cdf0e10cSrcweir 
288cdf0e10cSrcweir ::dbtools::throwFunctionNotSupportedException("setBytes", NULL);
289cdf0e10cSrcweir }
290cdf0e10cSrcweir // -------------------------------------------------------------------------
setDate(sal_Int32,const Date &)291cdf0e10cSrcweir void SAL_CALL MacabPreparedStatement::setDate(sal_Int32, const Date&) throw(SQLException, RuntimeException)
292cdf0e10cSrcweir {
293cdf0e10cSrcweir 
294cdf0e10cSrcweir 
295cdf0e10cSrcweir 
296cdf0e10cSrcweir ::dbtools::throwFunctionNotSupportedException("setDate", NULL);
297cdf0e10cSrcweir }
298cdf0e10cSrcweir // -------------------------------------------------------------------------
setTime(sal_Int32,const Time &)299cdf0e10cSrcweir void SAL_CALL MacabPreparedStatement::setTime(sal_Int32, const Time&) throw(SQLException, RuntimeException)
300cdf0e10cSrcweir {
301cdf0e10cSrcweir 
302cdf0e10cSrcweir 
303cdf0e10cSrcweir 
304cdf0e10cSrcweir ::dbtools::throwFunctionNotSupportedException("setTime", NULL);
305cdf0e10cSrcweir }
306cdf0e10cSrcweir // -------------------------------------------------------------------------
setTimestamp(sal_Int32,const DateTime &)307cdf0e10cSrcweir void SAL_CALL MacabPreparedStatement::setTimestamp(sal_Int32, const DateTime&) throw(SQLException, RuntimeException)
308cdf0e10cSrcweir {
309cdf0e10cSrcweir 
310cdf0e10cSrcweir 
311cdf0e10cSrcweir 
312cdf0e10cSrcweir ::dbtools::throwFunctionNotSupportedException("setTimestamp", NULL);
313cdf0e10cSrcweir }
314cdf0e10cSrcweir // -------------------------------------------------------------------------
setBinaryStream(sal_Int32,const Reference<::com::sun::star::io::XInputStream> &,sal_Int32)315cdf0e10cSrcweir void SAL_CALL MacabPreparedStatement::setBinaryStream(sal_Int32, const Reference< ::com::sun::star::io::XInputStream >&, sal_Int32) throw(SQLException, RuntimeException)
316cdf0e10cSrcweir {
317cdf0e10cSrcweir 
318cdf0e10cSrcweir 
319cdf0e10cSrcweir 
320cdf0e10cSrcweir ::dbtools::throwFunctionNotSupportedException("setBinaryStream", NULL);
321cdf0e10cSrcweir }
322cdf0e10cSrcweir // -------------------------------------------------------------------------
setCharacterStream(sal_Int32,const Reference<::com::sun::star::io::XInputStream> &,sal_Int32)323cdf0e10cSrcweir void SAL_CALL MacabPreparedStatement::setCharacterStream(sal_Int32, const Reference< ::com::sun::star::io::XInputStream >&, sal_Int32) throw(SQLException, RuntimeException)
324cdf0e10cSrcweir {
325cdf0e10cSrcweir 
326cdf0e10cSrcweir 
327cdf0e10cSrcweir 
328cdf0e10cSrcweir ::dbtools::throwFunctionNotSupportedException("setCharacterStream", NULL);
329cdf0e10cSrcweir }
330cdf0e10cSrcweir // -------------------------------------------------------------------------
setObject(sal_Int32 parameterIndex,const Any & x)331cdf0e10cSrcweir void SAL_CALL MacabPreparedStatement::setObject(sal_Int32 parameterIndex, const Any& x) throw(SQLException, RuntimeException)
332cdf0e10cSrcweir {
333cdf0e10cSrcweir 	if(!::dbtools::implSetObject(this,parameterIndex,x))
334cdf0e10cSrcweir 	{
335cdf0e10cSrcweir         const ::rtl::OUString sError( m_pConnection->getResources().getResourceStringWithSubstitution(
336cdf0e10cSrcweir                 STR_UNKNOWN_PARA_TYPE,
337cdf0e10cSrcweir                 "$position$", ::rtl::OUString::valueOf(parameterIndex)
338cdf0e10cSrcweir              ) );
339cdf0e10cSrcweir 		::dbtools::throwGenericSQLException(sError,*this);
340cdf0e10cSrcweir 	}
341cdf0e10cSrcweir }
342cdf0e10cSrcweir // -------------------------------------------------------------------------
setObjectWithInfo(sal_Int32,const Any &,sal_Int32,sal_Int32)343cdf0e10cSrcweir void SAL_CALL MacabPreparedStatement::setObjectWithInfo(sal_Int32, const Any&, sal_Int32, sal_Int32) throw(SQLException, RuntimeException)
344cdf0e10cSrcweir {
345cdf0e10cSrcweir 
346cdf0e10cSrcweir 
347cdf0e10cSrcweir 
348cdf0e10cSrcweir ::dbtools::throwFunctionNotSupportedException("setObjectWithInfo", NULL);
349cdf0e10cSrcweir }
350cdf0e10cSrcweir // -------------------------------------------------------------------------
setRef(sal_Int32,const Reference<XRef> &)351cdf0e10cSrcweir void SAL_CALL MacabPreparedStatement::setRef(sal_Int32, const Reference< XRef >&) throw(SQLException, RuntimeException)
352cdf0e10cSrcweir {
353cdf0e10cSrcweir 
354cdf0e10cSrcweir 
355cdf0e10cSrcweir 
356cdf0e10cSrcweir ::dbtools::throwFunctionNotSupportedException("setRef", NULL);
357cdf0e10cSrcweir }
358cdf0e10cSrcweir // -------------------------------------------------------------------------
setBlob(sal_Int32,const Reference<XBlob> &)359cdf0e10cSrcweir void SAL_CALL MacabPreparedStatement::setBlob(sal_Int32, const Reference< XBlob >&) throw(SQLException, RuntimeException)
360cdf0e10cSrcweir {
361cdf0e10cSrcweir 
362cdf0e10cSrcweir 
363cdf0e10cSrcweir 
364cdf0e10cSrcweir ::dbtools::throwFunctionNotSupportedException("setBlob", NULL);
365cdf0e10cSrcweir }
366cdf0e10cSrcweir // -------------------------------------------------------------------------
setClob(sal_Int32,const Reference<XClob> &)367cdf0e10cSrcweir void SAL_CALL MacabPreparedStatement::setClob(sal_Int32, const Reference< XClob >&) throw(SQLException, RuntimeException)
368cdf0e10cSrcweir {
369cdf0e10cSrcweir 
370cdf0e10cSrcweir 
371cdf0e10cSrcweir 
372cdf0e10cSrcweir ::dbtools::throwFunctionNotSupportedException("setClob", NULL);
373cdf0e10cSrcweir }
374cdf0e10cSrcweir // -------------------------------------------------------------------------
setArray(sal_Int32,const Reference<XArray> &)375cdf0e10cSrcweir void SAL_CALL MacabPreparedStatement::setArray(sal_Int32, const Reference< XArray >&) throw(SQLException, RuntimeException)
376cdf0e10cSrcweir {
377cdf0e10cSrcweir 
378cdf0e10cSrcweir 
379cdf0e10cSrcweir 
380cdf0e10cSrcweir ::dbtools::throwFunctionNotSupportedException("setArray", NULL);
381cdf0e10cSrcweir }
382cdf0e10cSrcweir // -------------------------------------------------------------------------
clearParameters()383cdf0e10cSrcweir void SAL_CALL MacabPreparedStatement::clearParameters() throw(SQLException, RuntimeException)
384cdf0e10cSrcweir {
385cdf0e10cSrcweir ::dbtools::throwFunctionNotSupportedException("clearParameters", NULL);
386cdf0e10cSrcweir }
387cdf0e10cSrcweir // -------------------------------------------------------------------------
setFastPropertyValue_NoBroadcast(sal_Int32 nHandle,const Any & rValue)388cdf0e10cSrcweir void MacabPreparedStatement::setFastPropertyValue_NoBroadcast(sal_Int32 nHandle,const Any& rValue) throw (Exception)
389cdf0e10cSrcweir {
390cdf0e10cSrcweir 	switch (nHandle)
391cdf0e10cSrcweir 	{
392cdf0e10cSrcweir 		case PROPERTY_ID_RESULTSETCONCURRENCY:
393cdf0e10cSrcweir 			break;
394cdf0e10cSrcweir 		case PROPERTY_ID_RESULTSETTYPE:
395cdf0e10cSrcweir 			break;
396cdf0e10cSrcweir 		case PROPERTY_ID_FETCHDIRECTION:
397cdf0e10cSrcweir 			break;
398cdf0e10cSrcweir 		case PROPERTY_ID_USEBOOKMARKS:
399cdf0e10cSrcweir 			break;
400cdf0e10cSrcweir 		default:
401cdf0e10cSrcweir 			MacabCommonStatement::setFastPropertyValue_NoBroadcast(nHandle,rValue);
402cdf0e10cSrcweir 	}
403cdf0e10cSrcweir }
404