This is a discussion on bcp_bind and SQL DATETIME type within the MS SQL ODBC forums, part of the Microsoft SQL Server category; --> Hi all, I'm working on a simple ODBC API bulk load application and I've run into a problem. I ...
| |||||||
| Register | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
| ||||
| Hi all, I'm working on a simple ODBC API bulk load application and I've run into a problem. I am binding variables in memory and sending the rows as prescribed in the ODBC 3.0 API Reference and on MSDN. Everything works fine for SQL VARCHAR and SQL INTEGER data types; however, I run into issues when I try to bind SQL DATETIME data types. I can't seem to find examples of how this should be done anywhere... Should my variable that I'm binding to be a C-Style string or a SQL_TIMESTAMP_STRUCT or a time_t structure? It's all a blur... Anyone know where I can find a sample that bcp_binds to a DATETIME column in a table? TIA |
| ||||
| Never mind, issue resolved. "Michael C#" wrote: > Hi all, > > I'm working on a simple ODBC API bulk load application and I've run > into a problem. I am binding variables in memory and sending the rows > as prescribed in the ODBC 3.0 API Reference and on MSDN. Everything > works fine for SQL VARCHAR and SQL INTEGER data types; however, I run > into issues when I try to bind SQL DATETIME data types. I can't seem > to find examples of how this should be done anywhere... Should my > variable that I'm binding to be a C-Style string or a > SQL_TIMESTAMP_STRUCT or a time_t structure? It's all a blur... > > Anyone know where I can find a sample that bcp_binds to a DATETIME > column in a table? > > TIA > > |