Index: t3lib/cache/backend/class.t3lib_cache_backend_dbbackend.php =================================================================== --- t3lib/cache/backend/class.t3lib_cache_backend_dbbackend.php (revision 6795) +++ t3lib/cache/backend/class.t3lib_cache_backend_dbbackend.php (working copy) @@ -125,13 +125,23 @@ ) ); - foreach ($tags as $tag) { - $GLOBALS['TYPO3_DB']->exec_INSERTquery( + if (count($tags)) { + $fields = array(); + $fields[] = 'identifier'; + $fields[] = 'tag'; + + $tagRows = array(); + foreach ($tags as $tag) { + $tagRow = array(); + $tagRow[] = $entryIdentifier; + $tagRow[] = $tag; + $tagRows[] = $tagRow; + } + + $GLOBALS['TYPO3_DB']->exec_INSERTmultipleRows( $this->tagsTable, - array( - 'identifier' => $entryIdentifier, - 'tag' => $tag, - ) + $fields, + $tagRows ); } }