Commit e4daaa73 authored by bgermann's avatar bgermann

Remove gb.db.odbc patch

[CYGPORT]
* NEW: Remove patch for gb.db.odbc as an euivalent patch is upstream now
parent 0f1c7d64
Index: gb.db.odbc/src/main.c
===================================================================
--- gb.db.odbc/src/main.c (revision 7930)
+++ gb.db.odbc/src/main.c (working copy)
@@ -54,6 +54,11 @@
#undef HAVE_UNISTD_H
#endif
+// columns in SQLColumns() RESULT SET
+#define SQLColumns_ColumnName 4
+#define SQLColumns_ColumnSize 7
+#define SQLColumns_SQL_DataType 14
+
#include "gb.db.proto.h"
#include "main.h"
@@ -1786,12 +1791,12 @@
colsNum = 0;
while (SQL_SUCCEEDED(SQLFetch(statHandle)))
{
- SQLGetData(statHandle, SQLColumns_COLUMN_NAME, SQL_C_CHAR, current->fieldname,
+ SQLGetData(statHandle, SQLColumns_ColumnName, SQL_C_CHAR, current->fieldname,
sizeof(current->fieldname), 0);
if (!SQL_SUCCEEDED
(SQLGetData
- (statHandle, SQLColumns_SQL_DATA_TYPE, SQL_C_CHAR, &coltype[0],
+ (statHandle, SQLColumns_SQL_DataType, SQL_C_CHAR, &coltype[0],
sizeof(coltype), 0)))
return TRUE;
@@ -1799,7 +1804,7 @@
if (!SQL_SUCCEEDED
(SQLGetData
- (statHandle, SQLColumns_COLUMN_SIZE, SQL_C_CHAR, precision,
+ (statHandle, SQLColumns_ColumnSize, SQL_C_CHAR, precision,
sizeof(precision), 0)))
return TRUE;
@@ -1904,7 +1909,7 @@
while (SQL_SUCCEEDED(SQLFetch(statHandle2)))
{
- if (!SQL_SUCCEEDED(SQLGetData (statHandle2, SQLColumns_COLUMN_NAME, SQL_C_CHAR, current->fieldname, sizeof(current->fieldname), 0)))
+ if (!SQL_SUCCEEDED(SQLGetData (statHandle2, SQLColumns_ColumnName, SQL_C_CHAR, current->fieldname, sizeof(current->fieldname), 0)))
strcpy((char *)current->fieldname, "Unknown");
colsNum = colsNum + 1;
@@ -2076,11 +2081,11 @@
return FALSE; //nReturn;
}
- SQLBindCol(statHandle, SQLTables_TABLE_NAME, SQL_C_CHAR, szTableName,
+ SQLBindCol(statHandle, 3, SQL_C_CHAR, szTableName,
sizeof(szTableName), &nIndicatorName);
- SQLBindCol(statHandle, SQLTables_TABLE_TYPE, SQL_C_CHAR, szTableType,
+ SQLBindCol(statHandle, 4, SQL_C_CHAR, szTableType,
sizeof(szTableType), &nIndicatorType);
- SQLBindCol(statHandle, SQLTables_REMARKS, SQL_C_CHAR, szTableRemarks,
+ SQLBindCol(statHandle, 5, SQL_C_CHAR, szTableRemarks,
sizeof(szTableRemarks), &nIndicatorRemarks);
// GET RESULTS
nReturn = SQLFetch(statHandle);
@@ -2161,11 +2166,11 @@
return nReturn;
}
- SQLBindCol(statHandle, SQLTables_TABLE_NAME, SQL_C_CHAR, szTableName,
+ SQLBindCol(statHandle, 3, SQL_C_CHAR, szTableName,
sizeof(szTableName), &nIndicatorName);
- SQLBindCol(statHandle, SQLTables_TABLE_TYPE, SQL_C_CHAR, szTableType,
+ SQLBindCol(statHandle, 4, SQL_C_CHAR, szTableType,
sizeof(szTableType), &nIndicatorType);
- SQLBindCol(statHandle, SQLTables_REMARKS, SQL_C_CHAR, szTableRemarks,
+ SQLBindCol(statHandle, 5, SQL_C_CHAR, szTableRemarks,
sizeof(szTableRemarks), &nIndicatorRemarks);
// GET RESULTS
nReturn = SQLFetch(statHandle);
@@ -2557,7 +2562,7 @@
while (SQL_SUCCEEDED(SQLFetch(statHandle)))
{
- SQLGetData(statHandle, SQLColumns_COLUMN_NAME, SQL_C_CHAR, colname,
+ SQLGetData(statHandle, SQLColumns_ColumnName, SQL_C_CHAR, colname,
sizeof(colname), 0);
//printf("field exist dopo la get data - field =%s, Colname %s\n",field,colname);
@@ -2647,7 +2652,7 @@
{
if (!SQL_SUCCEEDED
(SQLGetData
- (statHandle, SQLColumns_COLUMN_NAME, SQL_C_CHAR, current->fieldname,
+ (statHandle, SQLColumns_ColumnName, SQL_C_CHAR, current->fieldname,
sizeof(current->fieldname), 0)))
strcpy((char *)current->fieldname, "Unknown");
@@ -2760,13 +2765,13 @@
while (SQL_SUCCEEDED(SQLFetch(statHandle)))
{
- SQLGetData(statHandle, SQLColumns_COLUMN_NAME, SQL_C_CHAR, colname, sizeof(colname), 0);
+ SQLGetData(statHandle, SQLColumns_ColumnName, SQL_C_CHAR, colname, sizeof(colname), 0);
if (strcmp((char *) colname, field) == 0)
{
- SQL_SUCCEEDED(SQLGetData(statHandle, SQLColumns_SQL_DATA_TYPE, SQL_C_CHAR, coltype, sizeof(coltype), 0));
- SQL_SUCCEEDED(SQLGetData(statHandle, SQLColumns_COLUMN_SIZE, SQL_C_CHAR, precision, sizeof(precision), 0));
+ SQL_SUCCEEDED(SQLGetData(statHandle, SQLColumns_SQL_DataType, SQL_C_CHAR, coltype, sizeof(coltype), 0));
+ SQL_SUCCEEDED(SQLGetData(statHandle, SQLColumns_ColumnSize, SQL_C_CHAR, precision, sizeof(precision), 0));
break;
File mode changed from 100755 to 100644
......@@ -11,7 +11,7 @@ DEPEND="pkgconfig(libffi) pkgconfig(libpcre) pkgconfig(zlib) pkgconfig(cairo) pk
SRC_URI="mirror://sourceforge/gambas/${P}.tar.bz2"
PATCH_URI="${PN}-libpq.patch ${PN}-generic-odbc.patch"
PATCH_URI="${PN}-libpq.patch"
# Disable gb.v4l (deprecated) and gb.inotify, because they cannot be built for cygwin.
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment