Database Error Number 7405 |
[eluser]whobutsb[/eluser]
Hello All I'm running into some issues with querying my MSSQL Database. I have a DB that is pulling a list of employees from Active Directory into a View. Everything works fine with the view and I have used it in the past but not with CI. I now have a CI Model that is supposed to search the table using the WHERE LIKE statement. My Model looks like this: Code: class NHCEmployee_model extends Model{ I have the the Database all set up perfectly in CI with the correct User/Pass. But whenever I run the query I get this error message: Code: <h1>A Database Error Occurred</h1> Is there any way to debug these Error Numbers? When I run this query in MSSQL Management Query it performs fine. Thank you for the help!
[eluser]bena[/eluser]
Hi, This is just a suggestion, but maybe give the select function an array as opposed to a string? I'm not sure if it even accepts an array but it may be worth a shot! Code: # Change: Hope you fix it. Regards, Ben
[eluser]whobutsb[/eluser]
Hi Ben, Thanks for the tip. I tried it with an array and received the same results. I have used both strings and arrays in my select statements in the past and they have both worked out just fine. But I'm guessing there is something else that is happening. Thanks for the help anyways! Steve
[eluser]John_Betong[/eluser]
From: http://ellislab.com/codeigniter/user-gui...lpers.html Try using this function: $this->db->last_query();, copy the result and paste it to PhpMyAdmin() |
Welcome Guest, Not a member yet? Register Sign In |