{"action":"created","issue":{"url":"https://api.github.com/repos/joshcam/PHP-MySQLi-Database-Class/issues/208","labels_url":"https://api.github.com/repos/joshcam/PHP-MySQLi-Database-Class/issues/208/labels{/name}","comments_url":"https://api.github.com/repos/joshcam/PHP-MySQLi-Database-Class/issues/208/comments","events_url":"https://api.github.com/repos/joshcam/PHP-MySQLi-Database-Class/issues/208/events","html_url":"https://github.com/joshcam/PHP-MySQLi-Database-Class/issues/208","id":60862498,"number":208,"title":"Multiple queries","user":{"login":"alexa026","id":139744,"avatar_url":"https://avatars.githubusercontent.com/u/139744?v=3","gravatar_id":"","url":"https://api.github.com/users/alexa026","html_url":"https://github.com/alexa026","followers_url":"https://api.github.com/users/alexa026/followers","following_url":"https://api.github.com/users/alexa026/following{/other_user}","gists_url":"https://api.github.com/users/alexa026/gists{/gist_id}","starred_url":"https://api.github.com/users/alexa026/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/alexa026/subscriptions","organizations_url":"https://api.github.com/users/alexa026/orgs","repos_url":"https://api.github.com/users/alexa026/repos","events_url":"https://api.github.com/users/alexa026/events{/privacy}","received_events_url":"https://api.github.com/users/alexa026/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":14,"created_at":"2015-03-12T17:43:48Z","updated_at":"2015-04-23T09:02:30Z","closed_at":null,"body":"Hello, \r\nI'am having inserts added into $sql string. how do i execute them all at once, i've already tried with \r\nrawQuery($sql), but it gives me an error. is there any other way?\r\nNote: inserts are aiming for multiple tables\r\n\r\nThanks in advice."},"comment":{"url":"https://api.github.com/repos/joshcam/PHP-MySQLi-Database-Class/issues/comments/95498072","html_url":"https://github.com/joshcam/PHP-MySQLi-Database-Class/issues/208#issuecomment-95498072","issue_url":"https://api.github.com/repos/joshcam/PHP-MySQLi-Database-Class/issues/208","id":95498072,"user":{"login":"Izopi4a","id":7415020,"avatar_url":"https://avatars.githubusercontent.com/u/7415020?v=3","gravatar_id":"","url":"https://api.github.com/users/Izopi4a","html_url":"https://github.com/Izopi4a","followers_url":"https://api.github.com/users/Izopi4a/followers","following_url":"https://api.github.com/users/Izopi4a/following{/other_user}","gists_url":"https://api.github.com/users/Izopi4a/gists{/gist_id}","starred_url":"https://api.github.com/users/Izopi4a/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Izopi4a/subscriptions","organizations_url":"https://api.github.com/users/Izopi4a/orgs","repos_url":"https://api.github.com/users/Izopi4a/repos","events_url":"https://api.github.com/users/Izopi4a/events{/privacy}","received_events_url":"https://api.github.com/users/Izopi4a/received_events","type":"User","site_admin":false},"created_at":"2015-04-23T09:02:30Z","updated_at":"2015-04-23T09:02:30Z","body":"```\r\nprotected function _buildTableData ($tableData) {\r\n        if (!is_array ($tableData))\r\n            return;\r\n        $isInsert = strpos ($this->_query, 'INSERT');\r\n        $isUpdate = strpos ($this->_query, 'UPDATE');\r\n        if ($isInsert !== false) {\r\n\r\n            $columns = (isset($tableData['columns']) ? $tableData['columns'] : array_keys($tableData) );\r\n            \r\n            $this->_query .= ' (`' . implode($columns, '`, `') . '`)';\r\n            $this->_query .= ' VALUES (';\r\n\r\n            $tableData = $tableData['values'];\r\n```\r\n\r\nso after that we sohuld be able to call the insert method with a sintax like:\r\n\r\n```\r\n$this->DB->insert('products_data', [\r\n            \"columns\" => [\"product_id\", \"data\", \"value\"],\r\n            \"values\" =>  ['50', 'price', '400', '51', 'price', '401','52', 'price', '402','53', 'price', '403','54', 'price', '404']\r\n        ]);\r\n```\r\n"}}