Problem Note 70395: Using the NOPROMPT option with SAS/ACCESS® Interface to PostgreSQL might result in a connection error
Using the NOPROMPT option with SAS/ACCESS® Interface to PostgreSQL might result in a connection error similar to the following:
LIBNAME dev POSTGRES noprompt='BoolsAsChar=1' AUTOCOMMIT=YES DATABASE=xxxx PRESERVE_COL_NAMES=YES PRESERVE_TAB_NAMES=YES DIRECT_EXE=DELETE SERVER="xxxxx" SCHEMA=pgschema USER=xxxxx
PASSWORD="xxxxxx" ;
ERROR: CLI error trying to establish connection: could not connect to server: Connection refused (0x0000274D/10061) Is the server running on host "localhost" (::1) and accepting TCP/IP connections on port 5432? could not connect to server: Connection refused(0x0000274D/10061) Is the server running on host "localhost" (127.0.0.1) and accepting TCP/IP connections on port 5432?
ERROR: Error in the LIBNAME statement.
After an upgrade to SAS® 9.4 M7 (TS1M7) or in SAS® Viya® 2203.04 and earlier versions, LIBNAME statements that contain parameters similar to BoolsAsChar and use of the NOPROMPT option could cause this issue.
Workaround:
Move the parameter into a CONOPTS option:
LIBNAME dev POSTGRES AUTOCOMMIT=YES DATABASE=xxxx PRESERVE_COL_NAMES=YES PRESERVE_TAB_NAMES=YES DIRECT_EXE=DELETE SERVER="xxxxx" SCHEMA=pgschema USER=xxxxx
PASSWORD="xxxxxx" CONOPTS='BoolsAsChar=1' ;
Operating System and Release Information
| SAS System | SAS Viya platform | Linux for x64 | Stable 2023.04 | Stable 2023.05 | Viya platform | Viya platform |
*
For software releases that are not yet generally available, the Fixed
Release is the software release in which the problem is planned to be
fixed.
In this scenario, an error similar to the following occurs: "ERROR: CLI error trying to establish connection: could not connect to server: Connection refused ... TCP/IP connections on port 5432? Error in the LIBNAME statement."
| Type: | Problem Note |
| Priority: | medium |
| Date Modified: | 2023-09-27 09:17:30 |
| Date Created: | 2023-09-18 11:10:51 |