I have grocery crud with codeigniter running in xampp with php 5.6.8.
I made codeigniter connect with sqlsrv but when i open the crud i receive:
Error Number: 42000/156
[Microsoft][SQL Server Native Client 10.0][SQL Server]Incorrect syntax near the keyword 'FROM'.
SHOW COLUMNS FROM `PERSONA_TEST`
Filename: D:/Trabajo/xampp/htdocs/creditos/crud/application/models/grocery_crud_model.php
Line Number: 431
What i know:
I have a sql statement that's not made to work with sqlserver sintax. Should I need to edit grocery_crud_model?
Thanks!
After a bit of time i made to use sqlsrv. I edited the grocery_crud_model.php
Here is the connection :
Here is the controller: (need to specify primary key)
And the view:
Also i used this tutorial for the crud:
http://sourcezilla.com/articulos/programacion/como-realizar-un-crud-sencillo-en-php-y-codeigniter-desde-cero.html
Hope helps someone in the future.
i don't think ms sql server supports "show column" statement. You need change your code , or db server, or the model configuration.