| Oracle FAQ | Your Portal to the Oracle Knowledge Grid | |
Home -> Community -> Usenet -> c.d.o.tools -> Newbie: Inserting Nulls in ODBC ?
Hi,
I can input a number into my simplified test table fine in C (shown below). But what do I have to change if I want to enter null instead of 0 ?
Is the solution similar for text fields etc ?
Thanks.
SDWORD sd_ind, cb_ind;
rc = SQLPrepare(Hstmt,
"INSERT INTO test (mynumber) VALUES ( ? )",
SQL_NTS);
rc=SQLBindParameter(Hstmt, 1, SQL_PARAM_INPUT, SQL_C_SLONG,
SQL_INTEGER, 0, 0, &sd_ind, 0, &cb_ind);
rc = SQLExecute(Hstmt);
Received on Sun Jun 25 2000 - 00:00:00 CDT
![]() |
![]() |