| @@ 425-435 (lines=11) @@ | ||
| 422 | /** |
|
| 423 | * {@inheritdoc} |
|
| 424 | */ |
|
| 425 | public function hasColumn($tableName, $columnName) |
|
| 426 | { |
|
| 427 | $rows = $this->fetchAll(sprintf('SHOW COLUMNS FROM %s', $this->quoteTableName($tableName))); |
|
| 428 | foreach ($rows as $column) { |
|
| 429 | if (strcasecmp($column['Field'], $columnName) === 0) { |
|
| 430 | return true; |
|
| 431 | } |
|
| 432 | } |
|
| 433 | ||
| 434 | return false; |
|
| 435 | } |
|
| 436 | ||
| 437 | /** |
|
| 438 | * {@inheritdoc} |
|
| @@ 560-570 (lines=11) @@ | ||
| 557 | /** |
|
| 558 | * {@inheritdoc} |
|
| 559 | */ |
|
| 560 | public function hasColumn($tableName, $columnName) |
|
| 561 | { |
|
| 562 | $rows = $this->getTableInfo($tableName); |
|
| 563 | foreach ($rows as $column) { |
|
| 564 | if (strcasecmp($column['name'], $columnName) === 0) { |
|
| 565 | return true; |
|
| 566 | } |
|
| 567 | } |
|
| 568 | ||
| 569 | return false; |
|
| 570 | } |
|
| 571 | ||
| 572 | /** |
|
| 573 | * {@inheritdoc} |
|