| @@ 391-403 (lines=13) @@ | ||
| 388 | /** |
|
| 389 | * {@inheritdoc} |
|
| 390 | */ |
|
| 391 | public function hasColumn($tableName, $columnName) |
|
| 392 | { |
|
| 393 | $sql = sprintf( |
|
| 394 | "select count(*) as count from ALL_TAB_COLUMNS |
|
| 395 | where table_name = '%s' and column_name = '%s'", |
|
| 396 | $tableName, |
|
| 397 | $columnName |
|
| 398 | ); |
|
| 399 | ||
| 400 | $result = $this->fetchRow($sql); |
|
| 401 | ||
| 402 | return $result['COUNT'] > 0; |
|
| 403 | } |
|
| 404 | ||
| 405 | /** |
|
| 406 | * {@inheritdoc} |
|
| @@ 413-425 (lines=13) @@ | ||
| 410 | /** |
|
| 411 | * {@inheritdoc} |
|
| 412 | */ |
|
| 413 | public function hasColumn($tableName, $columnName) |
|
| 414 | { |
|
| 415 | $sql = sprintf( |
|
| 416 | "SELECT count(*) as [count] |
|
| 417 | FROM information_schema.columns |
|
| 418 | WHERE table_name = '%s' AND column_name = '%s'", |
|
| 419 | $tableName, |
|
| 420 | $columnName |
|
| 421 | ); |
|
| 422 | $result = $this->fetchRow($sql); |
|
| 423 | ||
| 424 | return $result['count'] > 0; |
|
| 425 | } |
|
| 426 | ||
| 427 | /** |
|
| 428 | * {@inheritdoc} |
|