diff options
| author | Michele Calgaro <michele.calgaro@yahoo.it> | 2024-11-04 13:01:41 +0900 |
|---|---|---|
| committer | Michele Calgaro <michele.calgaro@yahoo.it> | 2026-01-04 22:55:45 +0900 |
| commit | 6b5960c0e9ea768759c03be6532009409fa958ce (patch) | |
| tree | d9deedd7df48aef68e2b456d3343f634283d0df6 /src/sql/drivers/psql | |
| parent | 074d585cc3a076958b986ff7cf31eb15d1e8412a (diff) | |
| download | tqt-feat/tqmake.tar.gz tqt-feat/tqmake.zip | |
rename qmake to tqmakefeat/tqmake
Signed-off-by: Michele Calgaro <michele.calgaro@yahoo.it>
Diffstat (limited to 'src/sql/drivers/psql')
| -rw-r--r-- | src/sql/drivers/psql/tqsql_psql.cpp | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/src/sql/drivers/psql/tqsql_psql.cpp b/src/sql/drivers/psql/tqsql_psql.cpp index 625177c7b..43a3b1a7a 100644 --- a/src/sql/drivers/psql/tqsql_psql.cpp +++ b/src/sql/drivers/psql/tqsql_psql.cpp @@ -120,7 +120,7 @@ bool TQPSQLOpenExtension::open( const TQString& db, return driver->open( db, user, password, host, port, connOpts ); } -static TQSqlError qMakeError( const TQString& err, int type, const TQPSQLPrivate* p ) +static TQSqlError tqMakeError( const TQString& err, int type, const TQPSQLPrivate* p ) { const char *s = PQerrorMessage(p->connection); TQString msg = p->isUtf8 ? TQString::fromUtf8(s) : TQString::fromLocal8Bit(s); @@ -484,7 +484,7 @@ bool TQPSQLResult::reset ( const TQString& query ) setActive( true ); return true; } - setLastError( qMakeError( "Unable to create query", TQSqlError::Statement, d ) ); + setLastError( tqMakeError( "Unable to create query", TQSqlError::Statement, d ) ); return false; } @@ -656,7 +656,7 @@ bool TQPSQLDriver::open( const TQString & db, d->connection = PQconnectdb( connectString.local8Bit().data() ); if ( PQstatus( d->connection ) == CONNECTION_BAD ) { - setLastError( qMakeError("Unable to connect", TQSqlError::Connection, d ) ); + setLastError( tqMakeError("Unable to connect", TQSqlError::Connection, d ) ); setOpenError( true ); return false; } @@ -697,7 +697,7 @@ bool TQPSQLDriver::ping() if ( PQstatus( d->connection ) != CONNECTION_OK ) { PQreset( d->connection ); if ( PQstatus( d->connection ) != CONNECTION_OK ) { - setLastError( qMakeError("Unable to execute ping", TQSqlError::Statement, d ) ); + setLastError( tqMakeError("Unable to execute ping", TQSqlError::Statement, d ) ); return false; } } @@ -720,7 +720,7 @@ bool TQPSQLDriver::beginTransaction() PGresult* res = PQexec( d->connection, "BEGIN" ); if ( !res || PQresultStatus( res ) != PGRES_COMMAND_OK ) { PQclear( res ); - setLastError( qMakeError( "Could not begin transaction", TQSqlError::Transaction, d ) ); + setLastError( tqMakeError( "Could not begin transaction", TQSqlError::Transaction, d ) ); return false; } PQclear( res ); @@ -738,7 +738,7 @@ bool TQPSQLDriver::commitTransaction() PGresult* res = PQexec( d->connection, "COMMIT" ); if ( !res || PQresultStatus( res ) != PGRES_COMMAND_OK ) { PQclear( res ); - setLastError( qMakeError( "Could not commit transaction", TQSqlError::Transaction, d ) ); + setLastError( tqMakeError( "Could not commit transaction", TQSqlError::Transaction, d ) ); return false; } PQclear( res ); @@ -755,7 +755,7 @@ bool TQPSQLDriver::rollbackTransaction() } PGresult* res = PQexec( d->connection, "ROLLBACK" ); if ( !res || PQresultStatus( res ) != PGRES_COMMAND_OK ) { - setLastError( qMakeError( "Could not rollback transaction", TQSqlError::Transaction, d ) ); + setLastError( tqMakeError( "Could not rollback transaction", TQSqlError::Transaction, d ) ); PQclear( res ); return false; } |
