Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
D
doctrine-dbal
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Tomáš Trávníček
doctrine-dbal
Commits
01f5436b
Commit
01f5436b
authored
May 27, 2007
by
zYne
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
--no commit message
--no commit message
parent
3b4de020
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
4 deletions
+6
-4
query_cache.php
benchmark/query_cache.php
+6
-4
No files found.
benchmark/query_cache.php
View file @
01f5436b
...
...
@@ -24,6 +24,8 @@ while ($i--) {
$coll
->
save
();
$conn
->
clear
();
print
"<pre>DQL BENCHMARK
\n
"
;
$timepoint
=
microtime
(
true
);
$i
=
100
;
...
...
@@ -34,7 +36,7 @@ while ($i--) {
$query
->
from
(
'Entity e'
)
->
where
(
'e.id > 0'
);
$coll
=
$query
->
execute
(
array
(),
Doctrine
::
FETCH_ARRAY
);
}
print
'EXECUTED 100 QUERIES WITH CACHING ENABLED + FETCH_ARRAY : '
.
(
microtime
(
true
)
-
$timepoint
)
.
"
<br \>
"
;
print
'EXECUTED 100 QUERIES WITH CACHING ENABLED + FETCH_ARRAY : '
.
(
microtime
(
true
)
-
$timepoint
)
.
"
\n
"
;
$timepoint
=
microtime
(
true
);
...
...
@@ -45,7 +47,7 @@ while ($i--) {
$query
->
from
(
'Entity e'
)
->
where
(
'e.id > 0'
);
$coll
=
$query
->
execute
(
array
(),
Doctrine
::
FETCH_ARRAY
);
}
print
'EXECUTED 100 QUERIES WITHOUT CACHING + FETCH_ARRAY : '
.
(
microtime
(
true
)
-
$timepoint
);
print
'EXECUTED 100 QUERIES WITHOUT CACHING + FETCH_ARRAY : '
.
(
microtime
(
true
)
-
$timepoint
)
.
"
\n
"
;
$timepoint
=
microtime
(
true
);
...
...
@@ -57,7 +59,7 @@ while ($i--) {
$query
->
from
(
'Entity e'
)
->
where
(
'e.id > 0'
);
$coll
=
$query
->
execute
();
}
print
'EXECUTED 100 QUERIES WITH CACHING ENABLED + FETCH_RECORD : '
.
(
microtime
(
true
)
-
$timepoint
)
.
"
<br \>
"
;
print
'EXECUTED 100 QUERIES WITH CACHING ENABLED + FETCH_RECORD : '
.
(
microtime
(
true
)
-
$timepoint
)
.
"
\n
"
;
$timepoint
=
microtime
(
true
);
...
...
@@ -68,4 +70,4 @@ while ($i--) {
$query
->
from
(
'Entity e'
)
->
where
(
'e.id > 0'
);
$coll
=
$query
->
execute
();
}
print
'EXECUTED 100 QUERIES WITHOUT CACHING + FETCH_RECORD : '
.
(
microtime
(
true
)
-
$timepoint
);
print
'EXECUTED 100 QUERIES WITHOUT CACHING + FETCH_RECORD : '
.
(
microtime
(
true
)
-
$timepoint
)
.
"
\n
"
;
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a 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