summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLionel Elie Mamane <lionel@mamane.lu>2012-02-14 19:41:08 +0100
committerLionel Elie Mamane <lionel@mamane.lu>2012-02-14 19:55:23 +0100
commitcdb2d21c550d18c5565a4ade7aeca4594a836f94 (patch)
tree99f9b39432a256198189b99dcb6ce3e1b0505658
parent034b130b90af330caab0b9fe7f19db45b5232eea (diff)
ODBC: align *all* the handling of SQLULEN properties with maximal ODBC size
-rw-r--r--connectivity/source/drivers/odbcbase/OStatement.cxx18
-rw-r--r--connectivity/source/inc/odbc/OStatement.hxx6
2 files changed, 12 insertions, 12 deletions
diff --git a/connectivity/source/drivers/odbcbase/OStatement.cxx b/connectivity/source/drivers/odbcbase/OStatement.cxx
index 635521795b54..5c64c26b00e3 100644
--- a/connectivity/source/drivers/odbcbase/OStatement.cxx
+++ b/connectivity/source/drivers/odbcbase/OStatement.cxx
@@ -756,13 +756,13 @@ sal_Int64 OStatement_Base::getMaxFieldSize() const
return ::rtl::OUString::createFromAscii((const char*)pName);
}
//------------------------------------------------------------------------------
-void OStatement_Base::setQueryTimeOut(sal_Int32 seconds)
+void OStatement_Base::setQueryTimeOut(sal_Int64 seconds)
{
OSL_ENSURE(m_aStatementHandle,"StatementHandle is null!");
setStmtOption<SQLULEN, SQL_IS_UINTEGER>(SQL_ATTR_QUERY_TIMEOUT,seconds);
}
//------------------------------------------------------------------------------
-void OStatement_Base::setMaxRows(sal_Int32 _par0)
+void OStatement_Base::setMaxRows(sal_Int64 _par0)
{
OSL_ENSURE(m_aStatementHandle,"StatementHandle is null!");
setStmtOption<SQLULEN, SQL_IS_UINTEGER>(SQL_ATTR_MAX_ROWS, _par0);
@@ -872,7 +872,7 @@ void OStatement_Base::setFetchSize(sal_Int32 _par0)
}
}
//------------------------------------------------------------------------------
-void OStatement_Base::setMaxFieldSize(sal_Int32 _par0)
+void OStatement_Base::setMaxFieldSize(sal_Int64 _par0)
{
OSL_ENSURE(m_aStatementHandle,"StatementHandle is null!");
setStmtOption<SQLULEN, SQL_IS_UINTEGER>(SQL_ATTR_MAX_LENGTH, _par0);
@@ -913,9 +913,9 @@ void OStatement_Base::setUsingBookmarks(sal_Bool _bUseBookmark)
DECL_BOOL_PROP0(ESCAPEPROCESSING);
DECL_PROP0(FETCHDIRECTION,sal_Int32);
DECL_PROP0(FETCHSIZE, sal_Int32);
- DECL_PROP0(MAXFIELDSIZE,sal_Int32);
- DECL_PROP0(MAXROWS, sal_Int32);
- DECL_PROP0(QUERYTIMEOUT,sal_Int32);
+ DECL_PROP0(MAXFIELDSIZE,sal_Int64);
+ DECL_PROP0(MAXROWS, sal_Int64);
+ DECL_PROP0(QUERYTIMEOUT,sal_Int64);
DECL_PROP0(RESULTSETCONCURRENCY,sal_Int32);
DECL_PROP0(RESULTSETTYPE,sal_Int32);
DECL_BOOL_PROP0(USEBOOKMARKS);
@@ -997,13 +997,13 @@ void OStatement_Base::setFastPropertyValue_NoBroadcast(sal_Int32 nHandle,const A
switch(nHandle)
{
case PROPERTY_ID_QUERYTIMEOUT:
- setQueryTimeOut(comphelper::getINT32(rValue));
+ setQueryTimeOut(comphelper::getINT64(rValue));
break;
case PROPERTY_ID_MAXFIELDSIZE:
- setMaxFieldSize(comphelper::getINT32(rValue));
+ setMaxFieldSize(comphelper::getINT64(rValue));
break;
case PROPERTY_ID_MAXROWS:
- setMaxRows(comphelper::getINT32(rValue));
+ setMaxRows(comphelper::getINT64(rValue));
break;
case PROPERTY_ID_CURSORNAME:
setCursorName(comphelper::getString(rValue));
diff --git a/connectivity/source/inc/odbc/OStatement.hxx b/connectivity/source/inc/odbc/OStatement.hxx
index e0d466316968..4768f701cce9 100644
--- a/connectivity/source/inc/odbc/OStatement.hxx
+++ b/connectivity/source/inc/odbc/OStatement.hxx
@@ -99,9 +99,9 @@ namespace connectivity
sal_Bool getEscapeProcessing() const;
template < typename T, SQLINTEGER BufferLength > T getStmtOption (SQLINTEGER fOption, T dflt = 0) const;
- void setQueryTimeOut(sal_Int32 _par0) ;
- void setMaxFieldSize(sal_Int32 _par0) ;
- void setMaxRows(sal_Int32 _par0) ;
+ void setQueryTimeOut(sal_Int64 _par0) ;
+ void setMaxFieldSize(sal_Int64 _par0) ;
+ void setMaxRows(sal_Int64 _par0) ;
void setFetchDirection(sal_Int32 _par0) ;
void setFetchSize(sal_Int32 _par0) ;
void setCursorName(const ::rtl::OUString &_par0);