Tag: cws_src680_dba201d User: oj Date: 05/09/27 01:12:37 Modified: /dba/connectivity/source/commontools/ DateConversion.cxx /dba/connectivity/source/drivers/ado/ APreparedStatement.cxx /dba/connectivity/source/drivers/file/ FConnection.cxx /dba/connectivity/source/drivers/hsqldb/ HStorageMap.cxx
Log: commits from dba201c File Changes: Directory: /dba/connectivity/source/commontools/ ================================================ File [changed]: DateConversion.cxx Url: http://dba.openoffice.org/source/browse/dba/connectivity/source/commontools/DateConversion.cxx?r1=1.13&r2=1.13.10.1 Delta lines: +5 -6 ------------------- --- DateConversion.cxx 8 Sep 2005 05:09:08 -0000 1.13 +++ DateConversion.cxx 27 Sep 2005 08:12:26 -0000 1.13.10.1 @@ -4,9 +4,9 @@ * * $RCSfile: DateConversion.cxx,v $ * - * $Revision: 1.13 $ + * $Revision: 1.13.10.1 $ * - * last change: $Author: rt $ $Date: 2005/09/08 05:09:08 $ + * last change: $Author: oj $ $Date: 2005/09/27 08:12:26 $ * * The Contents of this file are made available subject to * the terms of GNU Lesser General Public License Version 2.1. @@ -146,15 +146,14 @@ DateTime aDateTime; // check if this is really a timestamp or only a date - if ((_rVal >>= aDateTime) && - (aDateTime.Hours || aDateTime.Minutes || aDateTime.Seconds || aDateTime.HundredthSeconds)) + if ( _rVal >>= aDateTime ) { if (bQuote) aRet += ::rtl::OUString::createFromAscii("{TS '"); aRet += DBTypeConversion::toDateTimeString(aDateTime); if (bQuote) aRet += ::rtl::OUString::createFromAscii("'}"); break; } - // else continue + break; } case DataType::DATE: { Directory: /dba/connectivity/source/drivers/ado/ ================================================ File [changed]: APreparedStatement.cxx Url: http://dba.openoffice.org/source/browse/dba/connectivity/source/drivers/ado/APreparedStatement.cxx?r1=1.16&r2=1.16.10.1 Delta lines: +15 -4 -------------------- --- APreparedStatement.cxx 8 Sep 2005 05:30:25 -0000 1.16 +++ APreparedStatement.cxx 27 Sep 2005 08:12:29 -0000 1.16.10.1 @@ -4,9 +4,9 @@ * * $RCSfile: APreparedStatement.cxx,v $ * - * $Revision: 1.16 $ + * $Revision: 1.16.10.1 $ * - * last change: $Author: rt $ $Date: 2005/09/08 05:30:25 $ + * last change: $Author: oj $ $Date: 2005/09/27 08:12:29 $ * * The Contents of this file are made available subject to * the terms of GNU Lesser General Public License Version 2.1. @@ -247,7 +247,18 @@ sDefaultName += ::rtl::OUString::valueOf(parameterIndex); ADOParameter* pParam = m_Command.CreateParameter(sDefaultName,_eType,adParamInput,_nSize,_Val); if(pParam) + { m_pParameters->Append(pParam); +#if OSL_DEBUG_LEVEL > 0 + ADOParameter* pParam = NULL; + m_pParameters->get_Item(OLEVariant(sal_Int32(parameterIndex-1)),&pParam); + WpADOParameter aParam(pParam); + if(pParam) + { + DataTypeEnum eType = aParam.GetADOType(); + } +#endif + } } else { @@ -262,7 +273,7 @@ #endif // OSL_DEBUG_LEVEL DataTypeEnum eType = aParam.GetADOType(); - if ( _eType != eType ) + if ( _eType != eType && _eType != adDBTimeStamp ) { aParam.put_Type(_eType); eType = _eType; Directory: /dba/connectivity/source/drivers/file/ ================================================= File [changed]: FConnection.cxx Url: http://dba.openoffice.org/source/browse/dba/connectivity/source/drivers/file/FConnection.cxx?r1=1.41&r2=1.41.10.1 Delta lines: +13 -6 -------------------- --- FConnection.cxx 8 Sep 2005 05:54:59 -0000 1.41 +++ FConnection.cxx 27 Sep 2005 08:12:33 -0000 1.41.10.1 @@ -4,9 +4,9 @@ * * $RCSfile: FConnection.cxx,v $ * - * $Revision: 1.41 $ + * $Revision: 1.41.10.1 $ * - * last change: $Author: rt $ $Date: 2005/09/08 05:54:59 $ + * last change: $Author: oj $ $Date: 2005/09/27 08:12:33 $ * * The Contents of this file are made available subject to * the terms of GNU Lesser General Public License Version 2.1. @@ -93,6 +93,9 @@ #ifndef _OSL_THREAD_H_ #include <osl/thread.h> #endif +#ifndef _OSL_NLSUPPORT_H_ +#include <osl/nlsupport.h> +#endif #ifndef _CONNECTIVITY_MODULECONTEXT_HXX_ #include "ModuleContext.hxx" #endif @@ -121,6 +124,7 @@ ,m_bCheckSQL92(sal_False) { ModuleContext::AddRef(); + m_nTextEncoding = RTL_TEXTENCODING_DONTKNOW; } //----------------------------------------------------------------------------- OConnection::~OConnection() @@ -189,9 +193,6 @@ m_nTextEncoding = (*aLookup).getEncoding(); else m_nTextEncoding = RTL_TEXTENCODING_DONTKNOW; - if(m_nTextEncoding == RTL_TEXTENCODING_DONTKNOW) - m_nTextEncoding = osl_getThreadTextEncoding(); - } else if (0 == pBegin->Name.compareToAscii("ShowDeleted")) { @@ -201,6 +202,12 @@ { pBegin->Value >>= m_bCheckSQL92; } + } // for(;pBegin != pEnd;++pBegin) + + if ( m_nTextEncoding == RTL_TEXTENCODING_DONTKNOW ) + { + //m_nTextEncoding = osl_getTextEncodingFromLocale(NULL); + m_nTextEncoding = osl_getThreadTextEncoding(); } if ( aExt.getLength() ) Directory: /dba/connectivity/source/drivers/hsqldb/ =================================================== File [changed]: HStorageMap.cxx Url: http://dba.openoffice.org/source/browse/dba/connectivity/source/drivers/hsqldb/HStorageMap.cxx?r1=1.8&r2=1.8.10.1 Delta lines: +16 -9 -------------------- --- HStorageMap.cxx 8 Sep 2005 06:04:08 -0000 1.8 +++ HStorageMap.cxx 27 Sep 2005 08:12:34 -0000 1.8.10.1 @@ -4,9 +4,9 @@ * * $RCSfile: HStorageMap.cxx,v $ * - * $Revision: 1.8 $ + * $Revision: 1.8.10.1 $ * - * last change: $Author: rt $ $Date: 2005/09/08 06:04:08 $ + * last change: $Author: oj $ $Date: 2005/09/27 08:12:34 $ * * The Contents of this file are made available subject to * the terms of GNU Lesser General Public License Version 2.1. @@ -170,22 +170,29 @@ ::rtl::OUString StorageContainer::jstring2ustring(JNIEnv * env, jstring jstr) { - const char * cstr; - rtl_uString * ustr = NULL; - cstr = env->GetStringUTFChars(jstr, NULL); if (JNI_FALSE != env->ExceptionCheck()) { env->ExceptionClear(); OSL_ENSURE(0,"ExceptionClear"); } - rtl_uString_newFromAscii(&ustr, cstr); - env->ReleaseStringUTFChars(jstr, cstr); + ::rtl::OUString aStr; + if ( jstr ) + { + jboolean bCopy(sal_True); + const jchar* pChar = env->GetStringChars(jstr,&bCopy); + jsize len = env->GetStringLength(jstr); + aStr = ::rtl::OUString(pChar,len); + + if(bCopy) + env->ReleaseStringChars(jstr,pChar); + } + if (JNI_FALSE != env->ExceptionCheck()) { env->ExceptionClear(); OSL_ENSURE(0,"ExceptionClear"); } - return ustr ? ::rtl::OUString(ustr,SAL_NO_ACQUIRE) : ::rtl::OUString(); + return aStr; } // ----------------------------------------------------------------------------- --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
