Fix #2836
diff --git a/system/database/DB_query_builder.php b/system/database/DB_query_builder.php
index c543e15..8223baa 100644
--- a/system/database/DB_query_builder.php
+++ b/system/database/DB_query_builder.php
@@ -2367,7 +2367,7 @@
 			for ($i = 0, $c = count($this->qb_groupby); $i < $c; $i++)
 			{
 				// Is it already compiled?
-				if (is_string($this->qb_groupby))
+				if (is_string($this->qb_groupby[$i]))
 				{
 					continue;
 				}