⚠ In case you've missed it, we have migrated to our new website, with a brand new forum. For more details about the migration you can read our blog post for website migration. This is an archived forum. ⚠

  •     

profile picture

Database Error \ SQL Syntax Error



Raymond Wongso
  • profile picture
  • Member

Posted 28 December 2016 - 08:43 AM

Hi, I am new to grocery crud and I follow the newbie tutorial here
http://www.grocerycrud.com/documentation/create-crud-codeigniter-tutorial

 

... and its working well, BUT when I make another table, named "items" and try to do this..

 

function items

{

   $crud = new grocery_CRUD();

   $crud->set_table('items');

   $output = $crud->render();

 

   print_r($output);

 

   die();

}

 

it throws this error :

 

-

Error Number: 1064

You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'FROM `items`' at line 2

SELECT `items`. FROM `items`

Filename: D:/XAMPP/htdocs/cobagrocery/system/database/DB_driver.php

Line Number: 691

-

 

Why is this?