Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
project
drupal
Commits
259c876b
Commit
259c876b
authored
Mar 19, 2007
by
Steven Wittens
Browse files
#109513
: Create temporary mysql tables in memory.
parent
081d6d66
Changes
2
Hide whitespace changes
Inline
Side-by-side
includes/database.mysql.inc
View file @
259c876b
...
...
@@ -358,7 +358,7 @@ function db_query_temporary($query) {
$tablename
=
array_pop
(
$args
);
array_shift
(
$args
);
$query
=
preg_replace
(
'/^SELECT/i'
,
'CREATE TEMPORARY TABLE '
.
$tablename
.
' SELECT'
,
db_prefix_tables
(
$query
));
$query
=
preg_replace
(
'/^SELECT/i'
,
'CREATE TEMPORARY TABLE '
.
$tablename
.
'
Engine=HEAP
SELECT'
,
db_prefix_tables
(
$query
));
if
(
isset
(
$args
[
0
])
and
is_array
(
$args
[
0
]))
{
// 'All arguments in one array' syntax
$args
=
$args
[
0
];
}
...
...
includes/database.mysqli.inc
View file @
259c876b
...
...
@@ -338,7 +338,7 @@ function db_query_temporary($query) {
$tablename
=
array_pop
(
$args
);
array_shift
(
$args
);
$query
=
preg_replace
(
'/^SELECT/i'
,
'CREATE TEMPORARY TABLE '
.
$tablename
.
' SELECT'
,
db_prefix_tables
(
$query
));
$query
=
preg_replace
(
'/^SELECT/i'
,
'CREATE TEMPORARY TABLE '
.
$tablename
.
'
Engine=HEAP
SELECT'
,
db_prefix_tables
(
$query
));
if
(
isset
(
$args
[
0
])
and
is_array
(
$args
[
0
]))
{
// 'All arguments in one array' syntax
$args
=
$args
[
0
];
}
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment