tracker issue : CF-4204003

select a category, or use search below
(searches all categories and all time range)

Incorrect defaults in setMSSQL()

| View in Tracker

Status/Resolution/Reason: Open//

Reporter/Name(from Bugbase): Mark P. / ()

Created: 02/04/2019

Components: Administrator, Admin API

Versions: 13.0

Failure Type: Incorrectly functioning

Found In Build/Fixed In Build: 2018.0.01.311402 /

Priority/Frequency: Normal / All users will encounter

Locale/System: English / Win 2016

Vote Count: 1

When creating a DSN via the Admin API (calling datasources.cfc) the default Select Method is "Cursor". The GUI defaults to "Direct".

Same issue with the Max Pooled Statements.  The API defaults to 1000 and the GUI defaults to 100.

The defaults in the API and the GUI should be the same.



+1 - a decade old issue
Vote by Aaron N.
30187 | February 05, 2019 10:36:15 AM GMT
Hi Mark, I asked the same during CF9 PR in 2009. Here is the question I asked, and scroll to bottom for Adobe's answer. My question: ----------- If an MSSQL datasource is added via CF Administrator, the following are set by default: - type - vendor - cf_pooled - usespylog - spylogfile - supportlinks - maxpooledstatements key in connectionprops struct - "MaxPooledStatements" parameter in url string But those are not set by default, if datasource is added via Admin API. Bug? Also, setMSSQL() *does* support "type" & "vendor" parameters. But, even if those are passed in, they are still not returned via Admin API. Bug? Also, regarding "maxpooledstatements" key in "connectionprops" struct, there are a couple of "maxpooledstatements" keys returned.. the one directly in the result is always returned, but the one in the result.connectionprops struct is only returned if "maxpooledstatements" is passed into setMSSQL(). Bug? Shouldn’t the Admin API mirror the CF Admin? Or is the Admin API just a work-in-progress w/ gotchas? ----------- Adobe's answer: ----------- You are seeing the differences in behavior between Admin pages and adminAPI because of default values. That is, all fields have default values in admin pages, which is not the case with adminAPI. For example, in case of usespylog, by default false is set in Administrator as we have to show a default value, and no value is set in adminAPI as they are not required. In addition to that, we don’t return type and vendor in the datasource, they are just required to make check some conditions and is not set in the datasource as such. Cf_pooled and maxpooledstatements are related and when no value is passed in the adminAPI, even though a default value of 1000 is returned , maxpooledstatements are not set in the connection string. It will be set only when user sets maxpooledstatements. ----------- Summary: Consistency _should_ and _could_ be done. But.. Thanks!, -Aaron
Comment by Aaron N.
30186 | February 05, 2019 10:44:45 AM GMT
Thanks Aaron - responded to you via ticket CF-4204002
Comment by Mark P.
30196 | February 06, 2019 12:36:25 AM GMT