// Fetch results SQLCHAR* buffer = new SQLCHAR[1024]; while (SQLFetch(sqlStmtHandle) == SQL_SUCCESS) SQLGetData(sqlStmtHandle, 1, SQL_C_CHAR, buffer, 1024, NULL); printf("%s\n", buffer);
# Create a DSN dsn = f'DSN=database;Server=host:port;Database=database;Uid=username;Pwd=password'
Here are some examples of using the Postgres ODBC driver:
# Install the driver sudo dnf install postgresql-odbc
The official website hosts the psqlODBC project.
// Fetch results SQLCHAR* buffer = new SQLCHAR[1024]; while (SQLFetch(sqlStmtHandle) == SQL_SUCCESS) SQLGetData(sqlStmtHandle, 1, SQL_C_CHAR, buffer, 1024, NULL); printf("%s\n", buffer);
# Create a DSN dsn = f'DSN=database;Server=host:port;Database=database;Uid=username;Pwd=password' download postgres odbc driver
Here are some examples of using the Postgres ODBC driver: // Fetch results SQLCHAR* buffer = new SQLCHAR[1024];
# Install the driver sudo dnf install postgresql-odbc download postgres odbc driver
The official website hosts the psqlODBC project.