diff options
author | Lionel Elie Mamane <lionel@mamane.lu> | 2013-11-30 11:55:03 +0100 |
---|---|---|
committer | Lionel Elie Mamane <lionel@mamane.lu> | 2013-11-30 12:03:19 +0100 |
commit | c0285abc4b3b128b0ab1cfc5689fef13e086db8e (patch) | |
tree | 6489e012f0b87cf91749a8243fac48ccba9a5749 /connectivity | |
parent | 7a64727f790f001ec42dafe38caeb86dfb6ddab1 (diff) |
factorise code
Change-Id: Ifd1829843886b8c58669fd4ccf04bc35bf4a0e10
Diffstat (limited to 'connectivity')
-rw-r--r-- | connectivity/source/drivers/flat/ETable.cxx | 9 |
1 files changed, 2 insertions, 7 deletions
diff --git a/connectivity/source/drivers/flat/ETable.cxx b/connectivity/source/drivers/flat/ETable.cxx index f30f467e2047..2fefbaac1eed 100644 --- a/connectivity/source/drivers/flat/ETable.cxx +++ b/connectivity/source/drivers/flat/ETable.cxx @@ -127,7 +127,6 @@ void OFlatTable::fillColumns(const ::com::sun::star::lang::Locale& _aLocale) // read description const sal_Unicode cDecimalDelimiter = pConnection->getDecimalDelimiter(); const sal_Unicode cThousandDelimiter = pConnection->getThousandDelimiter(); - OUString aColumnName; ::comphelper::UStringMixEqual aCase(bCase); vector<OUString> aColumnNames; vector<OUString> m_aTypeNames; @@ -144,17 +143,13 @@ void OFlatTable::fillColumns(const ::com::sun::star::lang::Locale& _aLocale) { if ( nRowCount == 0) { + OUString aColumnName; if ( bHasHeaderLine ) { aColumnName = aHeaderLine.GetTokenSpecial(nStartPosHeaderLine,m_cFieldDelimiter,m_cStringDelimiter); - if ( !aColumnName.getLength() ) - { - aColumnName = "C" + OUString::number(i+1); - } } - else + if ( aColumnName.isEmpty() ) { - // no column name so ... aColumnName = "C" + OUString::number(i+1); } aColumnNames.push_back(aColumnName); |