Remove some code for old unsupported versions of MSVC

As of d9dd406fe2, we require MSVC 2013,
which means _MSC_VER >= 1800.  This means that conditionals about
older versions of _MSC_VER can be removed or simplified.

Previous code was also in some cases handling MinGW, where _MSC_VER is
not defined at all, incorrectly, such as in pg_ctl.c and win32_port.h,
leading to some compiler warnings.  This should now be handled better.

Reviewed-by: Michael Paquier <michael@paquier.xyz>
This commit is contained in:
Peter Eisentraut 2019-10-08 10:27:30 +02:00
parent a7471bd85c
commit 38d8dce61f
12 changed files with 255 additions and 377 deletions

View File

@ -973,7 +973,7 @@ cache_locale_time(void)
static char * static char *
IsoLocaleName(const char *winlocname) IsoLocaleName(const char *winlocname)
{ {
#if (_MSC_VER >= 1400) /* VC8.0 or later */ #ifdef _MSC_VER
static char iso_lc_messages[32]; static char iso_lc_messages[32];
_locale_t loct = NULL; _locale_t loct = NULL;
@ -987,7 +987,6 @@ IsoLocaleName(const char *winlocname)
loct = _create_locale(LC_CTYPE, winlocname); loct = _create_locale(LC_CTYPE, winlocname);
if (loct != NULL) if (loct != NULL)
{ {
#if (_MSC_VER >= 1700) /* Visual Studio 2012 or later */
size_t rc; size_t rc;
char *hyphen; char *hyphen;
@ -1014,28 +1013,10 @@ IsoLocaleName(const char *winlocname)
hyphen = strchr(iso_lc_messages, '-'); hyphen = strchr(iso_lc_messages, '-');
if (hyphen) if (hyphen)
*hyphen = '_'; *hyphen = '_';
#else
char isolang[32],
isocrty[32];
LCID lcid;
lcid = loct->locinfo->lc_handle[LC_CTYPE];
if (lcid == 0)
lcid = MAKELCID(MAKELANGID(LANG_ENGLISH, SUBLANG_ENGLISH_US), SORT_DEFAULT);
_free_locale(loct);
if (!GetLocaleInfoA(lcid, LOCALE_SISO639LANGNAME, isolang, sizeof(isolang)))
return NULL;
if (!GetLocaleInfoA(lcid, LOCALE_SISO3166CTRYNAME, isocrty, sizeof(isocrty)))
return NULL;
snprintf(iso_lc_messages, sizeof(iso_lc_messages) - 1, "%s_%s", isolang, isocrty);
#endif
return iso_lc_messages; return iso_lc_messages;
} }
return NULL; #endif /* _MSC_VER */
#else
return NULL; /* Not supported on this version of msvc/mingw */ return NULL; /* Not supported on this version of msvc/mingw */
#endif /* _MSC_VER >= 1400 */
} }
#endif /* WIN32 && LC_MESSAGES */ #endif /* WIN32 && LC_MESSAGES */

View File

@ -4092,20 +4092,7 @@ convert_string_datum(Datum value, Oid typid, Oid collid, bool *failure)
* crashes since it will only give an estimation error and nothing * crashes since it will only give an estimation error and nothing
* fatal. * fatal.
*/ */
#if _MSC_VER == 1400 /* VS.Net 2005 */
/*
*
* http://connect.microsoft.com/VisualStudio/feedback/ViewFeedback.aspx?FeedbackID=99694
*/
{
char x[1];
xfrmlen = strxfrm(x, val, 0);
}
#else
xfrmlen = strxfrm(NULL, val, 0); xfrmlen = strxfrm(NULL, val, 0);
#endif
#ifdef WIN32 #ifdef WIN32
/* /*

View File

@ -137,12 +137,7 @@ static void print_msg(const char *msg);
static void adjust_data_dir(void); static void adjust_data_dir(void);
#ifdef WIN32 #ifdef WIN32
#if (_MSC_VER >= 1800)
#include <versionhelpers.h> #include <versionhelpers.h>
#else
static bool IsWindowsXPOrGreater(void);
static bool IsWindows7OrGreater(void);
#endif
static bool pgwin32_IsInstalled(SC_HANDLE); static bool pgwin32_IsInstalled(SC_HANDLE);
static char *pgwin32_CommandLine(bool); static char *pgwin32_CommandLine(bool);
static void pgwin32_doRegister(void); static void pgwin32_doRegister(void);
@ -1378,32 +1373,6 @@ do_kill(pgpid_t pid)
#ifdef WIN32 #ifdef WIN32
#if (_MSC_VER < 1800)
static bool
IsWindowsXPOrGreater(void)
{
OSVERSIONINFO osv;
osv.dwOSVersionInfoSize = sizeof(osv);
/* Windows XP = Version 5.1 */
return (!GetVersionEx(&osv) || /* could not get version */
osv.dwMajorVersion > 5 || (osv.dwMajorVersion == 5 && osv.dwMinorVersion >= 1));
}
static bool
IsWindows7OrGreater(void)
{
OSVERSIONINFO osv;
osv.dwOSVersionInfoSize = sizeof(osv);
/* Windows 7 = Version 6.0 */
return (!GetVersionEx(&osv) || /* could not get version */
osv.dwMajorVersion > 6 || (osv.dwMajorVersion == 6 && osv.dwMinorVersion >= 0));
}
#endif
static bool static bool
pgwin32_IsInstalled(SC_HANDLE hSCM) pgwin32_IsInstalled(SC_HANDLE hSCM)
{ {

View File

@ -268,14 +268,10 @@
/* #undef HAVE_LONG_INT_64 */ /* #undef HAVE_LONG_INT_64 */
/* Define to 1 if the system has the type `long long int'. */ /* Define to 1 if the system has the type `long long int'. */
#if (_MSC_VER > 1200)
#define HAVE_LONG_LONG_INT 1 #define HAVE_LONG_LONG_INT 1
#endif
/* Define to 1 if `long long int' works and is 64 bits. */ /* Define to 1 if `long long int' works and is 64 bits. */
#if (_MSC_VER > 1200)
#define HAVE_LONG_LONG_INT_64 1 #define HAVE_LONG_LONG_INT_64 1
#endif
/* Define to 1 if you have the `mbstowcs_l' function. */ /* Define to 1 if you have the `mbstowcs_l' function. */
#define HAVE_MBSTOWCS_L 1 #define HAVE_MBSTOWCS_L 1
@ -347,10 +343,7 @@
/* #undef HAVE_READLINK */ /* #undef HAVE_READLINK */
/* Define to 1 if you have the `rint' function. */ /* Define to 1 if you have the `rint' function. */
#if (_MSC_VER >= 1800)
#define HAVE_RINT 1 #define HAVE_RINT 1
#endif
/* Define to 1 if you have the global variable /* Define to 1 if you have the global variable
'rl_completion_append_character'. */ 'rl_completion_append_character'. */
@ -387,9 +380,7 @@
#define HAVE_SSL_GET_CURRENT_COMPRESSION 1 #define HAVE_SSL_GET_CURRENT_COMPRESSION 1
/* Define to 1 if stdbool.h conforms to C99. */ /* Define to 1 if stdbool.h conforms to C99. */
#if (_MSC_VER >= 1800)
#define HAVE_STDBOOL_H 1 #define HAVE_STDBOOL_H 1
#endif
/* Define to 1 if you have the <stdint.h> header file. */ /* Define to 1 if you have the <stdint.h> header file. */
/* #undef HAVE_STDINT_H */ /* #undef HAVE_STDINT_H */
@ -415,25 +406,15 @@
/* Define to 1 if you have the `strtoll' function. */ /* Define to 1 if you have the `strtoll' function. */
#ifdef HAVE_LONG_LONG_INT_64 #ifdef HAVE_LONG_LONG_INT_64
#define HAVE_STRTOLL 1 #define HAVE_STRTOLL 1
/* Before VS2013, use Microsoft's nonstandard equivalent function */
#if (_MSC_VER < 1800)
#define strtoll _strtoi64
#endif
#endif #endif
/* Define to 1 if you have the `strtoull' function. */ /* Define to 1 if you have the `strtoull' function. */
#ifdef HAVE_LONG_LONG_INT_64 #ifdef HAVE_LONG_LONG_INT_64
#define HAVE_STRTOULL 1 #define HAVE_STRTOULL 1
/* Before VS2013, use Microsoft's nonstandard equivalent function */
#if (_MSC_VER < 1800)
#define strtoull _strtoui64
#endif
#endif #endif
/* Define to 1 if the system has the type `struct addrinfo'. */ /* Define to 1 if the system has the type `struct addrinfo'. */
#if (_MSC_VER > 1200)
#define HAVE_STRUCT_ADDRINFO 1 #define HAVE_STRUCT_ADDRINFO 1
#endif
/* Define to 1 if the system has the type `struct cmsgcred'. */ /* Define to 1 if the system has the type `struct cmsgcred'. */
/* #undef HAVE_STRUCT_CMSGCRED */ /* #undef HAVE_STRUCT_CMSGCRED */
@ -445,14 +426,10 @@
/* #undef HAVE_STRUCT_SOCKADDR_SA_LEN */ /* #undef HAVE_STRUCT_SOCKADDR_SA_LEN */
/* Define to 1 if the system has the type `struct sockaddr_storage'. */ /* Define to 1 if the system has the type `struct sockaddr_storage'. */
#if (_MSC_VER > 1200)
#define HAVE_STRUCT_SOCKADDR_STORAGE 1 #define HAVE_STRUCT_SOCKADDR_STORAGE 1
#endif
/* Define to 1 if `ss_family' is member of `struct sockaddr_storage'. */ /* Define to 1 if `ss_family' is member of `struct sockaddr_storage'. */
#if (_MSC_VER > 1200)
#define HAVE_STRUCT_SOCKADDR_STORAGE_SS_FAMILY 1 #define HAVE_STRUCT_SOCKADDR_STORAGE_SS_FAMILY 1
#endif
/* Define to 1 if `ss_len' is member of `struct sockaddr_storage'. */ /* Define to 1 if `ss_len' is member of `struct sockaddr_storage'. */
/* #undef HAVE_STRUCT_SOCKADDR_STORAGE_SS_LEN */ /* #undef HAVE_STRUCT_SOCKADDR_STORAGE_SS_LEN */
@ -710,17 +687,13 @@
/* #undef USE_PAM */ /* #undef USE_PAM */
/* Define to 1 to use software CRC-32C implementation (slicing-by-8). */ /* Define to 1 to use software CRC-32C implementation (slicing-by-8). */
#if (_MSC_VER < 1500) /* #undef USE_SLICING_BY_8_CRC32C */
#define USE_SLICING_BY_8_CRC32C 1
#endif
/* Define to 1 use Intel SSE 4.2 CRC instructions. */ /* Define to 1 use Intel SSE 4.2 CRC instructions. */
/* #undef USE_SSE42_CRC32C */ /* #undef USE_SSE42_CRC32C */
/* Define to 1 to use Intel SSE 4.2 CRC instructions with a runtime check. */ /* Define to 1 to use Intel SSE 4.2 CRC instructions with a runtime check. */
#if (_MSC_VER >= 1500)
#define USE_SSE42_CRC32C_WITH_RUNTIME_CHECK #define USE_SSE42_CRC32C_WITH_RUNTIME_CHECK
#endif
/* Define to select SysV-style semaphores. */ /* Define to select SysV-style semaphores. */
/* #undef USE_SYSV_SEMAPHORES */ /* #undef USE_SYSV_SEMAPHORES */
@ -758,11 +731,7 @@
/* Define to keyword to use for C99 restrict support, or to nothing if this is /* Define to keyword to use for C99 restrict support, or to nothing if this is
not supported */ not supported */
/* Works for C and C++ in Visual Studio 2008 and upwards */ /* Works for C and C++ in Visual Studio 2008 and upwards */
#if (_MSC_VER >= 1500)
#define pg_restrict __restrict #define pg_restrict __restrict
#else
#define pg_restrict
#endif
/* Define to the equivalent of the C99 'restrict' keyword, or to /* Define to the equivalent of the C99 'restrict' keyword, or to
nothing if this is not supported. Do not define if restrict is nothing if this is not supported. Do not define if restrict is

View File

@ -35,7 +35,7 @@
* our errcode() function. Since it's likely to get included by standard * our errcode() function. Since it's likely to get included by standard
* system headers, pre-emptively include it now. * system headers, pre-emptively include it now.
*/ */
#if _MSC_VER >= 1400 || defined(HAVE_CRTDEFS_H) #if defined(_MSC_VER) || defined(HAVE_CRTDEFS_H)
#define errcode __msvc_errcode #define errcode __msvc_errcode
#include <crtdefs.h> #include <crtdefs.h>
#undef errcode #undef errcode

View File

@ -489,18 +489,6 @@ typedef unsigned short mode_t;
#define W_OK 2 #define W_OK 2
#define R_OK 4 #define R_OK 4
/*
* isinf() and isnan() should per spec be in <math.h>, but MSVC older than
* 2013 does not have them there. It does have _fpclass() and _isnan(), but
* they're in <float.h>, so include that here even though it means float.h
* percolates to our whole tree. Recent versions don't require any of this.
*/
#if (_MSC_VER < 1800)
#include <float.h>
#define isinf(x) ((_fpclass(x) == _FPCLASS_PINF) || (_fpclass(x) == _FPCLASS_NINF))
#define isnan(x) _isnan(x)
#endif
/* Pulled from Makefile.port in MinGW */ /* Pulled from Makefile.port in MinGW */
#define DLSUFFIX ".dll" #define DLSUFFIX ".dll"

View File

@ -63,7 +63,7 @@ extern int float8_cmp_internal(float8 a, float8 b);
* long lived bug in the Microsoft compilers. * long lived bug in the Microsoft compilers.
* See http://support.microsoft.com/kb/120968/en-us for details * See http://support.microsoft.com/kb/120968/en-us for details
*/ */
#if (_MSC_VER >= 1800) #ifdef _MSC_VER
#pragma warning(disable:4756) #pragma warning(disable:4756)
#endif #endif
static inline float4 static inline float4
@ -73,7 +73,7 @@ get_float4_infinity(void)
/* C99 standard way */ /* C99 standard way */
return (float4) INFINITY; return (float4) INFINITY;
#else #else
#if (_MSC_VER >= 1800) #ifdef _MSC_VER
#pragma warning(default:4756) #pragma warning(default:4756)
#endif #endif

View File

@ -25,13 +25,6 @@
#line 8 "nan_test.pgc" #line 8 "nan_test.pgc"
#ifdef WIN32
#if (_MSC_VER < 1800)
#define isinf(x) ((_fpclass(x) == _FPCLASS_PINF) || (_fpclass(x) == _FPCLASS_NINF))
#define isnan(x) _isnan(x)
#endif
#endif /* WIN32 */
int int
main(void) main(void)
{ {
@ -41,54 +34,54 @@ main(void)
#line 21 "nan_test.pgc" #line 14 "nan_test.pgc"
int id , loopcount ; int id , loopcount ;
#line 22 "nan_test.pgc" #line 15 "nan_test.pgc"
double d ; double d ;
#line 23 "nan_test.pgc" #line 16 "nan_test.pgc"
numeric * num ; numeric * num ;
#line 24 "nan_test.pgc" #line 17 "nan_test.pgc"
char val [ 16 ] ; char val [ 16 ] ;
/* exec sql end declare section */ /* exec sql end declare section */
#line 25 "nan_test.pgc" #line 18 "nan_test.pgc"
ECPGdebug(1, stderr); ECPGdebug(1, stderr);
/* exec sql whenever sqlerror do sqlprint ( ) ; */ /* exec sql whenever sqlerror do sqlprint ( ) ; */
#line 28 "nan_test.pgc" #line 21 "nan_test.pgc"
{ ECPGconnect(__LINE__, 0, "ecpg1_regression" , NULL, NULL , NULL, 0); { ECPGconnect(__LINE__, 0, "ecpg1_regression" , NULL, NULL , NULL, 0);
#line 30 "nan_test.pgc" #line 23 "nan_test.pgc"
if (sqlca.sqlcode < 0) sqlprint ( );} if (sqlca.sqlcode < 0) sqlprint ( );}
#line 30 "nan_test.pgc" #line 23 "nan_test.pgc"
{ ECPGdo(__LINE__, 0, 1, NULL, 0, ECPGst_normal, "create table nantest1 ( id int4 , d float8 )", ECPGt_EOIT, ECPGt_EORT); { ECPGdo(__LINE__, 0, 1, NULL, 0, ECPGst_normal, "create table nantest1 ( id int4 , d float8 )", ECPGt_EOIT, ECPGt_EORT);
#line 32 "nan_test.pgc" #line 25 "nan_test.pgc"
if (sqlca.sqlcode < 0) sqlprint ( );} if (sqlca.sqlcode < 0) sqlprint ( );}
#line 32 "nan_test.pgc" #line 25 "nan_test.pgc"
{ ECPGdo(__LINE__, 0, 1, NULL, 0, ECPGst_normal, "insert into nantest1 ( id , d ) values ( 1 , 'nan' :: float8 ) , ( 2 , 'infinity' :: float8 ) , ( 3 , '-infinity' :: float8 )", ECPGt_EOIT, ECPGt_EORT); { ECPGdo(__LINE__, 0, 1, NULL, 0, ECPGst_normal, "insert into nantest1 ( id , d ) values ( 1 , 'nan' :: float8 ) , ( 2 , 'infinity' :: float8 ) , ( 3 , '-infinity' :: float8 )", ECPGt_EOIT, ECPGt_EORT);
#line 33 "nan_test.pgc" #line 26 "nan_test.pgc"
if (sqlca.sqlcode < 0) sqlprint ( );} if (sqlca.sqlcode < 0) sqlprint ( );}
#line 33 "nan_test.pgc" #line 26 "nan_test.pgc"
/* declare cur cursor for select id , d , d from nantest1 */ /* declare cur cursor for select id , d , d from nantest1 */
#line 35 "nan_test.pgc" #line 28 "nan_test.pgc"
{ ECPGdo(__LINE__, 0, 1, NULL, 0, ECPGst_normal, "declare cur cursor for select id , d , d from nantest1", ECPGt_EOIT, ECPGt_EORT); { ECPGdo(__LINE__, 0, 1, NULL, 0, ECPGst_normal, "declare cur cursor for select id , d , d from nantest1", ECPGt_EOIT, ECPGt_EORT);
#line 36 "nan_test.pgc" #line 29 "nan_test.pgc"
if (sqlca.sqlcode < 0) sqlprint ( );} if (sqlca.sqlcode < 0) sqlprint ( );}
#line 36 "nan_test.pgc" #line 29 "nan_test.pgc"
for (loopcount = 0; loopcount < 100; loopcount++) for (loopcount = 0; loopcount < 100; loopcount++)
{ {
@ -99,10 +92,10 @@ if (sqlca.sqlcode < 0) sqlprint ( );}
ECPGt_NO_INDICATOR, NULL , 0L, 0L, 0L, ECPGt_NO_INDICATOR, NULL , 0L, 0L, 0L,
ECPGt_char,(val),(long)16,(long)1,(16)*sizeof(char), ECPGt_char,(val),(long)16,(long)1,(16)*sizeof(char),
ECPGt_NO_INDICATOR, NULL , 0L, 0L, 0L, ECPGt_EORT); ECPGt_NO_INDICATOR, NULL , 0L, 0L, 0L, ECPGt_EORT);
#line 39 "nan_test.pgc" #line 32 "nan_test.pgc"
if (sqlca.sqlcode < 0) sqlprint ( );} if (sqlca.sqlcode < 0) sqlprint ( );}
#line 39 "nan_test.pgc" #line 32 "nan_test.pgc"
if (sqlca.sqlcode) if (sqlca.sqlcode)
break; break;
@ -116,34 +109,34 @@ if (sqlca.sqlcode < 0) sqlprint ( );}
ECPGt_NO_INDICATOR, NULL , 0L, 0L, 0L, ECPGt_NO_INDICATOR, NULL , 0L, 0L, 0L,
ECPGt_double,&(d),(long)1,(long)1,sizeof(double), ECPGt_double,&(d),(long)1,(long)1,sizeof(double),
ECPGt_NO_INDICATOR, NULL , 0L, 0L, 0L, ECPGt_EOIT, ECPGt_EORT); ECPGt_NO_INDICATOR, NULL , 0L, 0L, 0L, ECPGt_EOIT, ECPGt_EORT);
#line 47 "nan_test.pgc" #line 40 "nan_test.pgc"
if (sqlca.sqlcode < 0) sqlprint ( );} if (sqlca.sqlcode < 0) sqlprint ( );}
#line 47 "nan_test.pgc" #line 40 "nan_test.pgc"
{ ECPGdo(__LINE__, 0, 1, NULL, 0, ECPGst_normal, "insert into nantest1 ( id , d ) values ( $1 + 6 , $2 )", { ECPGdo(__LINE__, 0, 1, NULL, 0, ECPGst_normal, "insert into nantest1 ( id , d ) values ( $1 + 6 , $2 )",
ECPGt_int,&(id),(long)1,(long)1,sizeof(int), ECPGt_int,&(id),(long)1,(long)1,sizeof(int),
ECPGt_NO_INDICATOR, NULL , 0L, 0L, 0L, ECPGt_NO_INDICATOR, NULL , 0L, 0L, 0L,
ECPGt_char,(val),(long)16,(long)1,(16)*sizeof(char), ECPGt_char,(val),(long)16,(long)1,(16)*sizeof(char),
ECPGt_NO_INDICATOR, NULL , 0L, 0L, 0L, ECPGt_EOIT, ECPGt_EORT); ECPGt_NO_INDICATOR, NULL , 0L, 0L, 0L, ECPGt_EOIT, ECPGt_EORT);
#line 48 "nan_test.pgc" #line 41 "nan_test.pgc"
if (sqlca.sqlcode < 0) sqlprint ( );} if (sqlca.sqlcode < 0) sqlprint ( );}
#line 48 "nan_test.pgc" #line 41 "nan_test.pgc"
} }
{ ECPGdo(__LINE__, 0, 1, NULL, 0, ECPGst_normal, "close cur", ECPGt_EOIT, ECPGt_EORT); { ECPGdo(__LINE__, 0, 1, NULL, 0, ECPGst_normal, "close cur", ECPGt_EOIT, ECPGt_EORT);
#line 50 "nan_test.pgc" #line 43 "nan_test.pgc"
if (sqlca.sqlcode < 0) sqlprint ( );} if (sqlca.sqlcode < 0) sqlprint ( );}
#line 50 "nan_test.pgc" #line 43 "nan_test.pgc"
{ ECPGdo(__LINE__, 0, 1, NULL, 0, ECPGst_normal, "declare cur cursor for select id , d , d from nantest1", ECPGt_EOIT, ECPGt_EORT); { ECPGdo(__LINE__, 0, 1, NULL, 0, ECPGst_normal, "declare cur cursor for select id , d , d from nantest1", ECPGt_EOIT, ECPGt_EORT);
#line 52 "nan_test.pgc" #line 45 "nan_test.pgc"
if (sqlca.sqlcode < 0) sqlprint ( );} if (sqlca.sqlcode < 0) sqlprint ( );}
#line 52 "nan_test.pgc" #line 45 "nan_test.pgc"
for (loopcount = 0; loopcount < 100; loopcount++) for (loopcount = 0; loopcount < 100; loopcount++)
{ {
@ -154,10 +147,10 @@ if (sqlca.sqlcode < 0) sqlprint ( );}
ECPGt_NO_INDICATOR, NULL , 0L, 0L, 0L, ECPGt_NO_INDICATOR, NULL , 0L, 0L, 0L,
ECPGt_char,(val),(long)16,(long)1,(16)*sizeof(char), ECPGt_char,(val),(long)16,(long)1,(16)*sizeof(char),
ECPGt_NO_INDICATOR, NULL , 0L, 0L, 0L, ECPGt_EORT); ECPGt_NO_INDICATOR, NULL , 0L, 0L, 0L, ECPGt_EORT);
#line 55 "nan_test.pgc" #line 48 "nan_test.pgc"
if (sqlca.sqlcode < 0) sqlprint ( );} if (sqlca.sqlcode < 0) sqlprint ( );}
#line 55 "nan_test.pgc" #line 48 "nan_test.pgc"
if (sqlca.sqlcode) if (sqlca.sqlcode)
break; break;
@ -167,25 +160,25 @@ if (sqlca.sqlcode < 0) sqlprint ( );}
printf("%d NaN '%s'\n", id, val); printf("%d NaN '%s'\n", id, val);
} }
{ ECPGdo(__LINE__, 0, 1, NULL, 0, ECPGst_normal, "close cur", ECPGt_EOIT, ECPGt_EORT); { ECPGdo(__LINE__, 0, 1, NULL, 0, ECPGst_normal, "close cur", ECPGt_EOIT, ECPGt_EORT);
#line 63 "nan_test.pgc" #line 56 "nan_test.pgc"
if (sqlca.sqlcode < 0) sqlprint ( );} if (sqlca.sqlcode < 0) sqlprint ( );}
#line 63 "nan_test.pgc" #line 56 "nan_test.pgc"
num = PGTYPESnumeric_new(); num = PGTYPESnumeric_new();
{ ECPGdo(__LINE__, 0, 1, NULL, 0, ECPGst_normal, "create table nantest2 ( id int4 , d numeric )", ECPGt_EOIT, ECPGt_EORT); { ECPGdo(__LINE__, 0, 1, NULL, 0, ECPGst_normal, "create table nantest2 ( id int4 , d numeric )", ECPGt_EOIT, ECPGt_EORT);
#line 67 "nan_test.pgc" #line 60 "nan_test.pgc"
if (sqlca.sqlcode < 0) sqlprint ( );} if (sqlca.sqlcode < 0) sqlprint ( );}
#line 67 "nan_test.pgc" #line 60 "nan_test.pgc"
{ ECPGdo(__LINE__, 0, 1, NULL, 0, ECPGst_normal, "insert into nantest2 ( id , d ) values ( 4 , 'nan' :: numeric )", ECPGt_EOIT, ECPGt_EORT); { ECPGdo(__LINE__, 0, 1, NULL, 0, ECPGst_normal, "insert into nantest2 ( id , d ) values ( 4 , 'nan' :: numeric )", ECPGt_EOIT, ECPGt_EORT);
#line 68 "nan_test.pgc" #line 61 "nan_test.pgc"
if (sqlca.sqlcode < 0) sqlprint ( );} if (sqlca.sqlcode < 0) sqlprint ( );}
#line 68 "nan_test.pgc" #line 61 "nan_test.pgc"
{ ECPGdo(__LINE__, 0, 1, NULL, 0, ECPGst_normal, "select id , d , d from nantest2 where id = 4", ECPGt_EOIT, { ECPGdo(__LINE__, 0, 1, NULL, 0, ECPGst_normal, "select id , d , d from nantest2 where id = 4", ECPGt_EOIT,
@ -195,10 +188,10 @@ if (sqlca.sqlcode < 0) sqlprint ( );}
ECPGt_NO_INDICATOR, NULL , 0L, 0L, 0L, ECPGt_NO_INDICATOR, NULL , 0L, 0L, 0L,
ECPGt_char,(val),(long)16,(long)1,(16)*sizeof(char), ECPGt_char,(val),(long)16,(long)1,(16)*sizeof(char),
ECPGt_NO_INDICATOR, NULL , 0L, 0L, 0L, ECPGt_EORT); ECPGt_NO_INDICATOR, NULL , 0L, 0L, 0L, ECPGt_EORT);
#line 70 "nan_test.pgc" #line 63 "nan_test.pgc"
if (sqlca.sqlcode < 0) sqlprint ( );} if (sqlca.sqlcode < 0) sqlprint ( );}
#line 70 "nan_test.pgc" #line 63 "nan_test.pgc"
printf("%d %s '%s'\n", id, (num->sign == NUMERIC_NAN ? "NaN" : "not NaN"), val); printf("%d %s '%s'\n", id, (num->sign == NUMERIC_NAN ? "NaN" : "not NaN"), val);
@ -206,28 +199,28 @@ if (sqlca.sqlcode < 0) sqlprint ( );}
{ ECPGdo(__LINE__, 0, 1, NULL, 0, ECPGst_normal, "insert into nantest2 ( id , d ) values ( 5 , $1 )", { ECPGdo(__LINE__, 0, 1, NULL, 0, ECPGst_normal, "insert into nantest2 ( id , d ) values ( 5 , $1 )",
ECPGt_numeric,&(num),(long)1,(long)0,sizeof(numeric), ECPGt_numeric,&(num),(long)1,(long)0,sizeof(numeric),
ECPGt_NO_INDICATOR, NULL , 0L, 0L, 0L, ECPGt_EOIT, ECPGt_EORT); ECPGt_NO_INDICATOR, NULL , 0L, 0L, 0L, ECPGt_EOIT, ECPGt_EORT);
#line 74 "nan_test.pgc" #line 67 "nan_test.pgc"
if (sqlca.sqlcode < 0) sqlprint ( );} if (sqlca.sqlcode < 0) sqlprint ( );}
#line 74 "nan_test.pgc" #line 67 "nan_test.pgc"
{ ECPGdo(__LINE__, 0, 1, NULL, 0, ECPGst_normal, "insert into nantest2 ( id , d ) values ( 6 , $1 )", { ECPGdo(__LINE__, 0, 1, NULL, 0, ECPGst_normal, "insert into nantest2 ( id , d ) values ( 6 , $1 )",
ECPGt_char,(val),(long)16,(long)1,(16)*sizeof(char), ECPGt_char,(val),(long)16,(long)1,(16)*sizeof(char),
ECPGt_NO_INDICATOR, NULL , 0L, 0L, 0L, ECPGt_EOIT, ECPGt_EORT); ECPGt_NO_INDICATOR, NULL , 0L, 0L, 0L, ECPGt_EOIT, ECPGt_EORT);
#line 75 "nan_test.pgc" #line 68 "nan_test.pgc"
if (sqlca.sqlcode < 0) sqlprint ( );} if (sqlca.sqlcode < 0) sqlprint ( );}
#line 75 "nan_test.pgc" #line 68 "nan_test.pgc"
/* declare cur1 cursor for select id , d , d from nantest2 */ /* declare cur1 cursor for select id , d , d from nantest2 */
#line 77 "nan_test.pgc" #line 70 "nan_test.pgc"
{ ECPGdo(__LINE__, 0, 1, NULL, 0, ECPGst_normal, "declare cur1 cursor for select id , d , d from nantest2", ECPGt_EOIT, ECPGt_EORT); { ECPGdo(__LINE__, 0, 1, NULL, 0, ECPGst_normal, "declare cur1 cursor for select id , d , d from nantest2", ECPGt_EOIT, ECPGt_EORT);
#line 78 "nan_test.pgc" #line 71 "nan_test.pgc"
if (sqlca.sqlcode < 0) sqlprint ( );} if (sqlca.sqlcode < 0) sqlprint ( );}
#line 78 "nan_test.pgc" #line 71 "nan_test.pgc"
for (loopcount = 0; loopcount < 100; loopcount++) for (loopcount = 0; loopcount < 100; loopcount++)
{ {
@ -238,35 +231,35 @@ if (sqlca.sqlcode < 0) sqlprint ( );}
ECPGt_NO_INDICATOR, NULL , 0L, 0L, 0L, ECPGt_NO_INDICATOR, NULL , 0L, 0L, 0L,
ECPGt_char,(val),(long)16,(long)1,(16)*sizeof(char), ECPGt_char,(val),(long)16,(long)1,(16)*sizeof(char),
ECPGt_NO_INDICATOR, NULL , 0L, 0L, 0L, ECPGt_EORT); ECPGt_NO_INDICATOR, NULL , 0L, 0L, 0L, ECPGt_EORT);
#line 81 "nan_test.pgc" #line 74 "nan_test.pgc"
if (sqlca.sqlcode < 0) sqlprint ( );} if (sqlca.sqlcode < 0) sqlprint ( );}
#line 81 "nan_test.pgc" #line 74 "nan_test.pgc"
if (sqlca.sqlcode) if (sqlca.sqlcode)
break; break;
printf("%d %s '%s'\n", id, (num->sign == NUMERIC_NAN ? "NaN" : "not NaN"), val); printf("%d %s '%s'\n", id, (num->sign == NUMERIC_NAN ? "NaN" : "not NaN"), val);
} }
{ ECPGdo(__LINE__, 0, 1, NULL, 0, ECPGst_normal, "close cur1", ECPGt_EOIT, ECPGt_EORT); { ECPGdo(__LINE__, 0, 1, NULL, 0, ECPGst_normal, "close cur1", ECPGt_EOIT, ECPGt_EORT);
#line 86 "nan_test.pgc" #line 79 "nan_test.pgc"
if (sqlca.sqlcode < 0) sqlprint ( );} if (sqlca.sqlcode < 0) sqlprint ( );}
#line 86 "nan_test.pgc" #line 79 "nan_test.pgc"
PGTYPESnumeric_free(num); PGTYPESnumeric_free(num);
{ ECPGtrans(__LINE__, NULL, "rollback"); { ECPGtrans(__LINE__, NULL, "rollback");
#line 90 "nan_test.pgc" #line 83 "nan_test.pgc"
if (sqlca.sqlcode < 0) sqlprint ( );} if (sqlca.sqlcode < 0) sqlprint ( );}
#line 90 "nan_test.pgc" #line 83 "nan_test.pgc"
{ ECPGdisconnect(__LINE__, "CURRENT"); { ECPGdisconnect(__LINE__, "CURRENT");
#line 91 "nan_test.pgc" #line 84 "nan_test.pgc"
if (sqlca.sqlcode < 0) sqlprint ( );} if (sqlca.sqlcode < 0) sqlprint ( );}
#line 91 "nan_test.pgc" #line 84 "nan_test.pgc"
return 0; return 0;

View File

@ -2,359 +2,359 @@
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ECPGconnect: opening database ecpg1_regression on <DEFAULT> port <DEFAULT> [NO_PID]: ECPGconnect: opening database ecpg1_regression on <DEFAULT> port <DEFAULT>
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_execute on line 32: query: create table nantest1 ( id int4 , d float8 ); with 0 parameter(s) on connection ecpg1_regression [NO_PID]: ecpg_execute on line 25: query: create table nantest1 ( id int4 , d float8 ); with 0 parameter(s) on connection ecpg1_regression
[NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_execute on line 25: using PQexec
[NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_process_output on line 25: OK: CREATE TABLE
[NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_execute on line 26: query: insert into nantest1 ( id , d ) values ( 1 , 'nan' :: float8 ) , ( 2 , 'infinity' :: float8 ) , ( 3 , '-infinity' :: float8 ); with 0 parameter(s) on connection ecpg1_regression
[NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_execute on line 26: using PQexec
[NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_process_output on line 26: OK: INSERT 0 3
[NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_execute on line 29: query: declare cur cursor for select id , d , d from nantest1; with 0 parameter(s) on connection ecpg1_regression
[NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_execute on line 29: using PQexec
[NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_process_output on line 29: OK: DECLARE CURSOR
[NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_execute on line 32: query: fetch from cur; with 0 parameter(s) on connection ecpg1_regression
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_execute on line 32: using PQexec [NO_PID]: ecpg_execute on line 32: using PQexec
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_process_output on line 32: OK: CREATE TABLE [NO_PID]: ecpg_process_output on line 32: correctly got 1 tuples with 3 fields
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_execute on line 33: query: insert into nantest1 ( id , d ) values ( 1 , 'nan' :: float8 ) , ( 2 , 'infinity' :: float8 ) , ( 3 , '-infinity' :: float8 ); with 0 parameter(s) on connection ecpg1_regression [NO_PID]: ecpg_get_data on line 32: RESULT: 1 offset: -1; array: no
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_execute on line 33: using PQexec [NO_PID]: ecpg_get_data on line 32: RESULT: NaN offset: -1; array: no
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_process_output on line 33: OK: INSERT 0 3 [NO_PID]: ecpg_get_data on line 32: RESULT: NaN offset: -1; array: no
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_execute on line 36: query: declare cur cursor for select id , d , d from nantest1; with 0 parameter(s) on connection ecpg1_regression [NO_PID]: ecpg_execute on line 40: query: insert into nantest1 ( id , d ) values ( $1 + 3 , $2 ); with 2 parameter(s) on connection ecpg1_regression
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_execute on line 36: using PQexec [NO_PID]: ecpg_execute on line 40: using PQexecParams
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_process_output on line 36: OK: DECLARE CURSOR [NO_PID]: ecpg_free_params on line 40: parameter 1 = 1
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_execute on line 39: query: fetch from cur; with 0 parameter(s) on connection ecpg1_regression [NO_PID]: ecpg_free_params on line 40: parameter 2 = NaN
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_execute on line 39: using PQexec [NO_PID]: ecpg_process_output on line 40: OK: INSERT 0 1
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_process_output on line 39: correctly got 1 tuples with 3 fields [NO_PID]: ecpg_execute on line 41: query: insert into nantest1 ( id , d ) values ( $1 + 6 , $2 ); with 2 parameter(s) on connection ecpg1_regression
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_get_data on line 39: RESULT: 1 offset: -1; array: no [NO_PID]: ecpg_execute on line 41: using PQexecParams
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_get_data on line 39: RESULT: NaN offset: -1; array: no [NO_PID]: ecpg_free_params on line 41: parameter 1 = 1
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_get_data on line 39: RESULT: NaN offset: -1; array: no [NO_PID]: ecpg_free_params on line 41: parameter 2 = NaN
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_execute on line 47: query: insert into nantest1 ( id , d ) values ( $1 + 3 , $2 ); with 2 parameter(s) on connection ecpg1_regression [NO_PID]: ecpg_process_output on line 41: OK: INSERT 0 1
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_execute on line 47: using PQexecParams [NO_PID]: ecpg_execute on line 32: query: fetch from cur; with 0 parameter(s) on connection ecpg1_regression
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_free_params on line 47: parameter 1 = 1 [NO_PID]: ecpg_execute on line 32: using PQexec
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_free_params on line 47: parameter 2 = NaN [NO_PID]: ecpg_process_output on line 32: correctly got 1 tuples with 3 fields
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_process_output on line 47: OK: INSERT 0 1 [NO_PID]: ecpg_get_data on line 32: RESULT: 2 offset: -1; array: no
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_execute on line 48: query: insert into nantest1 ( id , d ) values ( $1 + 6 , $2 ); with 2 parameter(s) on connection ecpg1_regression [NO_PID]: ecpg_get_data on line 32: RESULT: Infinity offset: -1; array: no
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_execute on line 48: using PQexecParams [NO_PID]: ecpg_get_data on line 32: RESULT: Infinity offset: -1; array: no
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_free_params on line 48: parameter 1 = 1 [NO_PID]: ecpg_execute on line 40: query: insert into nantest1 ( id , d ) values ( $1 + 3 , $2 ); with 2 parameter(s) on connection ecpg1_regression
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_free_params on line 48: parameter 2 = NaN [NO_PID]: ecpg_execute on line 40: using PQexecParams
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_process_output on line 48: OK: INSERT 0 1 [NO_PID]: ecpg_free_params on line 40: parameter 1 = 2
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_execute on line 39: query: fetch from cur; with 0 parameter(s) on connection ecpg1_regression [NO_PID]: ecpg_free_params on line 40: parameter 2 = Infinity
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_execute on line 39: using PQexec [NO_PID]: ecpg_process_output on line 40: OK: INSERT 0 1
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_process_output on line 39: correctly got 1 tuples with 3 fields [NO_PID]: ecpg_execute on line 41: query: insert into nantest1 ( id , d ) values ( $1 + 6 , $2 ); with 2 parameter(s) on connection ecpg1_regression
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_get_data on line 39: RESULT: 2 offset: -1; array: no [NO_PID]: ecpg_execute on line 41: using PQexecParams
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_get_data on line 39: RESULT: Infinity offset: -1; array: no [NO_PID]: ecpg_free_params on line 41: parameter 1 = 2
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_get_data on line 39: RESULT: Infinity offset: -1; array: no [NO_PID]: ecpg_free_params on line 41: parameter 2 = Infinity
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_execute on line 47: query: insert into nantest1 ( id , d ) values ( $1 + 3 , $2 ); with 2 parameter(s) on connection ecpg1_regression [NO_PID]: ecpg_process_output on line 41: OK: INSERT 0 1
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_execute on line 47: using PQexecParams [NO_PID]: ecpg_execute on line 32: query: fetch from cur; with 0 parameter(s) on connection ecpg1_regression
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_free_params on line 47: parameter 1 = 2 [NO_PID]: ecpg_execute on line 32: using PQexec
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_free_params on line 47: parameter 2 = Infinity [NO_PID]: ecpg_process_output on line 32: correctly got 1 tuples with 3 fields
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_process_output on line 47: OK: INSERT 0 1 [NO_PID]: ecpg_get_data on line 32: RESULT: 3 offset: -1; array: no
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_execute on line 48: query: insert into nantest1 ( id , d ) values ( $1 + 6 , $2 ); with 2 parameter(s) on connection ecpg1_regression [NO_PID]: ecpg_get_data on line 32: RESULT: -Infinity offset: -1; array: no
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_execute on line 48: using PQexecParams [NO_PID]: ecpg_get_data on line 32: RESULT: -Infinity offset: -1; array: no
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_free_params on line 48: parameter 1 = 2 [NO_PID]: ecpg_execute on line 40: query: insert into nantest1 ( id , d ) values ( $1 + 3 , $2 ); with 2 parameter(s) on connection ecpg1_regression
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_free_params on line 48: parameter 2 = Infinity [NO_PID]: ecpg_execute on line 40: using PQexecParams
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_process_output on line 48: OK: INSERT 0 1 [NO_PID]: ecpg_free_params on line 40: parameter 1 = 3
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_execute on line 39: query: fetch from cur; with 0 parameter(s) on connection ecpg1_regression [NO_PID]: ecpg_free_params on line 40: parameter 2 = -Infinity
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_execute on line 39: using PQexec [NO_PID]: ecpg_process_output on line 40: OK: INSERT 0 1
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_process_output on line 39: correctly got 1 tuples with 3 fields [NO_PID]: ecpg_execute on line 41: query: insert into nantest1 ( id , d ) values ( $1 + 6 , $2 ); with 2 parameter(s) on connection ecpg1_regression
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_get_data on line 39: RESULT: 3 offset: -1; array: no [NO_PID]: ecpg_execute on line 41: using PQexecParams
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_get_data on line 39: RESULT: -Infinity offset: -1; array: no [NO_PID]: ecpg_free_params on line 41: parameter 1 = 3
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_get_data on line 39: RESULT: -Infinity offset: -1; array: no [NO_PID]: ecpg_free_params on line 41: parameter 2 = -Infinity
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_execute on line 47: query: insert into nantest1 ( id , d ) values ( $1 + 3 , $2 ); with 2 parameter(s) on connection ecpg1_regression [NO_PID]: ecpg_process_output on line 41: OK: INSERT 0 1
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_execute on line 47: using PQexecParams [NO_PID]: ecpg_execute on line 32: query: fetch from cur; with 0 parameter(s) on connection ecpg1_regression
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_free_params on line 47: parameter 1 = 3 [NO_PID]: ecpg_execute on line 32: using PQexec
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_free_params on line 47: parameter 2 = -Infinity [NO_PID]: ecpg_process_output on line 32: correctly got 0 tuples with 3 fields
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_process_output on line 47: OK: INSERT 0 1 [NO_PID]: raising sqlcode 100 on line 32: no data found on line 32
[NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_execute on line 48: query: insert into nantest1 ( id , d ) values ( $1 + 6 , $2 ); with 2 parameter(s) on connection ecpg1_regression
[NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_execute on line 48: using PQexecParams
[NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_free_params on line 48: parameter 1 = 3
[NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_free_params on line 48: parameter 2 = -Infinity
[NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_process_output on line 48: OK: INSERT 0 1
[NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_execute on line 39: query: fetch from cur; with 0 parameter(s) on connection ecpg1_regression
[NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_execute on line 39: using PQexec
[NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_process_output on line 39: correctly got 0 tuples with 3 fields
[NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: raising sqlcode 100 on line 39: no data found on line 39
[NO_PID]: sqlca: code: 100, state: 02000 [NO_PID]: sqlca: code: 100, state: 02000
[NO_PID]: ecpg_execute on line 50: query: close cur; with 0 parameter(s) on connection ecpg1_regression [NO_PID]: ecpg_execute on line 43: query: close cur; with 0 parameter(s) on connection ecpg1_regression
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_execute on line 50: using PQexec [NO_PID]: ecpg_execute on line 43: using PQexec
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_process_output on line 50: OK: CLOSE CURSOR [NO_PID]: ecpg_process_output on line 43: OK: CLOSE CURSOR
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_execute on line 52: query: declare cur cursor for select id , d , d from nantest1; with 0 parameter(s) on connection ecpg1_regression [NO_PID]: ecpg_execute on line 45: query: declare cur cursor for select id , d , d from nantest1; with 0 parameter(s) on connection ecpg1_regression
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_execute on line 52: using PQexec [NO_PID]: ecpg_execute on line 45: using PQexec
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_process_output on line 52: OK: DECLARE CURSOR [NO_PID]: ecpg_process_output on line 45: OK: DECLARE CURSOR
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_execute on line 55: query: fetch from cur; with 0 parameter(s) on connection ecpg1_regression [NO_PID]: ecpg_execute on line 48: query: fetch from cur; with 0 parameter(s) on connection ecpg1_regression
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_execute on line 55: using PQexec [NO_PID]: ecpg_execute on line 48: using PQexec
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_process_output on line 55: correctly got 1 tuples with 3 fields [NO_PID]: ecpg_process_output on line 48: correctly got 1 tuples with 3 fields
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_get_data on line 55: RESULT: 1 offset: -1; array: no [NO_PID]: ecpg_get_data on line 48: RESULT: 1 offset: -1; array: no
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_get_data on line 55: RESULT: NaN offset: -1; array: no [NO_PID]: ecpg_get_data on line 48: RESULT: NaN offset: -1; array: no
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_get_data on line 55: RESULT: NaN offset: -1; array: no [NO_PID]: ecpg_get_data on line 48: RESULT: NaN offset: -1; array: no
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_execute on line 55: query: fetch from cur; with 0 parameter(s) on connection ecpg1_regression [NO_PID]: ecpg_execute on line 48: query: fetch from cur; with 0 parameter(s) on connection ecpg1_regression
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_execute on line 55: using PQexec [NO_PID]: ecpg_execute on line 48: using PQexec
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_process_output on line 55: correctly got 1 tuples with 3 fields [NO_PID]: ecpg_process_output on line 48: correctly got 1 tuples with 3 fields
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_get_data on line 55: RESULT: 2 offset: -1; array: no [NO_PID]: ecpg_get_data on line 48: RESULT: 2 offset: -1; array: no
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_get_data on line 55: RESULT: Infinity offset: -1; array: no [NO_PID]: ecpg_get_data on line 48: RESULT: Infinity offset: -1; array: no
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_get_data on line 55: RESULT: Infinity offset: -1; array: no [NO_PID]: ecpg_get_data on line 48: RESULT: Infinity offset: -1; array: no
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_execute on line 55: query: fetch from cur; with 0 parameter(s) on connection ecpg1_regression [NO_PID]: ecpg_execute on line 48: query: fetch from cur; with 0 parameter(s) on connection ecpg1_regression
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_execute on line 55: using PQexec [NO_PID]: ecpg_execute on line 48: using PQexec
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_process_output on line 55: correctly got 1 tuples with 3 fields [NO_PID]: ecpg_process_output on line 48: correctly got 1 tuples with 3 fields
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_get_data on line 55: RESULT: 3 offset: -1; array: no [NO_PID]: ecpg_get_data on line 48: RESULT: 3 offset: -1; array: no
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_get_data on line 55: RESULT: -Infinity offset: -1; array: no [NO_PID]: ecpg_get_data on line 48: RESULT: -Infinity offset: -1; array: no
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_get_data on line 55: RESULT: -Infinity offset: -1; array: no [NO_PID]: ecpg_get_data on line 48: RESULT: -Infinity offset: -1; array: no
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_execute on line 55: query: fetch from cur; with 0 parameter(s) on connection ecpg1_regression [NO_PID]: ecpg_execute on line 48: query: fetch from cur; with 0 parameter(s) on connection ecpg1_regression
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_execute on line 55: using PQexec [NO_PID]: ecpg_execute on line 48: using PQexec
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_process_output on line 55: correctly got 1 tuples with 3 fields [NO_PID]: ecpg_process_output on line 48: correctly got 1 tuples with 3 fields
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_get_data on line 55: RESULT: 4 offset: -1; array: no [NO_PID]: ecpg_get_data on line 48: RESULT: 4 offset: -1; array: no
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_get_data on line 55: RESULT: NaN offset: -1; array: no [NO_PID]: ecpg_get_data on line 48: RESULT: NaN offset: -1; array: no
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_get_data on line 55: RESULT: NaN offset: -1; array: no [NO_PID]: ecpg_get_data on line 48: RESULT: NaN offset: -1; array: no
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_execute on line 55: query: fetch from cur; with 0 parameter(s) on connection ecpg1_regression [NO_PID]: ecpg_execute on line 48: query: fetch from cur; with 0 parameter(s) on connection ecpg1_regression
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_execute on line 55: using PQexec [NO_PID]: ecpg_execute on line 48: using PQexec
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_process_output on line 55: correctly got 1 tuples with 3 fields [NO_PID]: ecpg_process_output on line 48: correctly got 1 tuples with 3 fields
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_get_data on line 55: RESULT: 7 offset: -1; array: no [NO_PID]: ecpg_get_data on line 48: RESULT: 7 offset: -1; array: no
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_get_data on line 55: RESULT: NaN offset: -1; array: no [NO_PID]: ecpg_get_data on line 48: RESULT: NaN offset: -1; array: no
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_get_data on line 55: RESULT: NaN offset: -1; array: no [NO_PID]: ecpg_get_data on line 48: RESULT: NaN offset: -1; array: no
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_execute on line 55: query: fetch from cur; with 0 parameter(s) on connection ecpg1_regression [NO_PID]: ecpg_execute on line 48: query: fetch from cur; with 0 parameter(s) on connection ecpg1_regression
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_execute on line 55: using PQexec [NO_PID]: ecpg_execute on line 48: using PQexec
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_process_output on line 55: correctly got 1 tuples with 3 fields [NO_PID]: ecpg_process_output on line 48: correctly got 1 tuples with 3 fields
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_get_data on line 55: RESULT: 5 offset: -1; array: no [NO_PID]: ecpg_get_data on line 48: RESULT: 5 offset: -1; array: no
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_get_data on line 55: RESULT: Infinity offset: -1; array: no [NO_PID]: ecpg_get_data on line 48: RESULT: Infinity offset: -1; array: no
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_get_data on line 55: RESULT: Infinity offset: -1; array: no [NO_PID]: ecpg_get_data on line 48: RESULT: Infinity offset: -1; array: no
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_execute on line 55: query: fetch from cur; with 0 parameter(s) on connection ecpg1_regression [NO_PID]: ecpg_execute on line 48: query: fetch from cur; with 0 parameter(s) on connection ecpg1_regression
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_execute on line 55: using PQexec [NO_PID]: ecpg_execute on line 48: using PQexec
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_process_output on line 55: correctly got 1 tuples with 3 fields [NO_PID]: ecpg_process_output on line 48: correctly got 1 tuples with 3 fields
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_get_data on line 55: RESULT: 8 offset: -1; array: no [NO_PID]: ecpg_get_data on line 48: RESULT: 8 offset: -1; array: no
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_get_data on line 55: RESULT: Infinity offset: -1; array: no [NO_PID]: ecpg_get_data on line 48: RESULT: Infinity offset: -1; array: no
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_get_data on line 55: RESULT: Infinity offset: -1; array: no [NO_PID]: ecpg_get_data on line 48: RESULT: Infinity offset: -1; array: no
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_execute on line 55: query: fetch from cur; with 0 parameter(s) on connection ecpg1_regression [NO_PID]: ecpg_execute on line 48: query: fetch from cur; with 0 parameter(s) on connection ecpg1_regression
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_execute on line 55: using PQexec [NO_PID]: ecpg_execute on line 48: using PQexec
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_process_output on line 55: correctly got 1 tuples with 3 fields [NO_PID]: ecpg_process_output on line 48: correctly got 1 tuples with 3 fields
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_get_data on line 55: RESULT: 6 offset: -1; array: no [NO_PID]: ecpg_get_data on line 48: RESULT: 6 offset: -1; array: no
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_get_data on line 55: RESULT: -Infinity offset: -1; array: no [NO_PID]: ecpg_get_data on line 48: RESULT: -Infinity offset: -1; array: no
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_get_data on line 55: RESULT: -Infinity offset: -1; array: no [NO_PID]: ecpg_get_data on line 48: RESULT: -Infinity offset: -1; array: no
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_execute on line 55: query: fetch from cur; with 0 parameter(s) on connection ecpg1_regression [NO_PID]: ecpg_execute on line 48: query: fetch from cur; with 0 parameter(s) on connection ecpg1_regression
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_execute on line 55: using PQexec [NO_PID]: ecpg_execute on line 48: using PQexec
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_process_output on line 55: correctly got 1 tuples with 3 fields [NO_PID]: ecpg_process_output on line 48: correctly got 1 tuples with 3 fields
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_get_data on line 55: RESULT: 9 offset: -1; array: no [NO_PID]: ecpg_get_data on line 48: RESULT: 9 offset: -1; array: no
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_get_data on line 55: RESULT: -Infinity offset: -1; array: no [NO_PID]: ecpg_get_data on line 48: RESULT: -Infinity offset: -1; array: no
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_get_data on line 55: RESULT: -Infinity offset: -1; array: no [NO_PID]: ecpg_get_data on line 48: RESULT: -Infinity offset: -1; array: no
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_execute on line 55: query: fetch from cur; with 0 parameter(s) on connection ecpg1_regression [NO_PID]: ecpg_execute on line 48: query: fetch from cur; with 0 parameter(s) on connection ecpg1_regression
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_execute on line 55: using PQexec [NO_PID]: ecpg_execute on line 48: using PQexec
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_process_output on line 55: correctly got 0 tuples with 3 fields [NO_PID]: ecpg_process_output on line 48: correctly got 0 tuples with 3 fields
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: raising sqlcode 100 on line 55: no data found on line 55 [NO_PID]: raising sqlcode 100 on line 48: no data found on line 48
[NO_PID]: sqlca: code: 100, state: 02000 [NO_PID]: sqlca: code: 100, state: 02000
[NO_PID]: ecpg_execute on line 63: query: close cur; with 0 parameter(s) on connection ecpg1_regression [NO_PID]: ecpg_execute on line 56: query: close cur; with 0 parameter(s) on connection ecpg1_regression
[NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_execute on line 56: using PQexec
[NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_process_output on line 56: OK: CLOSE CURSOR
[NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_execute on line 60: query: create table nantest2 ( id int4 , d numeric ); with 0 parameter(s) on connection ecpg1_regression
[NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_execute on line 60: using PQexec
[NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_process_output on line 60: OK: CREATE TABLE
[NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_execute on line 61: query: insert into nantest2 ( id , d ) values ( 4 , 'nan' :: numeric ); with 0 parameter(s) on connection ecpg1_regression
[NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_execute on line 61: using PQexec
[NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_process_output on line 61: OK: INSERT 0 1
[NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_execute on line 63: query: select id , d , d from nantest2 where id = 4; with 0 parameter(s) on connection ecpg1_regression
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_execute on line 63: using PQexec [NO_PID]: ecpg_execute on line 63: using PQexec
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_process_output on line 63: OK: CLOSE CURSOR [NO_PID]: ecpg_process_output on line 63: correctly got 1 tuples with 3 fields
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_execute on line 67: query: create table nantest2 ( id int4 , d numeric ); with 0 parameter(s) on connection ecpg1_regression [NO_PID]: ecpg_get_data on line 63: RESULT: 4 offset: -1; array: no
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_execute on line 67: using PQexec [NO_PID]: ecpg_get_data on line 63: RESULT: NaN offset: -1; array: no
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_process_output on line 67: OK: CREATE TABLE [NO_PID]: ecpg_get_data on line 63: RESULT: NaN offset: -1; array: no
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_execute on line 68: query: insert into nantest2 ( id , d ) values ( 4 , 'nan' :: numeric ); with 0 parameter(s) on connection ecpg1_regression [NO_PID]: ecpg_execute on line 67: query: insert into nantest2 ( id , d ) values ( 5 , $1 ); with 1 parameter(s) on connection ecpg1_regression
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_execute on line 68: using PQexec [NO_PID]: ecpg_execute on line 67: using PQexecParams
[NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_free_params on line 67: parameter 1 = NaN
[NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_process_output on line 67: OK: INSERT 0 1
[NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_execute on line 68: query: insert into nantest2 ( id , d ) values ( 6 , $1 ); with 1 parameter(s) on connection ecpg1_regression
[NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_execute on line 68: using PQexecParams
[NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_free_params on line 68: parameter 1 = NaN
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_process_output on line 68: OK: INSERT 0 1 [NO_PID]: ecpg_process_output on line 68: OK: INSERT 0 1
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_execute on line 70: query: select id , d , d from nantest2 where id = 4; with 0 parameter(s) on connection ecpg1_regression [NO_PID]: ecpg_execute on line 71: query: declare cur1 cursor for select id , d , d from nantest2; with 0 parameter(s) on connection ecpg1_regression
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_execute on line 70: using PQexec [NO_PID]: ecpg_execute on line 71: using PQexec
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_process_output on line 70: correctly got 1 tuples with 3 fields [NO_PID]: ecpg_process_output on line 71: OK: DECLARE CURSOR
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_get_data on line 70: RESULT: 4 offset: -1; array: no [NO_PID]: ecpg_execute on line 74: query: fetch from cur1; with 0 parameter(s) on connection ecpg1_regression
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_get_data on line 70: RESULT: NaN offset: -1; array: no [NO_PID]: ecpg_execute on line 74: using PQexec
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_get_data on line 70: RESULT: NaN offset: -1; array: no [NO_PID]: ecpg_process_output on line 74: correctly got 1 tuples with 3 fields
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_execute on line 74: query: insert into nantest2 ( id , d ) values ( 5 , $1 ); with 1 parameter(s) on connection ecpg1_regression [NO_PID]: ecpg_get_data on line 74: RESULT: 4 offset: -1; array: no
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_execute on line 74: using PQexecParams [NO_PID]: ecpg_get_data on line 74: RESULT: NaN offset: -1; array: no
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_free_params on line 74: parameter 1 = NaN [NO_PID]: ecpg_get_data on line 74: RESULT: NaN offset: -1; array: no
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_process_output on line 74: OK: INSERT 0 1 [NO_PID]: ecpg_execute on line 74: query: fetch from cur1; with 0 parameter(s) on connection ecpg1_regression
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_execute on line 75: query: insert into nantest2 ( id , d ) values ( 6 , $1 ); with 1 parameter(s) on connection ecpg1_regression [NO_PID]: ecpg_execute on line 74: using PQexec
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_execute on line 75: using PQexecParams [NO_PID]: ecpg_process_output on line 74: correctly got 1 tuples with 3 fields
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_free_params on line 75: parameter 1 = NaN [NO_PID]: ecpg_get_data on line 74: RESULT: 5 offset: -1; array: no
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_process_output on line 75: OK: INSERT 0 1 [NO_PID]: ecpg_get_data on line 74: RESULT: NaN offset: -1; array: no
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_execute on line 78: query: declare cur1 cursor for select id , d , d from nantest2; with 0 parameter(s) on connection ecpg1_regression [NO_PID]: ecpg_get_data on line 74: RESULT: NaN offset: -1; array: no
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_execute on line 78: using PQexec [NO_PID]: ecpg_execute on line 74: query: fetch from cur1; with 0 parameter(s) on connection ecpg1_regression
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_process_output on line 78: OK: DECLARE CURSOR [NO_PID]: ecpg_execute on line 74: using PQexec
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_execute on line 81: query: fetch from cur1; with 0 parameter(s) on connection ecpg1_regression [NO_PID]: ecpg_process_output on line 74: correctly got 1 tuples with 3 fields
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_execute on line 81: using PQexec [NO_PID]: ecpg_get_data on line 74: RESULT: 6 offset: -1; array: no
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_process_output on line 81: correctly got 1 tuples with 3 fields [NO_PID]: ecpg_get_data on line 74: RESULT: NaN offset: -1; array: no
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_get_data on line 81: RESULT: 4 offset: -1; array: no [NO_PID]: ecpg_get_data on line 74: RESULT: NaN offset: -1; array: no
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_get_data on line 81: RESULT: NaN offset: -1; array: no [NO_PID]: ecpg_execute on line 74: query: fetch from cur1; with 0 parameter(s) on connection ecpg1_regression
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_get_data on line 81: RESULT: NaN offset: -1; array: no [NO_PID]: ecpg_execute on line 74: using PQexec
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_execute on line 81: query: fetch from cur1; with 0 parameter(s) on connection ecpg1_regression [NO_PID]: ecpg_process_output on line 74: correctly got 0 tuples with 3 fields
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_execute on line 81: using PQexec [NO_PID]: raising sqlcode 100 on line 74: no data found on line 74
[NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_process_output on line 81: correctly got 1 tuples with 3 fields
[NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_get_data on line 81: RESULT: 5 offset: -1; array: no
[NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_get_data on line 81: RESULT: NaN offset: -1; array: no
[NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_get_data on line 81: RESULT: NaN offset: -1; array: no
[NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_execute on line 81: query: fetch from cur1; with 0 parameter(s) on connection ecpg1_regression
[NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_execute on line 81: using PQexec
[NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_process_output on line 81: correctly got 1 tuples with 3 fields
[NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_get_data on line 81: RESULT: 6 offset: -1; array: no
[NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_get_data on line 81: RESULT: NaN offset: -1; array: no
[NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_get_data on line 81: RESULT: NaN offset: -1; array: no
[NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_execute on line 81: query: fetch from cur1; with 0 parameter(s) on connection ecpg1_regression
[NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_execute on line 81: using PQexec
[NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_process_output on line 81: correctly got 0 tuples with 3 fields
[NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: raising sqlcode 100 on line 81: no data found on line 81
[NO_PID]: sqlca: code: 100, state: 02000 [NO_PID]: sqlca: code: 100, state: 02000
[NO_PID]: ecpg_execute on line 86: query: close cur1; with 0 parameter(s) on connection ecpg1_regression [NO_PID]: ecpg_execute on line 79: query: close cur1; with 0 parameter(s) on connection ecpg1_regression
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_execute on line 86: using PQexec [NO_PID]: ecpg_execute on line 79: using PQexec
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_process_output on line 86: OK: CLOSE CURSOR [NO_PID]: ecpg_process_output on line 79: OK: CLOSE CURSOR
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ECPGtrans on line 90: action "rollback"; connection "ecpg1_regression" [NO_PID]: ECPGtrans on line 83: action "rollback"; connection "ecpg1_regression"
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000
[NO_PID]: ecpg_finish: connection ecpg1_regression closed [NO_PID]: ecpg_finish: connection ecpg1_regression closed
[NO_PID]: sqlca: code: 0, state: 00000 [NO_PID]: sqlca: code: 0, state: 00000

View File

@ -7,13 +7,6 @@
exec sql include ../regression; exec sql include ../regression;
#ifdef WIN32
#if (_MSC_VER < 1800)
#define isinf(x) ((_fpclass(x) == _FPCLASS_PINF) || (_fpclass(x) == _FPCLASS_NINF))
#define isnan(x) _isnan(x)
#endif
#endif /* WIN32 */
int int
main(void) main(void)
{ {

View File

@ -212,7 +212,7 @@ win32_langinfo(const char *ctype)
{ {
char *r = NULL; char *r = NULL;
#if (_MSC_VER >= 1700) && (_MSC_VER < 1900) #if defined(_MSC_VER) && (_MSC_VER < 1900)
_locale_t loct = NULL; _locale_t loct = NULL;
loct = _create_locale(LC_CTYPE, ctype); loct = _create_locale(LC_CTYPE, ctype);
@ -226,7 +226,7 @@ win32_langinfo(const char *ctype)
#else #else
char *codepage; char *codepage;
#if (_MSC_VER >= 1900) #if defined(_MSC_VER) && (_MSC_VER >= 1900)
uint32 cp; uint32 cp;
WCHAR wctype[LOCALE_NAME_MAX_LENGTH]; WCHAR wctype[LOCALE_NAME_MAX_LENGTH];

View File

@ -511,10 +511,8 @@ sub GenerateFiles
open(my $o, '>', 'src/interfaces/ecpg/include/ecpg_config.h') open(my $o, '>', 'src/interfaces/ecpg/include/ecpg_config.h')
|| confess "Could not open ecpg_config.h"; || confess "Could not open ecpg_config.h";
print $o <<EOF; print $o <<EOF;
#if (_MSC_VER > 1200)
#define HAVE_LONG_LONG_INT 1 #define HAVE_LONG_LONG_INT 1
#define HAVE_LONG_LONG_INT_64 1 #define HAVE_LONG_LONG_INT_64 1
#endif
#define ENABLE_THREAD_SAFETY 1 #define ENABLE_THREAD_SAFETY 1
EOF EOF
close($o); close($o);