* DB Column Exists */
(
$table, $column_name
)
| 356 | * DB Column Exists |
| 357 | */ |
| 358 | public static function db_column_exists( |
| 359 | $table, $column_name |
| 360 | ){ |
| 361 | |
| 362 | // SQL. |
| 363 | $sql = 'SELECT '.$column_name.' FROM ` |
| 364 | '.$table.'` '; |
| 365 | $params = array(); |
| 366 | |
| 367 | // Query |
| 368 | $result = self::query($sql, $params, false); |
| 369 | |
| 370 | // Result |
| 371 | if(!$result){ |
| 372 | return false; |
| 373 | }else{ |
| 374 | return true; |
| 375 | } |
| 376 | |
| 377 | } |
| 378 | |
| 379 | /** |
| 380 | * Update DB Rows |
no test coverage detected