Update database.php

This commit is contained in:
Namhyeon Go 2020-02-04 19:22:52 +09:00 committed by GitHub
parent d1b9d1303a
commit e10cad84c4
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -1003,7 +1003,7 @@ if(!check_function_exists("exec_db_temp_create")) {
$temptables[] = $tablename;
set_shared_var("temptables", $temptables);
// set variables
// set engine (default: memory)
$_engine = get_value_in_array("engine", $options, "memory");
// create temporary table
@ -1022,8 +1022,10 @@ if(!check_function_exists("exec_db_temp_start")) {
function exec_db_temp_start($sql, $bind=array(), $options=array()) {
$flag = false;
// set engine (default: memory)
$_engine = get_value_in_array("engine", $options, "memory");
// create temporary table
$tablename = make_random_id();
if($_engine !== false) {
$sql = sprintf("create temporary table if not exists `%s` %s", $tablename, $sql);