diff --git a/dbaccess/source/core/api/CRowSetColumn.cxx b/dbaccess/source/core/api/CRowSetColumn.cxx
index 60c4fe1..d7216ff 100644
--- a/dbaccess/source/core/api/CRowSetColumn.cxx
+++ b/dbaccess/source/core/api/CRowSetColumn.cxx
@@ -60,7 +60,6 @@ ORowSetColumn::ORowSetColumn(	const Reference < XResultSetMetaData >& _xMetaData
 {
     const sal_Int32 nDerivedProperties = 21;
     Sequence< Property> aDerivedProperties( nDerivedProperties );
-    Property* pDesc = aDerivedProperties.getArray();
     sal_Int32 nPos = 0;
 
     DECL_PROP1( CATALOGNAME,                ::rtl::OUString,    READONLY );
diff --git a/dbaccess/source/core/api/CRowSetDataColumn.cxx b/dbaccess/source/core/api/CRowSetDataColumn.cxx
index ab1ef90..fe8ade4 100644
--- a/dbaccess/source/core/api/CRowSetDataColumn.cxx
+++ b/dbaccess/source/core/api/CRowSetDataColumn.cxx
@@ -80,7 +80,6 @@ ORowSetDataColumn::~ORowSetDataColumn()
 {
     const sal_Int32 nDerivedProperties = 21;
     Sequence< Property> aDerivedProperties( nDerivedProperties );
-    Property* pDesc = aDerivedProperties.getArray();
     sal_Int32 nPos = 0;
 
     DECL_PROP1( CATALOGNAME,                ::rtl::OUString,    READONLY );
diff --git a/dbaccess/source/core/api/definitioncolumn.cxx b/dbaccess/source/core/api/definitioncolumn.cxx
index 2a0f263..3b7de41 100644
--- a/dbaccess/source/core/api/definitioncolumn.cxx
+++ b/dbaccess/source/core/api/definitioncolumn.cxx
@@ -502,7 +502,6 @@ Sequence< ::rtl::OUString > OTableColumnDescriptorWrapper::getSupportedServiceNa
 
     const sal_Int32 nPropertyCount( nHaveAlways + nHaveOptionally );
     Sequence< Property > aTableDescProperties( nPropertyCount );
-    Property* pDesc = aTableDescProperties.getArray();
     sal_Int32 nPos = 0;
 
     DECL_PROP0_BOOL( ISAUTOINCREMENT                );
diff --git a/dbaccess/source/ui/app/subcomponentmanager.cxx b/dbaccess/source/ui/app/subcomponentmanager.cxx
index ea37fcf..8159f74 100644
--- a/dbaccess/source/ui/app/subcomponentmanager.cxx
+++ b/dbaccess/source/ui/app/subcomponentmanager.cxx
@@ -179,7 +179,7 @@ namespace dbaui
         //..............................................................................................................
         struct SelectSubComponent : public ::std::unary_function< SubComponentDescriptor, Reference< XComponent > >
         {
-            Reference< XComponent > operator()( const SubComponentDescriptor _desc ) const
+            Reference< XComponent > operator()( const SubComponentDescriptor &_desc ) const
             {
                 if ( _desc.xModel.is() )
                     return _desc.xModel.get();
diff --git a/dbaccess/source/ui/misc/DExport.cxx b/dbaccess/source/ui/misc/DExport.cxx
index 9332a2f..7cbb660 100644
--- a/dbaccess/source/ui/misc/DExport.cxx
+++ b/dbaccess/source/ui/misc/DExport.cxx
@@ -332,8 +332,6 @@ void ODatabaseExport::insertValueIntoColumn()
                         m_pUpdateHelper->updateNull(nPos,pField->GetType());
                     else
                     {
-                        sal_Int32 nNumberFormat = 0;
-                        double fOutNumber = 0.0;
                         OSL_ENSURE((nNewPos) < static_cast<sal_Int32>(m_vColumnTypes.size()),"Illegal index for vector");
                         if (m_vColumnTypes[nNewPos] != DataType::VARCHAR && m_vColumnTypes[nNewPos] != DataType::CHAR && m_vColumnTypes[nNewPos] != DataType::LONGVARCHAR )
                         {
@@ -342,6 +340,8 @@ void ODatabaseExport::insertValueIntoColumn()
                             bool bNumberFormatError = false;
                             if ( m_pFormatter && m_sNumToken.Len() )
                             {
+								sal_Int32 nNumberFormat = 0;
+								double fOutNumber = 0.0;
                                 LanguageType eNumLang = LANGUAGE_NONE;
                                 sal_uInt32 nNumberFormat2( nNumberFormat );
                                 fOutNumber = SfxHTMLParser::GetTableDataOptionsValNum(nNumberFormat2,eNumLang,m_sTextToken,m_sNumToken,*m_pFormatter);
diff --git a/dbaccess/source/ui/misc/TokenWriter.cxx b/dbaccess/source/ui/misc/TokenWriter.cxx
index 6de15f1..74f7345 100644
--- a/dbaccess/source/ui/misc/TokenWriter.cxx
+++ b/dbaccess/source/ui/misc/TokenWriter.cxx
@@ -1056,13 +1056,12 @@ void OHTMLImportExport::WriteCell( sal_Int32 nFormat,sal_Int32 nWidthPixel,sal_I
     aStrTD = aStrTD + "=";
     aStrTD = aStrTD + pChar;
 
-    double fVal = 0.0;
-
     Reference< ::com::sun::star::util::XNumberFormatsSupplier >  xSupplier = m_xFormatter->getNumberFormatsSupplier();
     SvNumberFormatsSupplierObj* pSupplierImpl = SvNumberFormatsSupplierObj::getImplementation( xSupplier );
     SvNumberFormatter* pFormatter = pSupplierImpl ? pSupplierImpl->GetNumberFormatter() : NULL;
     if(pFormatter)
     {
+		double fVal = 0.0;
         try
         {
             fVal = m_xFormatter->convertStringToNumber(nFormat,rValue);
diff --git a/dbaccess/source/ui/relationdesign/RelationController.cxx b/dbaccess/source/ui/relationdesign/RelationController.cxx
index c32fbb7..5637f1f 100644
--- a/dbaccess/source/ui/relationdesign/RelationController.cxx
+++ b/dbaccess/source/ui/relationdesign/RelationController.cxx
@@ -366,12 +366,10 @@ namespace
         Reference<XPropertySet> xTableProp(_aTable,UNO_QUERY);
         const ::rtl::OUString sSourceName = ::dbtools::composeTableName( m_xMetaData, xTableProp, ::dbtools::eInTableDefinitions, false, false, false );
         TTableDataHelper::iterator aFind = m_aTableData.find(sSourceName);
-        bool bNotFound = true, bAdded = false;
         if ( aFind == m_aTableData.end() )
         {
             aFind = m_aTableData.insert(TTableDataHelper::value_type(sSourceName,::boost::shared_ptr<OTableWindowData>(new OTableWindowData(xTableProp,sSourceName, sSourceName)))).first;
             aFind->second->ShowAll(FALSE);
-            bAdded = true;
         }
         TTableWindowData::value_type pReferencingTable = aFind->second;
         Reference<XIndexAccess> xKeys = pReferencingTable->getKeys();
@@ -393,7 +391,6 @@ namespace
                 xKey->getPropertyValue(PROPERTY_TYPE) >>= nKeyType;
                 if ( KeyType::FOREIGN == nKeyType )
                 {
-                    bNotFound = false;
                     ::rtl::OUString sReferencedTable;
                     xKey->getPropertyValue(PROPERTY_REFERENCEDTABLE) >>= sReferencedTable;
                     //////////////////////////////////////////////////////////////////////
diff --git a/dbaccess/source/ui/tabledesign/TEditControl.cxx b/dbaccess/source/ui/tabledesign/TEditControl.cxx
index 4e841d7..b4ff271 100644
--- a/dbaccess/source/ui/tabledesign/TEditControl.cxx
+++ b/dbaccess/source/ui/tabledesign/TEditControl.cxx
@@ -1802,7 +1802,6 @@ void OTableEditorCtrl::SetPrimaryKey( sal_Bool bSet )
     // Evtl. vorhandene Primary Keys loeschen
     MultiSelection aDeletedPrimKeys;
     aDeletedPrimKeys.SetTotalRange( Range(0,GetRowCount()) );
-    long nIndex = 0;
 
     ::std::vector< ::boost::shared_ptr<OTableRow> >::const_iterator aIter = m_pRowList->begin();
     ::std::vector< ::boost::shared_ptr<OTableRow> >::const_iterator aEnd = m_pRowList->end();
@@ -1821,7 +1820,7 @@ void OTableEditorCtrl::SetPrimaryKey( sal_Bool bSet )
     aInsertedPrimKeys.SetTotalRange( Range(0,GetRowCount()) );
     if( bSet )
     {
-        nIndex = FirstSelectedRow();
+        long nIndex = FirstSelectedRow();
         while( nIndex >= 0 && nIndex < static_cast<long>(m_pRowList->size()) )
         {
             //////////////////////////////////////////////////////////////////////
