diff --git a/src/interfaces/ecpg/test/expected/thread-alloc.c b/src/interfaces/ecpg/test/expected/thread-alloc.c
index 12a95df8f66..0f2979a2550 100644
--- a/src/interfaces/ecpg/test/expected/thread-alloc.c
+++ b/src/interfaces/ecpg/test/expected/thread-alloc.c
@@ -121,7 +121,7 @@ struct sqlca_t *ECPGget_sqlca(void);
#ifdef WIN32
-static unsigned STDCALL fn(void* arg)
+static unsigned __stdcall fn(void* arg)
#else
static void* fn(void* arg)
#endif
diff --git a/src/interfaces/ecpg/test/expected/thread-descriptor.c b/src/interfaces/ecpg/test/expected/thread-descriptor.c
index 4bbed8c256a..6fd0dd818bb 100644
--- a/src/interfaces/ecpg/test/expected/thread-descriptor.c
+++ b/src/interfaces/ecpg/test/expected/thread-descriptor.c
@@ -101,7 +101,7 @@ struct sqlca_t *ECPGget_sqlca(void);
#if defined(ENABLE_THREAD_SAFETY) && defined(WIN32)
-static unsigned STDCALL fn(void* arg)
+static unsigned __stdcall fn(void* arg)
#else
static void* fn(void* arg)
#endif
diff --git a/src/interfaces/ecpg/test/expected/thread-prep.c b/src/interfaces/ecpg/test/expected/thread-prep.c
index 22b63f16fce..90d9dbc4958 100644
--- a/src/interfaces/ecpg/test/expected/thread-prep.c
+++ b/src/interfaces/ecpg/test/expected/thread-prep.c
@@ -121,7 +121,7 @@ struct sqlca_t *ECPGget_sqlca(void);
#ifdef WIN32
-static unsigned STDCALL fn(void* arg)
+static unsigned __stdcall fn(void* arg)
#else
static void* fn(void* arg)
#endif
diff --git a/src/interfaces/ecpg/test/thread/alloc.pgc b/src/interfaces/ecpg/test/thread/alloc.pgc
index d4850dcd884..9c56c070c53 100644
--- a/src/interfaces/ecpg/test/thread/alloc.pgc
+++ b/src/interfaces/ecpg/test/thread/alloc.pgc
@@ -28,7 +28,7 @@ exec sql whenever sqlerror sqlprint;
exec sql whenever not found sqlprint;
#ifdef WIN32
-static unsigned STDCALL fn(void* arg)
+static unsigned __stdcall fn(void* arg)
#else
static void* fn(void* arg)
#endif
diff --git a/src/interfaces/ecpg/test/thread/descriptor.pgc b/src/interfaces/ecpg/test/thread/descriptor.pgc
index 7f7b4a1d0b9..9560d105b6a 100644
--- a/src/interfaces/ecpg/test/thread/descriptor.pgc
+++ b/src/interfaces/ecpg/test/thread/descriptor.pgc
@@ -17,7 +17,7 @@ EXEC SQL whenever sqlerror sqlprint;
EXEC SQL whenever not found sqlprint;
#if defined(ENABLE_THREAD_SAFETY) && defined(WIN32)
-static unsigned STDCALL fn(void* arg)
+static unsigned __stdcall fn(void* arg)
#else
static void* fn(void* arg)
#endif
diff --git a/src/interfaces/ecpg/test/thread/prep.pgc b/src/interfaces/ecpg/test/thread/prep.pgc
index 314e24eecd2..0e822bb3598 100644
--- a/src/interfaces/ecpg/test/thread/prep.pgc
+++ b/src/interfaces/ecpg/test/thread/prep.pgc
@@ -28,7 +28,7 @@ exec sql whenever sqlerror sqlprint;
exec sql whenever not found sqlprint;
#ifdef WIN32
-static unsigned STDCALL fn(void* arg)
+static unsigned __stdcall fn(void* arg)
#else
static void* fn(void* arg)
#endif
diff --git a/src/tools/msvc/ecpg_regression.proj b/src/tools/msvc/ecpg_regression.proj
index a026c5433c4..cccd6bce2ed 100644
--- a/src/tools/msvc/ecpg_regression.proj
+++ b/src/tools/msvc/ecpg_regression.proj
@@ -33,9 +33,12 @@
+
+
+
-
+