PRB: Error 3162 Setting FoxPro Date Field to Null (168837)
The information in this article applies to:
- Microsoft Visual Basic Professional Edition for Windows 5.0
- Microsoft Visual Basic Enterprise Edition for Windows 5.0
- Microsoft Visual Basic Professional Edition, 32-bit, for Windows 4.0
- Microsoft Visual Basic Enterprise Edition, 32-bit, for Windows 4.0
- Microsoft Visual FoxPro for Windows 3.0
- Microsoft Visual FoxPro for Windows 5.0
This article was previously published under Q168837 SYMPTOMS
Trying to set a Visual FoxPro Date field to Null via DAO/ODBC results in
the following error:
"Run-time error '3162':
Null Is Invalid."
CAUSE
The FoxPro ODBC driver does not use Null for an empty date.
RESOLUTION
Set the date field to 12/30/1899 instead. The Visual FoxPro ODBC driver
translates this value into an empty date.
STATUS
This behavior is by design.
REFERENCES
Modification Type: | Minor | Last Reviewed: | 10/11/2006 |
---|
Keywords: | kb32bitOnly kberrmsg kbprb kbProgramming KB168837 |
---|
|