本文整理匯總了PHP中dbconnection::queryArrayAssoc方法的典型用法代碼示例。如果您正苦於以下問題:PHP dbconnection::queryArrayAssoc方法的具體用法?PHP dbconnection::queryArrayAssoc怎麽用?PHP dbconnection::queryArrayAssoc使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類dbconnection
的用法示例。
在下文中一共展示了dbconnection::queryArrayAssoc方法的1個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。
示例1: exportGameData
private static function exportGameData($pack)
{
$tables = array();
$columns = array();
$coltablemap = array();
duplicate::getSchema($tables, $columns, $coltablemap);
$table_data = array();
for ($i = 0; $i < count($tables); $i++) {
$table = $tables[$i];
$cols = $columns[$i];
$old_data = dbconnection::queryArrayAssoc("SELECT * FROM {$table} WHERE game_id = '{$pack->game_id}';");
$table_data[] = new table_data($table, $cols, $old_data);
}
$package = new stdClass();
$package->game_id = $pack->game_id;
$package->table_data = $table_data;
$db_upgrade = dbconnection::queryObject("SELECT * FROM db_upgrades ORDER BY version_major DESC, version_minor DESC LIMIT 1");
if (!$db_upgrade) {
$package->db_upgrade = null;
} else {
$package->db_upgrade = $db_upgrade->version_major . "." . $db_upgrade->version_minor;
}
return $package;
}