summaryrefslogtreecommitdiff
path: root/connectivity/source/drivers/postgresql/pq_statement.cxx
diff options
context:
space:
mode:
authorNoel Grandin <noel@peralex.com>2013-11-19 17:06:06 +0200
committerNoel Grandin <noel@peralex.com>2013-11-20 10:07:32 +0200
commit52bbd9cc00b5a1e15e4f96b5c5fa5e75855692c1 (patch)
tree72d0d1d16806f1c785a4f79ea2c0cdfe54bb8101 /connectivity/source/drivers/postgresql/pq_statement.cxx
parent3af99e4d59d89c343965a928681a30f36b1007d2 (diff)
remove unnecessary RTL_CONSTASCII_STRINGPARAM in appendAscii calls
Convert code like: aStrBuf.appendAscii( RTL_CONSTASCII_STRINGPARAM( "ln(x)" )); to: aStrBuf.append( "ln(x)" ); which compiles down to the same code. Change-Id: I24c7cb45ceb32fd7cd6ec7ed203c2a5d746f1c5c
Diffstat (limited to 'connectivity/source/drivers/postgresql/pq_statement.cxx')
-rw-r--r--connectivity/source/drivers/postgresql/pq_statement.cxx14
1 files changed, 7 insertions, 7 deletions
diff --git a/connectivity/source/drivers/postgresql/pq_statement.cxx b/connectivity/source/drivers/postgresql/pq_statement.cxx
index f8e25652eb97..47697d1990f5 100644
--- a/connectivity/source/drivers/postgresql/pq_statement.cxx
+++ b/connectivity/source/drivers/postgresql/pq_statement.cxx
@@ -749,12 +749,12 @@ Reference< XResultSet > getGeneratedValuesFromLastInsert(
if( nLastOid && lastTableInserted.getLength() )
{
OUStringBuffer buf( 128 );
- buf.appendAscii( RTL_CONSTASCII_STRINGPARAM( "SELECT * FROM " ) );
+ buf.append( "SELECT * FROM " );
if( schemaName.getLength() )
bufferQuoteQualifiedIdentifier(buf, schemaName, tableName, pConnectionSettings );
else
bufferQuoteIdentifier( buf, lastTableInserted, pConnectionSettings );
- buf.appendAscii( RTL_CONSTASCII_STRINGPARAM( " WHERE oid = " ) );
+ buf.append( " WHERE oid = " );
buf.append( nLastOid , 10 );
query = buf.makeStringAndClear();
}
@@ -786,9 +786,9 @@ Reference< XResultSet > getGeneratedValuesFromLastInsert(
if( keyColumnNames.getLength() )
{
OUStringBuffer buf( 128 );
- buf.appendAscii( RTL_CONSTASCII_STRINGPARAM( "SELECT * FROM " ) );
+ buf.append( "SELECT * FROM " );
bufferQuoteQualifiedIdentifier(buf, schemaName, tableName, pConnectionSettings );
- buf.appendAscii( RTL_CONSTASCII_STRINGPARAM( " WHERE " ) );
+ buf.append( " WHERE " );
bool additionalCondition = false;
String2StringMap autoValues;
for( int i = 0 ; i < keyColumnNames.getLength() ; i ++ )
@@ -829,7 +829,7 @@ Reference< XResultSet > getGeneratedValuesFromLastInsert(
{
// retrieve current sequence value:
OUStringBuffer myBuf(128 );
- myBuf.appendAscii( RTL_CONSTASCII_STRINGPARAM( "SELECT currval(" ) );
+ myBuf.append( "SELECT currval(" );
myBuf.appendAscii( &(j->second.getStr()[8]));
value = querySingleValue( connection, myBuf.makeStringAndClear() );
}
@@ -846,9 +846,9 @@ Reference< XResultSet > getGeneratedValuesFromLastInsert(
}
if( additionalCondition )
- buf.appendAscii( RTL_CONSTASCII_STRINGPARAM( " AND " ) );
+ buf.append( " AND " );
bufferQuoteIdentifier( buf, keyColumnNames[i], pConnectionSettings );
- buf.appendAscii( RTL_CONSTASCII_STRINGPARAM( " = " ) );
+ buf.append( " = " );
buf.append( value );
additionalCondition = true;
}