clear values of type SQL_C_DATE/TIME too (patch 1541829)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@41141 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -2244,6 +2244,20 @@ void wxDbTable::ClearMemberVar(UWORD colNumber, bool setToNull)
|
|||||||
pDt->second = 0;
|
pDt->second = 0;
|
||||||
pDt->fraction = 0;
|
pDt->fraction = 0;
|
||||||
break;
|
break;
|
||||||
|
case SQL_C_DATE:
|
||||||
|
DATE_STRUCT *pDtd;
|
||||||
|
pDtd = (DATE_STRUCT *) colDefs[colNumber].PtrDataObj;
|
||||||
|
pDtd->year = 0;
|
||||||
|
pDtd->month = 0;
|
||||||
|
pDtd->day = 0;
|
||||||
|
break;
|
||||||
|
case SQL_C_TIME:
|
||||||
|
TIME_STRUCT *pDtt;
|
||||||
|
pDtt = (TIME_STRUCT *) colDefs[colNumber].PtrDataObj;
|
||||||
|
pDtt->hour = 0;
|
||||||
|
pDtt->minute = 0;
|
||||||
|
pDtt->second = 0;
|
||||||
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (setToNull)
|
if (setToNull)
|
||||||
|
Reference in New Issue
Block a user