2010-01-14 23:46 UTC+0100 Viktor Szakats (harbour.01 syenar.hu)
* contrib/rddsql/sddmy/mysqldd.c
* contrib/rddsql/sddpg/pgsqldd.c
* contrib/rddsql/sddfb/fbirddd.c
* contrib/rddsql/sddodbc/odbcdd.c
* contrib/rddsql/hbrddsql.h
* contrib/rddsql/sqlbase.c
* contrib/rddsql/sqlmix.c
* BOOL -> HB_BOOL
* TRUE -> HB_TRUE
* FALSE -> HB_FALSE
This commit is contained in:
@@ -17,6 +17,18 @@
|
||||
past entries belonging to author(s): Viktor Szakats.
|
||||
*/
|
||||
|
||||
2010-01-14 23:46 UTC+0100 Viktor Szakats (harbour.01 syenar.hu)
|
||||
* contrib/rddsql/sddmy/mysqldd.c
|
||||
* contrib/rddsql/sddpg/pgsqldd.c
|
||||
* contrib/rddsql/sddfb/fbirddd.c
|
||||
* contrib/rddsql/sddodbc/odbcdd.c
|
||||
* contrib/rddsql/hbrddsql.h
|
||||
* contrib/rddsql/sqlbase.c
|
||||
* contrib/rddsql/sqlmix.c
|
||||
* BOOL -> HB_BOOL
|
||||
* TRUE -> HB_TRUE
|
||||
* FALSE -> HB_FALSE
|
||||
|
||||
2010-01-14 23:35 UTC+0100 Viktor Szakats (harbour.01 syenar.hu)
|
||||
* contrib/rddads/adsx.c
|
||||
* contrib/rddads/adsfunc.c
|
||||
|
||||
@@ -108,10 +108,10 @@ typedef struct _SQLBASEAREA
|
||||
void * pNatRecord;
|
||||
void * pNatLength;
|
||||
|
||||
BOOL fFetched;
|
||||
BOOL fPositioned;
|
||||
BOOL fAppend;
|
||||
BOOL fRecordChanged;
|
||||
HB_BOOL fFetched;
|
||||
HB_BOOL fPositioned;
|
||||
HB_BOOL fAppend;
|
||||
HB_BOOL fRecordChanged;
|
||||
} SQLBASEAREA, * SQLBASEAREAP;
|
||||
|
||||
|
||||
@@ -176,9 +176,9 @@ typedef struct _MIXTAG
|
||||
unsigned int uiKeyLen; /* Length of key */
|
||||
unsigned int uiTotalLen; /* Total length of key structure */
|
||||
|
||||
BOOL fEof;
|
||||
BOOL fBof;
|
||||
BOOL fCustom;
|
||||
HB_BOOL fEof;
|
||||
HB_BOOL fBof;
|
||||
HB_BOOL fCustom;
|
||||
|
||||
PMIXNODE Root;
|
||||
|
||||
@@ -187,7 +187,7 @@ typedef struct _MIXTAG
|
||||
unsigned int CurPos;
|
||||
|
||||
PMIXKEY HotKey;
|
||||
BOOL HotFor;
|
||||
HB_BOOL HotFor;
|
||||
|
||||
PHB_CODEPAGE pCodepage; /* National sorttable for character key tags, NULL otherwise */
|
||||
} MIXTAG, * PMIXTAG;
|
||||
|
||||
@@ -200,7 +200,7 @@ static HB_ERRCODE fbOpen( SQLBASEAREAP pArea )
|
||||
XSQLVAR* pVar;
|
||||
PHB_ITEM pItemEof, pItem;
|
||||
DBFIELDINFO pFieldInfo;
|
||||
BOOL bError;
|
||||
HB_BOOL bError;
|
||||
char* pBuffer;
|
||||
USHORT uiFields, uiCount;
|
||||
int iType;
|
||||
@@ -257,7 +257,7 @@ static HB_ERRCODE fbOpen( SQLBASEAREAP pArea )
|
||||
|
||||
pBuffer = ( char * ) hb_xgrab( 256 );
|
||||
|
||||
bError = FALSE;
|
||||
bError = HB_FALSE;
|
||||
for ( uiCount = 0, pVar = pSqlda->sqlvar; uiCount < uiFields; uiCount++, pVar++ )
|
||||
{
|
||||
memcpy( pBuffer, pVar->sqlname, pVar->sqlname_length );
|
||||
@@ -362,7 +362,7 @@ static HB_ERRCODE fbOpen( SQLBASEAREAP pArea )
|
||||
|
||||
default:
|
||||
pItem = hb_itemNew( NULL );
|
||||
bError = TRUE;
|
||||
bError = HB_TRUE;
|
||||
break;
|
||||
}
|
||||
|
||||
@@ -516,7 +516,7 @@ static HB_ERRCODE fbGoTo( SQLBASEAREAP pArea, ULONG ulRecNo )
|
||||
}
|
||||
else if ( lErr == 100L )
|
||||
{
|
||||
pArea->fFetched = TRUE;
|
||||
pArea->fFetched = HB_TRUE;
|
||||
if ( isc_dsql_free_statement( status, &stmt, DSQL_drop ) )
|
||||
{
|
||||
hb_errRT_FireBirdDD( EG_OPEN, ESQLDD_STMTFREE, "Statement free error", NULL, ( HB_ERRCODE ) status[ 1 ] );
|
||||
@@ -546,13 +546,13 @@ static HB_ERRCODE fbGoTo( SQLBASEAREAP pArea, ULONG ulRecNo )
|
||||
{
|
||||
pArea->pRecord = pArea->pRow[ 0 ];
|
||||
pArea->bRecordFlags = pArea->pRowFlags[ 0 ];
|
||||
pArea->fPositioned = FALSE;
|
||||
pArea->fPositioned = HB_FALSE;
|
||||
}
|
||||
else
|
||||
{
|
||||
pArea->pRecord = pArea->pRow[ ulRecNo ];
|
||||
pArea->bRecordFlags = pArea->pRowFlags[ ulRecNo ];
|
||||
pArea->fPositioned = TRUE;
|
||||
pArea->fPositioned = HB_TRUE;
|
||||
}
|
||||
return HB_SUCCESS;
|
||||
}
|
||||
|
||||
@@ -216,7 +216,7 @@ static HB_ERRCODE mysqlOpen( SQLBASEAREAP pArea )
|
||||
ULONG ulIndex;
|
||||
USHORT uiFields, uiCount;
|
||||
HB_ERRCODE errCode = 0;
|
||||
BOOL bError;
|
||||
HB_BOOL bError;
|
||||
char * pBuffer;
|
||||
DBFIELDINFO pFieldInfo;
|
||||
MYSQL_FIELD * pMyField;
|
||||
@@ -243,7 +243,7 @@ static HB_ERRCODE mysqlOpen( SQLBASEAREAP pArea )
|
||||
|
||||
pBuffer = ( char * ) hb_xgrab( 256 );
|
||||
|
||||
bError = FALSE;
|
||||
bError = HB_FALSE;
|
||||
for ( uiCount = 0; uiCount < uiFields; uiCount++ )
|
||||
{
|
||||
pMyField = mysql_fetch_field_direct( ( MYSQL_RES * ) pArea->pResult, uiCount );
|
||||
@@ -313,7 +313,7 @@ static HB_ERRCODE mysqlOpen( SQLBASEAREAP pArea )
|
||||
*/
|
||||
|
||||
default:
|
||||
bError = TRUE;
|
||||
bError = HB_TRUE;
|
||||
errCode = ( HB_ERRCODE ) pMyField->type;
|
||||
pFieldInfo.uiType = 0;
|
||||
break;
|
||||
@@ -363,7 +363,7 @@ static HB_ERRCODE mysqlOpen( SQLBASEAREAP pArea )
|
||||
|
||||
default:
|
||||
pItem = hb_itemNew( NULL );
|
||||
bError = TRUE;
|
||||
bError = HB_TRUE;
|
||||
break;
|
||||
}
|
||||
|
||||
@@ -434,7 +434,7 @@ static HB_ERRCODE mysqlGoTo( SQLBASEAREAP pArea, ULONG ulRecNo )
|
||||
pArea->pRecord = pArea->pRow[ 0 ];
|
||||
pArea->bRecordFlags = pArea->pRowFlags[ 0 ];
|
||||
|
||||
pArea->fPositioned = FALSE;
|
||||
pArea->fPositioned = HB_FALSE;
|
||||
}
|
||||
else
|
||||
{
|
||||
@@ -448,7 +448,7 @@ static HB_ERRCODE mysqlGoTo( SQLBASEAREAP pArea, ULONG ulRecNo )
|
||||
pArea->pNatLength = ( void * ) mysql_fetch_lengths( ( MYSQL_RES * ) pArea->pResult );
|
||||
}
|
||||
|
||||
pArea->fPositioned = TRUE;
|
||||
pArea->fPositioned = HB_TRUE;
|
||||
}
|
||||
return HB_SUCCESS;
|
||||
}
|
||||
@@ -459,11 +459,11 @@ static HB_ERRCODE mysqlGetValue( SQLBASEAREAP pArea, USHORT uiIndex, PHB_ITEM pI
|
||||
LPFIELD pField;
|
||||
char* pValue;
|
||||
char szBuffer[ 64 ];
|
||||
BOOL bError;
|
||||
HB_BOOL bError;
|
||||
PHB_ITEM pError;
|
||||
ULONG ulLen;
|
||||
|
||||
bError = FALSE;
|
||||
bError = HB_FALSE;
|
||||
uiIndex--;
|
||||
pField = pArea->area.lpFields + uiIndex;
|
||||
|
||||
@@ -606,7 +606,7 @@ static HB_ERRCODE mysqlGetValue( SQLBASEAREAP pArea, USHORT uiIndex, PHB_ITEM pI
|
||||
}
|
||||
|
||||
default:
|
||||
bError = TRUE;
|
||||
bError = HB_TRUE;
|
||||
break;
|
||||
}
|
||||
|
||||
|
||||
@@ -155,11 +155,11 @@ static char * odbcGetError( SQLHENV hEnv, SQLHDBC hConn, SQLHSTMT hStmt, HB_ERRC
|
||||
SQLINTEGER iNativeErr = 9999;
|
||||
SQLSMALLINT iLen;
|
||||
char * szRet;
|
||||
|
||||
|
||||
if( SQL_SUCCEEDED( SQLError( hEnv, hConn, hStmt, szError, &iNativeErr, szError + 6, SQL_MAX_MESSAGE_LENGTH, &iLen ) ) )
|
||||
{
|
||||
char * szStr;
|
||||
|
||||
|
||||
szError[ 5 ] = ' ';
|
||||
szStr = HB_TCHAR_CONVFROM( szError );
|
||||
szRet = hb_strdup( szStr );
|
||||
@@ -182,7 +182,7 @@ static HB_ERRCODE odbcConnect( SQLDDCONNECTION * pConnection, PHB_ITEM pItem )
|
||||
SQLHDBC hConnect = NULL;
|
||||
char * szError;
|
||||
HB_ERRCODE errCode;
|
||||
|
||||
|
||||
if( SQL_SUCCEEDED( SQLAllocHandle( SQL_HANDLE_ENV, SQL_NULL_HANDLE, &hEnv ) ) )
|
||||
{
|
||||
SQLSetEnvAttr( hEnv, SQL_ATTR_ODBC_VERSION, ( SQLPOINTER ) SQL_OV_ODBC3, SQL_IS_UINTEGER );
|
||||
@@ -295,7 +295,7 @@ static HB_ERRCODE odbcOpen( SQLBASEAREAP pArea )
|
||||
SQLULEN uiSize;
|
||||
PHB_ITEM pItemEof, pItem;
|
||||
DBFIELDINFO pFieldInfo;
|
||||
BOOL bError;
|
||||
HB_BOOL bError;
|
||||
USHORT uiFields, uiIndex;
|
||||
HB_ERRCODE errCode;
|
||||
char * szError;
|
||||
@@ -339,7 +339,7 @@ static HB_ERRCODE odbcOpen( SQLBASEAREAP pArea )
|
||||
/* HB_TRACE( HB_TR_ALWAYS, ("fieldcount=%d", iNameLen) ); */
|
||||
|
||||
errCode = 0;
|
||||
bError = FALSE;
|
||||
bError = HB_FALSE;
|
||||
for ( uiIndex = 0; uiIndex < uiFields; uiIndex++ )
|
||||
{
|
||||
if ( ! SQL_SUCCEEDED( SQLDescribeCol( hStmt, ( SQLSMALLINT ) uiIndex + 1, ( SQLTCHAR* ) cName, HB_SIZEOFARRAY( cName ), &iNameLen, &iDataType, &uiSize, &iDec, &iNull ) ) )
|
||||
@@ -410,7 +410,7 @@ static HB_ERRCODE odbcOpen( SQLBASEAREAP pArea )
|
||||
|
||||
default:
|
||||
/* HB_TRACE( HB_TR_ALWAYS, ("new sql type=%d", iDataType) ); */
|
||||
bError = TRUE;
|
||||
bError = HB_TRUE;
|
||||
errCode = ( HB_ERRCODE ) iDataType;
|
||||
pFieldInfo.uiType = 0;
|
||||
pFieldInfo.uiType = HB_FT_STRING;
|
||||
@@ -454,7 +454,7 @@ static HB_ERRCODE odbcOpen( SQLBASEAREAP pArea )
|
||||
break;
|
||||
|
||||
case HB_FT_LOGICAL:
|
||||
pItem = hb_itemPutL( NULL, FALSE );
|
||||
pItem = hb_itemPutL( NULL, HB_FALSE );
|
||||
break;
|
||||
|
||||
case HB_FT_DATE:
|
||||
@@ -471,7 +471,7 @@ static HB_ERRCODE odbcOpen( SQLBASEAREAP pArea )
|
||||
|
||||
default:
|
||||
pItem = hb_itemNew( NULL );
|
||||
bError = TRUE;
|
||||
bError = HB_TRUE;
|
||||
break;
|
||||
}
|
||||
|
||||
@@ -534,7 +534,7 @@ static HB_ERRCODE odbcGoTo( SQLBASEAREAP pArea, ULONG ulRecNo )
|
||||
{
|
||||
if( ! SQL_SUCCEEDED( SQLFetch( hStmt ) ) )
|
||||
{
|
||||
pArea->fFetched = TRUE;
|
||||
pArea->fFetched = HB_TRUE;
|
||||
break;
|
||||
}
|
||||
|
||||
@@ -676,13 +676,13 @@ static HB_ERRCODE odbcGoTo( SQLBASEAREAP pArea, ULONG ulRecNo )
|
||||
{
|
||||
pArea->pRecord = pArea->pRow[ 0 ];
|
||||
pArea->bRecordFlags = pArea->pRowFlags[ 0 ];
|
||||
pArea->fPositioned = FALSE;
|
||||
pArea->fPositioned = HB_FALSE;
|
||||
}
|
||||
else
|
||||
{
|
||||
pArea->pRecord = pArea->pRow[ ulRecNo ];
|
||||
pArea->bRecordFlags = pArea->pRowFlags[ ulRecNo ];
|
||||
pArea->fPositioned = TRUE;
|
||||
pArea->fPositioned = HB_TRUE;
|
||||
}
|
||||
return HB_SUCCESS;
|
||||
}
|
||||
|
||||
@@ -236,7 +236,7 @@ static HB_ERRCODE pgsqlOpen( SQLBASEAREAP pArea )
|
||||
ExecStatusType status;
|
||||
PHB_ITEM pItemEof, pItem;
|
||||
USHORT uiFields, uiCount;
|
||||
BOOL bError;
|
||||
HB_BOOL bError;
|
||||
char* pBuffer;
|
||||
DBFIELDINFO pFieldInfo;
|
||||
|
||||
@@ -264,7 +264,7 @@ static HB_ERRCODE pgsqlOpen( SQLBASEAREAP pArea )
|
||||
|
||||
pBuffer = ( char* ) hb_xgrab( 256 );
|
||||
|
||||
bError = FALSE;
|
||||
bError = HB_FALSE;
|
||||
for ( uiCount = 0; uiCount < uiFields; uiCount++ )
|
||||
{
|
||||
hb_strncpy( pBuffer, PQfname( pResult, ( int ) uiCount ), 256 - 1 );
|
||||
@@ -370,7 +370,7 @@ static HB_ERRCODE pgsqlOpen( SQLBASEAREAP pArea )
|
||||
default:
|
||||
pFieldInfo.uiType = 0;
|
||||
pFieldInfo.uiLen = 0;
|
||||
bError = TRUE;
|
||||
bError = HB_TRUE;
|
||||
break;
|
||||
}
|
||||
/* printf( "field:%s \ttype:%d \tsize:%d \tformat:%d \tmod:%d err=%d\n", pBuffer, PQftype( pResult, ( int ) uiCount ), PQfsize( pResult, uiCount ), PQfformat( pResult, uiCount ) , PQfmod( pResult, uiCount ), bError ); */
|
||||
@@ -405,7 +405,7 @@ static HB_ERRCODE pgsqlOpen( SQLBASEAREAP pArea )
|
||||
break;
|
||||
|
||||
case HB_FT_LOGICAL:
|
||||
pItem = hb_itemPutL( NULL, FALSE );
|
||||
pItem = hb_itemPutL( NULL, HB_FALSE );
|
||||
break;
|
||||
|
||||
case HB_FT_DATE:
|
||||
@@ -414,7 +414,7 @@ static HB_ERRCODE pgsqlOpen( SQLBASEAREAP pArea )
|
||||
|
||||
default:
|
||||
pItem = hb_itemNew( NULL );
|
||||
bError = TRUE;
|
||||
bError = HB_TRUE;
|
||||
break;
|
||||
}
|
||||
|
||||
@@ -473,11 +473,11 @@ static HB_ERRCODE pgsqlGetValue( SQLBASEAREAP pArea, USHORT uiIndex, PHB_ITEM pI
|
||||
{
|
||||
LPFIELD pField;
|
||||
char* pValue;
|
||||
BOOL bError;
|
||||
HB_BOOL bError;
|
||||
PHB_ITEM pError;
|
||||
ULONG ulLen;
|
||||
|
||||
bError = FALSE;
|
||||
bError = HB_FALSE;
|
||||
uiIndex--;
|
||||
pField = pArea->area.lpFields + uiIndex;
|
||||
|
||||
@@ -533,7 +533,7 @@ static HB_ERRCODE pgsqlGetValue( SQLBASEAREAP pArea, USHORT uiIndex, PHB_ITEM pI
|
||||
}
|
||||
|
||||
default:
|
||||
bError = TRUE;
|
||||
bError = HB_TRUE;
|
||||
break;
|
||||
}
|
||||
|
||||
|
||||
@@ -193,14 +193,14 @@ static HB_ERRCODE sddGoTo( SQLBASEAREAP pArea, ULONG ulRecNo )
|
||||
pArea->pRecord = pArea->pRow[ 0 ];
|
||||
pArea->bRecordFlags = pArea->pRowFlags[ 0 ];
|
||||
|
||||
pArea->fPositioned = FALSE;
|
||||
pArea->fPositioned = HB_FALSE;
|
||||
}
|
||||
else
|
||||
{
|
||||
pArea->pRecord = pArea->pRow[ ulRecNo ];
|
||||
pArea->bRecordFlags = pArea->pRowFlags[ ulRecNo ];
|
||||
|
||||
pArea->fPositioned = TRUE;
|
||||
pArea->fPositioned = HB_TRUE;
|
||||
}
|
||||
return HB_SUCCESS;
|
||||
}
|
||||
@@ -276,8 +276,8 @@ static HB_ERRCODE sqlbaseGoBottom( SQLBASEAREAP pArea )
|
||||
if ( ! pArea->fFetched && pArea->pSDD->GoTo( pArea, ( ULONG ) -1 ) == HB_FAILURE )
|
||||
return HB_FAILURE;
|
||||
|
||||
pArea->area.fTop = FALSE;
|
||||
pArea->area.fBottom = TRUE;
|
||||
pArea->area.fTop = HB_FALSE;
|
||||
pArea->area.fBottom = HB_TRUE;
|
||||
|
||||
if ( SELF_GOTO( ( AREAP ) pArea, pArea->ulRecCount ) != HB_SUCCESS )
|
||||
return HB_FAILURE;
|
||||
@@ -297,14 +297,14 @@ static HB_ERRCODE sqlbaseGoTo( SQLBASEAREAP pArea, ULONG ulRecNo )
|
||||
if ( pArea->fPositioned )
|
||||
{
|
||||
pArea->ulRecNo = ulRecNo;
|
||||
pArea->area.fBof = pArea->area.fEof = FALSE;
|
||||
pArea->area.fBof = pArea->area.fEof = HB_FALSE;
|
||||
}
|
||||
else
|
||||
{
|
||||
pArea->ulRecNo = pArea->ulRecCount + 1;
|
||||
pArea->area.fBof = pArea->area.fEof = TRUE;
|
||||
pArea->area.fBof = pArea->area.fEof = HB_TRUE;
|
||||
}
|
||||
pArea->area.fFound = FALSE;
|
||||
pArea->area.fFound = HB_FALSE;
|
||||
|
||||
return HB_SUCCESS;
|
||||
}
|
||||
@@ -331,8 +331,8 @@ static HB_ERRCODE sqlbaseGoToId( SQLBASEAREAP pArea, PHB_ITEM pItem )
|
||||
|
||||
static HB_ERRCODE sqlbaseGoTop( SQLBASEAREAP pArea )
|
||||
{
|
||||
pArea->area.fTop = TRUE;
|
||||
pArea->area.fBottom = FALSE;
|
||||
pArea->area.fTop = HB_TRUE;
|
||||
pArea->area.fBottom = HB_FALSE;
|
||||
|
||||
if ( SELF_GOTO( ( AREAP ) pArea, 1 ) == HB_FAILURE )
|
||||
return HB_FAILURE;
|
||||
@@ -351,7 +351,7 @@ static HB_ERRCODE sqlbaseSkip( SQLBASEAREAP pArea, LONG lToSkip )
|
||||
return HB_FAILURE;
|
||||
}
|
||||
|
||||
pArea->area.fTop = pArea->area.fBottom = FALSE;
|
||||
pArea->area.fTop = pArea->area.fBottom = HB_FALSE;
|
||||
|
||||
if ( lToSkip == 0 || hb_setGetDeleted() ||
|
||||
pArea->area.dbfi.itmCobExpr || pArea->area.dbfi.fFilter )
|
||||
@@ -363,13 +363,13 @@ static HB_ERRCODE sqlbaseSkip( SQLBASEAREAP pArea, LONG lToSkip )
|
||||
if ( errCode == HB_SUCCESS && pArea->area.fBof && lToSkip < 0 )
|
||||
{
|
||||
errCode = SELF_GOTOP( ( AREAP ) pArea );
|
||||
pArea->area.fBof = TRUE;
|
||||
pArea->area.fBof = HB_TRUE;
|
||||
}
|
||||
|
||||
if ( lToSkip < 0 )
|
||||
pArea->area.fEof = FALSE;
|
||||
pArea->area.fEof = HB_FALSE;
|
||||
else /* if ( lToSkip > 0 ) */
|
||||
pArea->area.fBof = FALSE;
|
||||
pArea->area.fBof = HB_FALSE;
|
||||
|
||||
return errCode;
|
||||
}
|
||||
@@ -388,7 +388,7 @@ static HB_ERRCODE sqlbaseSkipRaw( SQLBASEAREAP pArea, LONG lToSkip )
|
||||
if ( lToSkip == 0 )
|
||||
{
|
||||
/* TODO: maybe gocold is enough here?! */
|
||||
BOOL bBof, bEof;
|
||||
HB_BOOL bBof, bEof;
|
||||
|
||||
/* Save flags */
|
||||
bBof = pArea->area.fBof;
|
||||
@@ -403,7 +403,7 @@ static HB_ERRCODE sqlbaseSkipRaw( SQLBASEAREAP pArea, LONG lToSkip )
|
||||
else if ( lToSkip < 0 && ( ULONG ) ( -lToSkip ) >= pArea->ulRecNo )
|
||||
{
|
||||
errCode = SELF_GOTO( ( AREAP ) pArea, 1 );
|
||||
pArea->area.fBof = TRUE;
|
||||
pArea->area.fBof = HB_TRUE;
|
||||
}
|
||||
else
|
||||
{
|
||||
@@ -414,7 +414,7 @@ static HB_ERRCODE sqlbaseSkipRaw( SQLBASEAREAP pArea, LONG lToSkip )
|
||||
}
|
||||
|
||||
|
||||
static HB_ERRCODE sqlbaseAppend( SQLBASEAREAP pArea, BOOL bUnLockAll )
|
||||
static HB_ERRCODE sqlbaseAppend( SQLBASEAREAP pArea, HB_BOOL bUnLockAll )
|
||||
{
|
||||
HB_SYMBOL_UNUSED( bUnLockAll );
|
||||
|
||||
@@ -432,10 +432,10 @@ static HB_ERRCODE sqlbaseAppend( SQLBASEAREAP pArea, BOOL bUnLockAll )
|
||||
pArea->ulRecMax += SQLDD_ROWSET_RESIZE;
|
||||
}
|
||||
|
||||
pArea->fAppend = pArea->fPositioned = TRUE;
|
||||
pArea->fAppend = pArea->fPositioned = HB_TRUE;
|
||||
pArea->ulRecCount++;
|
||||
pArea->ulRecNo = pArea->ulRecCount;
|
||||
pArea->area.fBof = pArea->area.fEof = pArea->area.fFound = FALSE;
|
||||
pArea->area.fBof = pArea->area.fEof = pArea->area.fFound = HB_FALSE;
|
||||
return HB_SUCCESS;
|
||||
}
|
||||
|
||||
@@ -453,7 +453,7 @@ static HB_ERRCODE sqlbaseDeleteRec( SQLBASEAREAP pArea )
|
||||
}
|
||||
|
||||
|
||||
static HB_ERRCODE sqlbaseDeleted( SQLBASEAREAP pArea, BOOL* pDeleted )
|
||||
static HB_ERRCODE sqlbaseDeleted( SQLBASEAREAP pArea, HB_BOOL* pDeleted )
|
||||
{
|
||||
* pDeleted = pArea->bRecordFlags & SQLDD_FLAG_DELETED;
|
||||
return HB_SUCCESS;
|
||||
@@ -495,8 +495,8 @@ static HB_ERRCODE sqlbaseGoCold( SQLBASEAREAP pArea )
|
||||
}
|
||||
pArea->pRow[ pArea->ulRecNo ] = pArea->pRecord;
|
||||
pArea->pRowFlags[ pArea->ulRecNo ] = pArea->bRecordFlags;
|
||||
pArea->fRecordChanged = FALSE;
|
||||
pArea->fAppend = FALSE;
|
||||
pArea->fRecordChanged = HB_FALSE;
|
||||
pArea->fAppend = HB_FALSE;
|
||||
}
|
||||
return HB_SUCCESS;
|
||||
}
|
||||
@@ -517,7 +517,7 @@ static HB_ERRCODE sqlbaseGoHot( SQLBASEAREAP pArea )
|
||||
}
|
||||
pArea->pRecord = pArray;
|
||||
pArea->bRecordFlags |= SQLDD_FLAG_CACHED;
|
||||
pArea->fRecordChanged = TRUE;
|
||||
pArea->fRecordChanged = HB_TRUE;
|
||||
return HB_SUCCESS;
|
||||
}
|
||||
|
||||
@@ -644,7 +644,7 @@ static HB_ERRCODE sqlbaseCreate( SQLBASEAREAP pArea, LPDBOPENINFO pOpenInfo )
|
||||
{
|
||||
PHB_ITEM pItemEof, pItem;
|
||||
USHORT uiCount;
|
||||
BOOL bError;
|
||||
HB_BOOL bError;
|
||||
|
||||
pArea->ulConnection = pOpenInfo->ulConnection ? pOpenInfo->ulConnection : s_ulConnectionCurrent;
|
||||
|
||||
@@ -668,7 +668,7 @@ static HB_ERRCODE sqlbaseCreate( SQLBASEAREAP pArea, LPDBOPENINFO pOpenInfo )
|
||||
|
||||
pItemEof = hb_itemArrayNew( pArea->area.uiFieldCount );
|
||||
|
||||
bError = FALSE;
|
||||
bError = HB_FALSE;
|
||||
for ( uiCount = 0; uiCount < pArea->area.uiFieldCount; uiCount++ )
|
||||
{
|
||||
LPFIELD pField = pArea->area.lpFields + uiCount;
|
||||
@@ -719,12 +719,12 @@ static HB_ERRCODE sqlbaseCreate( SQLBASEAREAP pArea, LPDBOPENINFO pOpenInfo )
|
||||
break;
|
||||
|
||||
case HB_FT_LOGICAL:
|
||||
pItem = hb_itemPutL( NULL, FALSE );
|
||||
pItem = hb_itemPutL( NULL, HB_FALSE );
|
||||
break;
|
||||
|
||||
default:
|
||||
pItem = hb_itemNew( NULL );
|
||||
bError = TRUE;
|
||||
bError = HB_TRUE;
|
||||
break;
|
||||
}
|
||||
|
||||
@@ -955,7 +955,7 @@ static HB_ERRCODE sqlbaseRddInfo( LPRDDNODE pRDD, USHORT uiIndex, ULONG ulConnec
|
||||
{
|
||||
|
||||
case RDDI_REMOTE:
|
||||
hb_itemPutL( pItem, TRUE );
|
||||
hb_itemPutL( pItem, HB_TRUE );
|
||||
break;
|
||||
|
||||
case RDDI_CONNECTION:
|
||||
@@ -975,11 +975,11 @@ static HB_ERRCODE sqlbaseRddInfo( LPRDDNODE pRDD, USHORT uiIndex, ULONG ulConnec
|
||||
}
|
||||
|
||||
case RDDI_ISDBF:
|
||||
hb_itemPutL( pItem, FALSE );
|
||||
hb_itemPutL( pItem, HB_FALSE );
|
||||
break;
|
||||
|
||||
case RDDI_CANPUTREC:
|
||||
hb_itemPutL( pItem, TRUE );
|
||||
hb_itemPutL( pItem, HB_TRUE );
|
||||
break;
|
||||
|
||||
|
||||
@@ -1044,10 +1044,10 @@ static HB_ERRCODE sqlbaseRddInfo( LPRDDNODE pRDD, USHORT uiIndex, ULONG ulConnec
|
||||
if ( pConn && ! pConn->uiAreaCount && pConn->pSDD->Disconnect( pConn ) == HB_SUCCESS )
|
||||
{
|
||||
pConn->hConnection = 0;
|
||||
hb_itemPutL( pItem, TRUE );
|
||||
hb_itemPutL( pItem, HB_TRUE );
|
||||
return HB_SUCCESS;
|
||||
}
|
||||
hb_itemPutL( pItem, FALSE );
|
||||
hb_itemPutL( pItem, HB_FALSE );
|
||||
return HB_SUCCESS;
|
||||
}
|
||||
|
||||
@@ -1059,7 +1059,7 @@ static HB_ERRCODE sqlbaseRddInfo( LPRDDNODE pRDD, USHORT uiIndex, ULONG ulConnec
|
||||
hb_itemPutL( pItem, pConn->pSDD->Execute( pConn, pItem ) == HB_SUCCESS );
|
||||
}
|
||||
else
|
||||
hb_itemPutL( pItem, FALSE );
|
||||
hb_itemPutL( pItem, HB_FALSE );
|
||||
|
||||
return HB_SUCCESS;
|
||||
}
|
||||
|
||||
@@ -219,10 +219,10 @@ static PMIXKEY hb_mixKeyEval( PMIXKEY pKey, PMIXTAG pTag )
|
||||
}
|
||||
|
||||
|
||||
static BOOL hb_mixEvalCond( SQLMIXAREAP pArea, PHB_ITEM pCondItem )
|
||||
static HB_BOOL hb_mixEvalCond( SQLMIXAREAP pArea, PHB_ITEM pCondItem )
|
||||
{
|
||||
int iCurrArea = 0;
|
||||
BOOL fRet;
|
||||
HB_BOOL fRet;
|
||||
|
||||
if ( pArea )
|
||||
{
|
||||
@@ -350,7 +350,7 @@ static void hb_mixTagPrintNode( PMIXTAG pTag, PMIXNODE pNode, int iLevel )
|
||||
}
|
||||
*/
|
||||
|
||||
static PMIXNODE hb_mixTagCreateNode( PMIXTAG pTag, BOOL fLeaf )
|
||||
static PMIXNODE hb_mixTagCreateNode( PMIXTAG pTag, HB_BOOL fLeaf )
|
||||
{
|
||||
PMIXNODE pNode;
|
||||
ULONG ulSize;
|
||||
@@ -380,7 +380,7 @@ static unsigned int hb_mixTagNodeParentIndex( PMIXNODE pNode )
|
||||
}
|
||||
|
||||
|
||||
static int hb_mixTagFindKey( PMIXTAG pTag, PMIXKEY pKey, unsigned int uiLen, PMIXNODE* ppNode, unsigned int* puiPos, BOOL fValidKey )
|
||||
static int hb_mixTagFindKey( PMIXTAG pTag, PMIXKEY pKey, unsigned int uiLen, PMIXNODE* ppNode, unsigned int* puiPos, HB_BOOL fValidKey )
|
||||
{
|
||||
PMIXNODE pNode;
|
||||
unsigned int ui;
|
||||
@@ -446,16 +446,16 @@ static void hb_mixTagSetCurrent( PMIXTAG pTag, PMIXNODE pNode, unsigned int uiPo
|
||||
pTag->CurNode = pNode;
|
||||
pTag->CurPos = uiPos;
|
||||
pTag->CurKey = MIX_KEY( pTag, pNode, uiPos );
|
||||
pTag->fEof = FALSE;
|
||||
pTag->fEof = HB_FALSE;
|
||||
}
|
||||
else
|
||||
{
|
||||
pTag->fEof = TRUE;
|
||||
pTag->fEof = HB_TRUE;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
static BOOL hb_mixTagRefreshKey( PMIXTAG pTag )
|
||||
static HB_BOOL hb_mixTagRefreshKey( PMIXTAG pTag )
|
||||
{
|
||||
SQLMIXAREAP pArea;
|
||||
|
||||
@@ -466,8 +466,8 @@ static BOOL hb_mixTagRefreshKey( PMIXTAG pTag )
|
||||
|
||||
if ( ! pArea->sqlarea.fPositioned )
|
||||
{
|
||||
pTag->fEof = TRUE;
|
||||
return FALSE;
|
||||
pTag->fEof = HB_TRUE;
|
||||
return HB_FALSE;
|
||||
}
|
||||
else if ( pTag->fEof || pTag->CurKey->rec != pArea->sqlarea.ulRecNo )
|
||||
{
|
||||
@@ -477,14 +477,14 @@ static BOOL hb_mixTagRefreshKey( PMIXTAG pTag )
|
||||
|
||||
pKey = hb_mixKeyEval( NULL, pTag );
|
||||
|
||||
hb_mixTagFindKey( pTag, pKey, pTag->uiKeyLen, &pNode, &ui, FALSE );
|
||||
hb_mixTagFindKey( pTag, pKey, pTag->uiKeyLen, &pNode, &ui, HB_FALSE );
|
||||
hb_mixTagSetCurrent( pTag, pNode, ui );
|
||||
|
||||
hb_mixKeyFree( pKey );
|
||||
return ! pTag->fEof && pTag->CurKey->rec == pArea->sqlarea.ulRecNo;
|
||||
}
|
||||
pTag->fBof = pTag->fEof = FALSE;
|
||||
return TRUE;
|
||||
pTag->fBof = pTag->fEof = HB_FALSE;
|
||||
return HB_TRUE;
|
||||
}
|
||||
|
||||
|
||||
@@ -613,20 +613,20 @@ static void hb_mixTagAddKeyPos( PMIXTAG pTag, PMIXNODE pNode, unsigned int uiPos
|
||||
}
|
||||
|
||||
|
||||
static BOOL hb_mixTagAddKey( PMIXTAG pTag, PMIXKEY pKey )
|
||||
static HB_BOOL hb_mixTagAddKey( PMIXTAG pTag, PMIXKEY pKey )
|
||||
{
|
||||
PMIXNODE pNode;
|
||||
unsigned int ui;
|
||||
int i;
|
||||
|
||||
i = hb_mixTagFindKey( pTag, pKey, pTag->uiKeyLen, &pNode, &ui, FALSE );
|
||||
i = hb_mixTagFindKey( pTag, pKey, pTag->uiKeyLen, &pNode, &ui, HB_FALSE );
|
||||
|
||||
/* Key can not be duplicated */
|
||||
if ( ! i )
|
||||
return FALSE;
|
||||
return HB_FALSE;
|
||||
|
||||
hb_mixTagAddKeyPos( pTag, pNode, ui, pKey, NULL, NULL );
|
||||
return TRUE;
|
||||
return HB_TRUE;
|
||||
}
|
||||
|
||||
|
||||
@@ -776,19 +776,19 @@ static void hb_mixTagDelKeyPos( PMIXTAG pTag, PMIXNODE pNode, unsigned int uiPos
|
||||
}
|
||||
|
||||
|
||||
static BOOL hb_mixTagDelKey( PMIXTAG pTag, PMIXKEY pKey )
|
||||
static HB_BOOL hb_mixTagDelKey( PMIXTAG pTag, PMIXKEY pKey )
|
||||
{
|
||||
PMIXNODE pNode;
|
||||
unsigned int ui;
|
||||
int i;
|
||||
|
||||
i = hb_mixTagFindKey( pTag, pKey, pTag->uiKeyLen, &pNode, &ui, FALSE );
|
||||
i = hb_mixTagFindKey( pTag, pKey, pTag->uiKeyLen, &pNode, &ui, HB_FALSE );
|
||||
|
||||
if ( i )
|
||||
return FALSE;
|
||||
return HB_FALSE;
|
||||
|
||||
hb_mixTagDelKeyPos( pTag, pNode, ui );
|
||||
return 1;
|
||||
return HB_TRUE;
|
||||
}
|
||||
|
||||
|
||||
@@ -831,7 +831,7 @@ static PMIXTAG hb_mixTagCreate( const char* szTagName, PHB_ITEM pKeyExpr, PHB_IT
|
||||
}
|
||||
}
|
||||
|
||||
pTag->Root = hb_mixTagCreateNode( pTag, TRUE );
|
||||
pTag->Root = hb_mixTagCreateNode( pTag, HB_TRUE );
|
||||
|
||||
ulStartRec = 0;
|
||||
|
||||
@@ -975,10 +975,10 @@ static void hb_mixTagGoTop( PMIXTAG pTag )
|
||||
|
||||
if ( ! pNode->KeyCount )
|
||||
{
|
||||
pTag->fEof = TRUE;
|
||||
pTag->fEof = HB_TRUE;
|
||||
return;
|
||||
}
|
||||
pTag->fEof = FALSE;
|
||||
pTag->fEof = HB_FALSE;
|
||||
pTag->CurNode = pNode;
|
||||
pTag->CurPos = 0;
|
||||
pTag->CurKey = MIX_KEY( pTag, pTag->CurNode, 0 );
|
||||
@@ -997,10 +997,10 @@ static void hb_mixTagGoBottom( PMIXTAG pTag )
|
||||
|
||||
if ( ! pNode->KeyCount )
|
||||
{
|
||||
pTag->fEof = TRUE;
|
||||
pTag->fEof = HB_TRUE;
|
||||
return;
|
||||
}
|
||||
pTag->fEof = FALSE;
|
||||
pTag->fEof = HB_FALSE;
|
||||
pTag->CurNode = pNode;
|
||||
pTag->CurPos = pNode->KeyCount - 1;
|
||||
pTag->CurKey = MIX_KEY( pTag, pTag->CurNode, pTag->CurPos );
|
||||
@@ -1019,7 +1019,7 @@ static void hb_mixTagSkip( PMIXTAG pTag, LONG lSkip )
|
||||
|
||||
if ( lSkip > 0 )
|
||||
{
|
||||
pTag->fBof = FALSE;
|
||||
pTag->fBof = HB_FALSE;
|
||||
while ( ! pTag->fEof && lSkip > 0 )
|
||||
{
|
||||
if ( pNode->Leaf )
|
||||
@@ -1048,7 +1048,7 @@ static void hb_mixTagSkip( PMIXTAG pTag, LONG lSkip )
|
||||
}
|
||||
else
|
||||
{
|
||||
pTag->fEof = TRUE;
|
||||
pTag->fEof = HB_TRUE;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1112,7 +1112,7 @@ static void hb_mixTagSkip( PMIXTAG pTag, LONG lSkip )
|
||||
{
|
||||
pNode = pNode2;
|
||||
uiPos = uiPos2;
|
||||
pTag->fBof = TRUE;
|
||||
pTag->fBof = HB_TRUE;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1189,9 +1189,9 @@ static ULONG hb_mixTagNodeKeyCount( PMIXNODE pNode )
|
||||
}
|
||||
|
||||
|
||||
static BOOL hb_mixCheckRecordFilter( SQLMIXAREAP pArea, ULONG ulRecNo )
|
||||
static HB_BOOL hb_mixCheckRecordFilter( SQLMIXAREAP pArea, ULONG ulRecNo )
|
||||
{
|
||||
BOOL lResult = FALSE;
|
||||
HB_BOOL lResult = HB_FALSE;
|
||||
|
||||
if ( pArea->sqlarea.area.dbfi.itmCobExpr || hb_setGetDeleted() )
|
||||
{
|
||||
@@ -1211,7 +1211,7 @@ static BOOL hb_mixCheckRecordFilter( SQLMIXAREAP pArea, ULONG ulRecNo )
|
||||
}
|
||||
|
||||
|
||||
static ULONG hb_mixDBOIKeyCount( PMIXTAG pTag, BOOL fFilter )
|
||||
static ULONG hb_mixDBOIKeyCount( PMIXTAG pTag, HB_BOOL fFilter )
|
||||
{
|
||||
ULONG ulKeyCount;
|
||||
|
||||
@@ -1245,7 +1245,7 @@ static ULONG hb_mixDBOIKeyCount( PMIXTAG pTag, BOOL fFilter )
|
||||
}
|
||||
|
||||
|
||||
static ULONG hb_mixDBOIKeyNo( PMIXTAG pTag, BOOL fFilter )
|
||||
static ULONG hb_mixDBOIKeyNo( PMIXTAG pTag, HB_BOOL fFilter )
|
||||
{
|
||||
ULONG ulKeyCount;
|
||||
|
||||
@@ -1299,8 +1299,8 @@ static HB_ERRCODE sqlmixGoBottom( SQLMIXAREAP pArea )
|
||||
|
||||
hb_mixTagGoBottom( pArea->pTag );
|
||||
|
||||
pArea->sqlarea.area.fTop = FALSE;
|
||||
pArea->sqlarea.area.fBottom = TRUE;
|
||||
pArea->sqlarea.area.fTop = HB_FALSE;
|
||||
pArea->sqlarea.area.fBottom = HB_TRUE;
|
||||
|
||||
retval = SELF_GOTO( ( AREAP ) pArea, pArea->pTag->CurKey ? pArea->pTag->CurKey->rec : 0 );
|
||||
if ( retval != HB_FAILURE && pArea->sqlarea.fPositioned )
|
||||
@@ -1325,8 +1325,8 @@ static HB_ERRCODE sqlmixGoTop( SQLMIXAREAP pArea )
|
||||
|
||||
hb_mixTagGoTop( pArea->pTag );
|
||||
|
||||
pArea->sqlarea.area.fTop = TRUE;
|
||||
pArea->sqlarea.area.fBottom = FALSE;
|
||||
pArea->sqlarea.area.fTop = HB_TRUE;
|
||||
pArea->sqlarea.area.fBottom = HB_FALSE;
|
||||
|
||||
retval = SELF_GOTO( ( AREAP ) pArea, pArea->pTag->CurKey ? pArea->pTag->CurKey->rec : 0 );
|
||||
if ( retval != HB_FAILURE && pArea->sqlarea.fPositioned )
|
||||
@@ -1336,7 +1336,7 @@ static HB_ERRCODE sqlmixGoTop( SQLMIXAREAP pArea )
|
||||
}
|
||||
|
||||
|
||||
static HB_ERRCODE sqlmixSeek( SQLMIXAREAP pArea, BOOL fSoftSeek, PHB_ITEM pItem, BOOL fFindLast )
|
||||
static HB_ERRCODE sqlmixSeek( SQLMIXAREAP pArea, HB_BOOL fSoftSeek, PHB_ITEM pItem, HB_BOOL fFindLast )
|
||||
{
|
||||
if ( SELF_GOCOLD( ( AREAP ) pArea ) == HB_FAILURE )
|
||||
return HB_FAILURE;
|
||||
@@ -1350,7 +1350,7 @@ static HB_ERRCODE sqlmixSeek( SQLMIXAREAP pArea, BOOL fSoftSeek, PHB_ITEM pItem,
|
||||
{
|
||||
PMIXKEY pKey;
|
||||
HB_ERRCODE errCode = HB_SUCCESS;
|
||||
BOOL fEOF;
|
||||
HB_BOOL fEOF;
|
||||
PMIXTAG pTag = pArea->pTag;
|
||||
PMIXNODE pNode;
|
||||
unsigned int uiKeyLen, ui;
|
||||
@@ -1358,8 +1358,8 @@ static HB_ERRCODE sqlmixSeek( SQLMIXAREAP pArea, BOOL fSoftSeek, PHB_ITEM pItem,
|
||||
if ( pArea->sqlarea.lpdbPendingRel && pArea->sqlarea.lpdbPendingRel->isScoped )
|
||||
SELF_FORCEREL( ( AREAP ) pArea );
|
||||
|
||||
pArea->sqlarea.area.fTop = pArea->sqlarea.area.fBottom = FALSE;
|
||||
pArea->sqlarea.area.fEof = FALSE;
|
||||
pArea->sqlarea.area.fTop = pArea->sqlarea.area.fBottom = HB_FALSE;
|
||||
pArea->sqlarea.area.fEof = HB_FALSE;
|
||||
|
||||
pKey = hb_mixKeyPutItem( NULL, pItem, fFindLast ? ( ULONG ) -1 : 0, pTag );
|
||||
|
||||
@@ -1371,7 +1371,7 @@ static HB_ERRCODE sqlmixSeek( SQLMIXAREAP pArea, BOOL fSoftSeek, PHB_ITEM pItem,
|
||||
uiKeyLen = pTag->uiKeyLen;
|
||||
}
|
||||
|
||||
hb_mixTagFindKey( pTag, pKey, uiKeyLen, &pNode, &ui, TRUE );
|
||||
hb_mixTagFindKey( pTag, pKey, uiKeyLen, &pNode, &ui, HB_TRUE );
|
||||
hb_mixTagSetCurrent( pTag, pNode, ui );
|
||||
|
||||
if ( fFindLast )
|
||||
@@ -1403,7 +1403,7 @@ static HB_ERRCODE sqlmixSeek( SQLMIXAREAP pArea, BOOL fSoftSeek, PHB_ITEM pItem,
|
||||
{
|
||||
pArea->sqlarea.area.fFound = ( uiKeyLen == 0 || memcmp( pTag->CurKey->val, pKey->val, ( ULONG ) uiKeyLen ) == 0 );
|
||||
if ( ! pArea->sqlarea.area.fFound && ! fSoftSeek )
|
||||
fEOF = TRUE;
|
||||
fEOF = HB_TRUE;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1411,7 +1411,7 @@ static HB_ERRCODE sqlmixSeek( SQLMIXAREAP pArea, BOOL fSoftSeek, PHB_ITEM pItem,
|
||||
{
|
||||
errCode = SELF_GOTO( ( AREAP ) pArea, 0 );
|
||||
}
|
||||
pArea->sqlarea.area.fBof = FALSE;
|
||||
pArea->sqlarea.area.fBof = HB_FALSE;
|
||||
|
||||
hb_mixKeyFree( pKey );
|
||||
return errCode;
|
||||
@@ -1422,7 +1422,7 @@ static HB_ERRCODE sqlmixSeek( SQLMIXAREAP pArea, BOOL fSoftSeek, PHB_ITEM pItem,
|
||||
static HB_ERRCODE sqlmixSkipRaw( SQLMIXAREAP pArea, LONG lToSkip )
|
||||
{
|
||||
PMIXTAG pTag = pArea->pTag;
|
||||
BOOL fOut = FALSE;
|
||||
HB_BOOL fOut = HB_FALSE;
|
||||
|
||||
if ( SELF_GOCOLD( ( AREAP ) pArea ) == HB_FAILURE )
|
||||
return HB_FAILURE;
|
||||
@@ -1436,7 +1436,7 @@ static HB_ERRCODE sqlmixSkipRaw( SQLMIXAREAP pArea, LONG lToSkip )
|
||||
if ( ! hb_mixTagRefreshKey( pTag ) )
|
||||
{
|
||||
if ( lToSkip > 0 || pArea->sqlarea.fPositioned )
|
||||
fOut = TRUE;
|
||||
fOut = HB_TRUE;
|
||||
else
|
||||
{
|
||||
hb_mixTagGoBottom( pTag );
|
||||
@@ -1458,8 +1458,8 @@ static HB_ERRCODE sqlmixSkipRaw( SQLMIXAREAP pArea, LONG lToSkip )
|
||||
|
||||
static HB_ERRCODE sqlmixGoCold( SQLMIXAREAP pArea )
|
||||
{
|
||||
BOOL fRecordChanged = pArea->sqlarea.fRecordChanged;
|
||||
BOOL fAppend = pArea->sqlarea.fAppend;
|
||||
HB_BOOL fRecordChanged = pArea->sqlarea.fRecordChanged;
|
||||
HB_BOOL fAppend = pArea->sqlarea.fAppend;
|
||||
|
||||
if ( SUPER_GOCOLD( ( AREAP ) pArea ) == HB_FAILURE )
|
||||
return HB_FAILURE;
|
||||
@@ -1468,7 +1468,7 @@ static HB_ERRCODE sqlmixGoCold( SQLMIXAREAP pArea )
|
||||
{
|
||||
PMIXTAG pTag;
|
||||
PMIXKEY pKey = NULL;
|
||||
BOOL fAdd, fDel;
|
||||
HB_BOOL fAdd, fDel;
|
||||
LPDBRELINFO lpdbPendingRel;
|
||||
|
||||
lpdbPendingRel = pArea->sqlarea.lpdbPendingRel;
|
||||
@@ -1487,10 +1487,10 @@ static HB_ERRCODE sqlmixGoCold( SQLMIXAREAP pArea )
|
||||
if ( pTag->pForItem != NULL )
|
||||
fAdd = hb_mixEvalCond( pArea, pTag->pForItem );
|
||||
else
|
||||
fAdd = TRUE;
|
||||
fAdd = HB_TRUE;
|
||||
|
||||
if ( fAppend )
|
||||
fDel = FALSE;
|
||||
fDel = HB_FALSE;
|
||||
else
|
||||
{
|
||||
if ( hb_mixKeyCompare( pTag, pKey, pTag->HotKey, pTag->uiKeyLen ) == 0 )
|
||||
@@ -1877,13 +1877,13 @@ static HB_ERRCODE sqlmixOrderInfo( SQLMIXAREAP pArea, USHORT uiIndex, LPDBORDERI
|
||||
case DBOI_FINDREC:
|
||||
pOrderInfo->itmResult = hb_itemPutL( pOrderInfo->itmResult,
|
||||
hb_cdxDBOIFindRec( pArea, pTag,
|
||||
hb_itemGetNL( pOrderInfo->itmNewVal ), FALSE ) );
|
||||
hb_itemGetNL( pOrderInfo->itmNewVal ), HB_FALSE ) );
|
||||
break;
|
||||
|
||||
case DBOI_FINDRECCONT:
|
||||
pOrderInfo->itmResult = hb_itemPutL( pOrderInfo->itmResult,
|
||||
hb_cdxDBOIFindRec( pArea, pTag,
|
||||
hb_itemGetNL( pOrderInfo->itmNewVal ), TRUE ) );
|
||||
hb_itemGetNL( pOrderInfo->itmNewVal ), HB_TRUE ) );
|
||||
break;
|
||||
*/
|
||||
case DBOI_NAME:
|
||||
@@ -1900,7 +1900,7 @@ static HB_ERRCODE sqlmixOrderInfo( SQLMIXAREAP pArea, USHORT uiIndex, LPDBORDERI
|
||||
|
||||
case DBOI_ISDESC:
|
||||
case DBOI_UNIQUE:
|
||||
pOrderInfo->itmResult = hb_itemPutL( pOrderInfo->itmResult, FALSE );
|
||||
pOrderInfo->itmResult = hb_itemPutL( pOrderInfo->itmResult, HB_FALSE );
|
||||
break;
|
||||
|
||||
case DBOI_SCOPETOP:
|
||||
@@ -1945,23 +1945,23 @@ static HB_ERRCODE sqlmixOrderInfo( SQLMIXAREAP pArea, USHORT uiIndex, LPDBORDERI
|
||||
}
|
||||
if ( pTag->CurKey->rec == pArea->sqlarea.ulRecNo )
|
||||
pOrderInfo->itmResult = hb_cdxKeyGetItem( pTag->CurKey,
|
||||
pOrderInfo->itmResult, pTag, TRUE );
|
||||
pOrderInfo->itmResult, pTag, HB_TRUE );
|
||||
}
|
||||
break;
|
||||
|
||||
case DBOI_CUSTOM:
|
||||
pOrderInfo->itmResult = hb_itemPutL( pOrderInfo->itmResult, ( pTag ? pTag->fCustom : FALSE ) );
|
||||
pOrderInfo->itmResult = hb_itemPutL( pOrderInfo->itmResult, ( pTag ? pTag->fCustom : HB_FALSE ) );
|
||||
if ( pOrderInfo->itmNewVal && HB_IS_LOGICAL( pOrderInfo->itmNewVal )
|
||||
&& hb_itemGetL( pOrderInfo->itmNewVal ) )
|
||||
{
|
||||
pTag->fCustom = TRUE;
|
||||
pTag->fCustom = HB_TRUE;
|
||||
}
|
||||
break;
|
||||
|
||||
case DBOI_KEYADD:
|
||||
if ( ! pTag )
|
||||
{
|
||||
pOrderInfo->itmResult = hb_itemPutL( pOrderInfo->itmResult, FALSE );
|
||||
pOrderInfo->itmResult = hb_itemPutL( pOrderInfo->itmResult, HB_FALSE );
|
||||
}
|
||||
else
|
||||
{
|
||||
@@ -1972,16 +1972,16 @@ static HB_ERRCODE sqlmixOrderInfo( SQLMIXAREAP pArea, USHORT uiIndex, LPDBORDERI
|
||||
|
||||
if ( ! pArea->sqlarea.fPositioned ||
|
||||
( pTag->pForItem &&
|
||||
! hb_cdxEvalCond( pArea, pTag->pForItem, TRUE ) ) )
|
||||
! hb_cdxEvalCond( pArea, pTag->pForItem, HB_TRUE ) ) )
|
||||
{
|
||||
pOrderInfo->itmResult = hb_itemPutL( pOrderInfo->itmResult, FALSE );
|
||||
pOrderInfo->itmResult = hb_itemPutL( pOrderInfo->itmResult, HB_FALSE );
|
||||
}
|
||||
else
|
||||
{
|
||||
LPCDXKEY pKey;
|
||||
hb_cdxIndexLockWrite( pTag->pIndex );
|
||||
if ( pOrderInfo->itmNewVal && ! HB_IS_NIL( pOrderInfo->itmNewVal ) )
|
||||
pKey = hb_cdxKeyPutItem( NULL, pOrderInfo->itmNewVal, pArea->sqlarea.ulRecNo, pTag, TRUE, TRUE );
|
||||
pKey = hb_cdxKeyPutItem( NULL, pOrderInfo->itmNewVal, pArea->sqlarea.ulRecNo, pTag, HB_TRUE, HB_TRUE );
|
||||
else
|
||||
pKey = hb_cdxKeyEval( NULL, pTag );
|
||||
pOrderInfo->itmResult = hb_itemPutL( pOrderInfo->itmResult,
|
||||
@@ -2000,7 +2000,7 @@ static HB_ERRCODE sqlmixOrderInfo( SQLMIXAREAP pArea, USHORT uiIndex, LPDBORDERI
|
||||
case DBOI_KEYDELETE:
|
||||
if ( ! pTag )
|
||||
{
|
||||
pOrderInfo->itmResult = hb_itemPutL( pOrderInfo->itmResult, FALSE );
|
||||
pOrderInfo->itmResult = hb_itemPutL( pOrderInfo->itmResult, HB_FALSE );
|
||||
}
|
||||
else
|
||||
{
|
||||
@@ -2011,16 +2011,16 @@ static HB_ERRCODE sqlmixOrderInfo( SQLMIXAREAP pArea, USHORT uiIndex, LPDBORDERI
|
||||
|
||||
if ( !pArea->sqlarea.fPositioned ||
|
||||
( pTag->pForItem &&
|
||||
!hb_cdxEvalCond( pArea, pTag->pForItem, TRUE ) ) )
|
||||
!hb_cdxEvalCond( pArea, pTag->pForItem, HB_TRUE ) ) )
|
||||
{
|
||||
pOrderInfo->itmResult = hb_itemPutL( pOrderInfo->itmResult, FALSE );
|
||||
pOrderInfo->itmResult = hb_itemPutL( pOrderInfo->itmResult, HB_FALSE );
|
||||
}
|
||||
else
|
||||
{
|
||||
LPCDXKEY pKey;
|
||||
hb_cdxIndexLockWrite( pTag->pIndex );
|
||||
if ( pOrderInfo->itmNewVal && !HB_IS_NIL( pOrderInfo->itmNewVal ) )
|
||||
pKey = hb_cdxKeyPutItem( NULL, pOrderInfo->itmNewVal, pArea->sqlarea.ulRecNo, pTag, TRUE, TRUE );
|
||||
pKey = hb_cdxKeyPutItem( NULL, pOrderInfo->itmNewVal, pArea->sqlarea.ulRecNo, pTag, HB_TRUE, HB_TRUE );
|
||||
else
|
||||
pKey = hb_cdxKeyEval( NULL, pTag );
|
||||
pOrderInfo->itmResult = hb_itemPutL( pOrderInfo->itmResult,
|
||||
@@ -2039,7 +2039,7 @@ static HB_ERRCODE sqlmixOrderInfo( SQLMIXAREAP pArea, USHORT uiIndex, LPDBORDERI
|
||||
*/
|
||||
case DBOI_SHARED:
|
||||
case DBOI_ISREADONLY:
|
||||
pOrderInfo->itmResult = hb_itemPutL( pOrderInfo->itmResult, FALSE );
|
||||
pOrderInfo->itmResult = hb_itemPutL( pOrderInfo->itmResult, HB_FALSE );
|
||||
break;
|
||||
|
||||
default:
|
||||
|
||||
Reference in New Issue
Block a user