|
(发帖时间:
12/09/2007 08:14:40)
<cfscript> //Log in to admin createObject("component","cfide.adminapi.administrator").login("admin");
// Instantiate the data source object. myObj = createObject("component","cfide.adminapi.datasource");
// Required arguments for a data source. stDSN = structNew(); stDSN.driver = "MSSQLServer"; stDSN.name="datesourcename"; stDSN.host = "127.0.0.1"; stDSN.port = "1433"; stDSN.database = "datebasename"; stDSN.username = "sa";
stDSN.password = "sa"; stDSN.login_timeout = "29"; stDSN.timeout = "23"; stDSN.interval = 6; stDSN.buffer = "64000"; stDSN.blob_buffer = "64000"; stDSN.setStringParameterAsUnicode = "false"; stDSN.description = "Northwind SQL Server"; stDSN.pooling = true; stDSN.maxpooledstatements = 999; stDSN.enableMaxConnections = "true"; stDSN.maxConnections = "299"; stDSN.enable_clob = true; stDSN.enable_blob = true; stDSN.disable = false; stDSN.storedProc = true; stDSN.alter = false; stDSN.grant = true; stDSN.select = true; stDSN.update = true; stDSN.create = true; stDSN.delete = true; stDSN.drop = false; stDSN.revoke = false;
//Create a DSN. myObj.setMSSQL(argumentCollection=stDSN); </cfscript> <cfdump var="#stDSN#">
|