Hi,
I've just bought the premium version of Grid Control and want to use it with my Microsoft SQL database. Not MySQL server.
So how to start? The database.sql is not for MS SQL so to run, what to do?
just the quick start…
🙂
Hello,
Try the sample in demos/loading/db-layer-sqlsvr.php
Just change your database config and table/sql settings. For more customizations, refer docs and other demos on website.
Fantastic!
🙂
It worked!
Thank you for responding me so fast!
This looks very nice!
when I go to the suggested link I get an error on your page mssqlnative extension not installed
This was because, sqlserver is not installed on our server.
I just disabled those demos online. It is tested on local environment and sql server works fine by just changing db conffig.
Sorry if you found an inbox full of my updates, but being in eastern US I think we are are different time frames. Getting closer but still can't get it to work.
I get the following error when $out = $g->render("list1"); is in my code.
Couldn't execute query. 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 '[pltdata].[dbo].[CustomerMasterTable] WHERE 1=1 LIMIT 1 OFFSET 0' at line 1 – SELECT * FROM [pltdata].[dbo].[CustomerMasterTable] WHERE 1=1 LIMIT 1 OFFSET 0
This is what I have.
$db_conf = array();
$db_conf["type"] = "mssqlnative"; // or mssql
$db_conf["server"] = "SQLSERVER";
$db_conf["database"] = "Pltdata";
$g = new jqgrid($db_conf);
// include and create object
include("inc/jqgrid_dist.php");
$g = new jqgrid();
// set few params
$grid["caption"] = "Sample Grid";
$g->set_options($grid);
// render grid and get html/js output
$g->table = "[pltdata].[dbo].[CustomerMasterTable]";
$out = $g->render("list1");
still can't figure out what is giving me this error. I assume I missed a setting somewhere in the config
I guess, the issue is with
$db_conf["server"] = "SQLSERVER";
It should be your instance name OR it could be IP:port
I've also emailed you few samples for connection.
Can anyone help me to fix this error.
Please check your database connection configuration. SQLState: IMSSP Error Code: -1 Message: Invalid option was passed to sqlsrv_connect. SQLState: IMSSP Error Code: -1 Message: Invalid option was passed to sqlsrv_connect.