| 475 | } |
| 476 | |
| 477 | S32 SQLiteObject::GetColumnIndex(S32 iResult, const char* columnName) |
| 478 | { |
| 479 | S32 iIndex; |
| 480 | VectorPtr<char*>::iterator i; |
| 481 | sqlite_resultset* pResultSet; |
| 482 | sqlite_resultrow* pRow; |
| 483 | |
| 484 | pResultSet = GetResultSet(iResult); |
| 485 | if (!pResultSet) |
| 486 | return 0; |
| 487 | |
| 488 | pRow = pResultSet->vRows[0]; |
| 489 | if (!pRow) |
| 490 | return 0; |
| 491 | |
| 492 | iIndex = 0; |
| 493 | for (i = pRow->vColumnNames.begin(); i != pRow->vColumnNames.end(); i++) |
| 494 | { |
| 495 | if (dStricmp((*i), columnName) == 0) |
| 496 | return iIndex + 1; |
| 497 | iIndex++; |
| 498 | } |
| 499 | |
| 500 | return 0; |
| 501 | } |
| 502 | |
| 503 | S32 SQLiteObject::numResultSets() |
| 504 | { |
no test coverage detected