Robert S. Bachman | 15 Jul 20:22 2016

Connecting to a MySQL database over a network

Hello,

 

I emailed you about a year ago regarding a PostgreSQL database. I have another question, not

Sure you can help or not.

 

We have a client application that connects to a MySQL database over a network but we’re

not able to connect.

 

Is this something that’s possible using PostgreSQL driver or do we need to migrate our

MySQL database network Server to PostgreSQL?

 

Thanks very much.

 

Bob Bachman

Dave Cramer | 19 Jul 23:09 2016
Picon

How can I run installcheck using powershell ?

Is there a way to run the tests ?

Alternatively nmake is giving me:
 error LNK2019: unresolved external symbol __vsnwprintf_s referenced in function _StringCchPrintfW


Dave Cramer
Dave Cramer | 19 Jul 17:43 2016
Picon

Errors building on windows

I am getting the following errors:

loadlib.c(114): error C2373: '__pfnDliFailureHook2': redefinition; different type modifiers
C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\INCLUDE\delayimp.h(141): note: see declaration of '__pfnDliFailur
eHook2'
loadlib.c(115): error C2373: '__pfnDliNotifyHook2': redefinition; different type modifiers
C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\INCLUDE\delayimp.h(134): note: see declaration of '__pfnDliNotify
Hook2'
loadlib.c(129): error C2166: l-value specifies const object
loadlib.c(190): error C2166: l-value specifies const object
loadlib.c(198): error C2166: l-value specifies const object
loadlib.c(229): error C2166: l-value specifies const object
loadlib.c(237): error C2166: l-value specifies const object

Which appear to be from:

// Prior to Visual Studio 2015 Update 3, these hooks were non-const.  They were
// made const to improve security (global, writable function pointers are bad).
// If for backwards compatibility you require the hooks to be writable, define
// the macro DELAYIMP_INSECURE_WRITABLE_HOOKS prior to including this header and
// provide your own non-const definition of the hooks.
ExternC
#ifndef DELAYIMP_INSECURE_WRITABLE_HOOKS
const
#endif
PfnDliHook   __pfnDliNotifyHook2;

// This is the failure hook, dliNotify = {dliFailLoadLib|dliFailGetProc}
ExternC
#ifndef DELAYIMP_INSECURE_WRITABLE_HOOKS
const
#endif
PfnDliHook   __pfnDliFailureHook2;


It would appear we need to define DELAYIMP_INSECURE_WRITABLE_HOOKS. Is there another way to set the hook to NULL

Dave Cramer
Jan-Peter Seifert | 14 Jul 16:31 2016
Picon
Picon

Getting DSN settings via ODBC?

Hello,

is it possible to get the DSN's psqlODBC specific settings (PROTOCOL, "Level of Rollback on errors" etc.)
via ODBC (information) functions?

Thank you very much!

Best regards,

Peter

--

-- 
Sent via pgsql-odbc mailing list (pgsql-odbc <at> postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-odbc

Dave Cramer | 12 Jul 12:47 2016
Picon

broken link on web


https://odbc.postgresql.org/docs/win32-compilation.html 

has a broken link to the ssl information.

Dave Cramer
john.robinson | 11 Jul 16:20 2016

PSQLODBC - Selecting bytea columns in Oracle

Hi,

 

I hope you can help.  We have a PostgreSQL database which stores image data in bytea columns.  I am attempting to read these images from within an Oracle database using the Oracle Database Gateway for ODBC and the PSQLODBC driver with the iODBC driver manager.  However, the bytea column is being truncated to a single byte when selected within Oracle.  I have attached the mylog_oracle????.log file plus the odbc.ini and odbcinst.ini.  The software versions we are using are:

 

PostgreSQL database -  9.2.17

Oracle Database - 11.2.0.4

PSQLODBC driver – 9.5.3

iODBC Driver manager – 3.52.10

 

I have been working with Oracle Support for a while on this issue.  Initially Oracle was displaying the bytea columns as a raw datatype with a length of 255 bytes.  Oracle recommended setting the ByteaAsLongVarBinary to 1 in the odbc.ini file.  This resulted in the bytea columns to be truncated to 1 byte within Oracle.  Oracle have seen the log files and claim the data is being truncated within the ODBC driver.

 

Is there anything else I can try to resolve this issue so I can read all the data within the bytea columns from Oracle?  Please let me know if I can provide any further information.

 

Many Thanks,

 

Regards,

 

John Robinson

 

John Robinson | Oracle Database Administrator
Vaisala Ltd, Information Services, Elm House, 351 Bristol Road, Birmingham, B5 7SW, United Kingdom
Tel
 +44 121 683 1237| Mobile +44 7739 874462
Email 
John.Robinson <at> vaisala.com |  www.vaisala.com
Follow us on: Twitter | Facebook | YouTube | LinkedIn

P  Please consider our environment before printing this email

 


--

-- 
Sent via pgsql-odbc mailing list (pgsql-odbc <at> postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-odbc
NILTON OLIV | 9 Jul 14:54 2016
Picon

Help me please - psqlODBC _09_05_0300-x64


Hello, I downloaded "psqlODBC _09_05_0300-x64." After it was installed, when opening shows this error:

Warning:
The server you are connecting to is not a version that is suported by this release of pgAdmin III.
pgAdmin III may not function as expected.
Supported server versions are 8.4 to 9.5.

I am grateful to be able to help me.

Att,

Nilton
Johnny Yan | 6 Jul 22:01 2016

Statically linking against libpq

Hi,

 

We’re building the postgres odbc driver by ourselves for our customers on Linux. It builds against hence depends on libpq.so. We’re wondering if there is a secret configure flag to statically link against libpq such that the final psqlodbcw.so has less dependencies and in particular doesn’t depend on libpq.so. Also if there is no such config flag yet, are you guys planning to add one? Thank you for your help in advance.

 

Johnny

Andrus | 4 Jul 21:42 2016
Picon

How to get correct error message before logging to database

Tried

x84 driver 09.05.0300 in Windows 10 x64 with Visual FoxPro
Server is Postgres 9.5 in same maschine.

If there is no host name, user name or password is wrong, this driver 
returns always same error  message

Connectivity error: Unable to retrieve specific error information.  Driver 
is probably out of resources

Earlier versions of drivers returned correct error message.

After logging in correct error messages are returned.

How to fix ?

Andrus. 

--

-- 
Sent via pgsql-odbc mailing list (pgsql-odbc <at> postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-odbc

Jan-Peter Seifert | 4 Jul 15:31 2016
Picon
Picon

psqlODBC 09.05.0300 (x86) - problem with SQL_QUERY_TIMEOUT

Hello,

it looks like SQL_QUERY_TIMEOUT is on by default - causing dead connections with long running statements:

"SQLSTATE = 00000 Native Error = 26 Could not send Query(connection dead)"

I tested with 9.3.400 (without problems) as well.

How can I disable it? Adding "statement_timeout = 0" to the "Connect Settings" field on Advance Options
Page 2?

Could you tell me, please?

Thank you very much!

Best regards,

Peter

--

-- 
Sent via pgsql-odbc mailing list (pgsql-odbc <at> postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-odbc

Koenig, Michael | 1 Jul 18:35 2016

Fetch next with ODBC driver 09.05.0100 yields wrong/duplicate results

Hi there!

 

While developing turbodbc, a Python database driver for unixodbc, I encountered some difficulties when testing it with PostgreSQL.

 

System: Ubuntu 14.04

PostgreSQL ODBC driver version: 09.05.0100-2.pgdg14.04+1 (following instructions from http://tecadmin.net/install-postgresql-server-on-ubuntu/)

PostgreSQL server version: psql 9.5.3, server 9.3.13

Debug log: Cannot manage to activate it… (TraceFile does not work)

 

What I do (summary):

·         Create a table on the database with 102 ascending integers (1-102)

·         Connect to PostgreSQL via unixodbc 2.2.14

·         Prepare and execute a statement

·         Bind a buffer which holds 1000 64 bit integer elements

·         Bind variable to hold number of returned elements

·         Use SQLFetchScroll to fetch data with SQL_FETCH_NEXT

 

The test should return a total of 102 values.

 

What I get:

 

All tests ran on Ubuntu 14.04.

 

Output with odbc-postgresql package in version odbc-postgresql=1:09.02.0100-2ubuntu1 (Ubuntu official mirror):
102 elements

[1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90, 91, 92, 93, 94, 95, 96, 97, 98, 99, 100, 101, 102]

 

Output with odbc-postgresql=1:09.05.0100-2.pgdg14.04+1 (following instructions from http://tecadmin.net/install-postgresql-server-on-ubuntu/):

 

203 elements

[1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90, 91, 92, 93, 94, 95, 96, 97, 98, 99, 100, 101, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90, 91, 92, 93, 94, 95, 96, 97, 98, 99, 100, 101, 102]

 

In between the runs, the only difference is that I run sudo apt-get install odbc-postgresql=1:09.05.0100-2.pgdg14.04+1 to upgrade the ODBC driver.

 

The magic numbers used here (102 integers, 100 element buffer) are not too important. I can reproduce the error (with slightly different outcome) with other buffer sizes, including some smaller than the size of the result set. 12 is the smallest buffer size to reproduce the error. I need at least 102 integers to reproduce the problem.

 

Here is some output with 102 integers and a buffer size of 12:

 

108 elements

[1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90, 91, 92, 93, 94, 95, 96, 97, 98, 99, 100, 101, 1, 2, 3, 4, 5, 6, 7]

 

I have tested my code with a number of databases and a number of ODBC drivers on a number of Linux systems, and this ODBC driver is the only one which shows the problem.

 

Hope you can help me or point me to an entry in the change log which explains the changed behavior.

 

Kind regards

 

Michael


Gmane