Determine Database Type from ColdFusion Data Source
I have web site with source co开发者_JS百科de in ColdFusion. How can I find out which database is used and where is database files? Thank you!
Also, I haven't access to CF Admin.
Assuming you are using CF8 or later:
If you have the datasource (which you can see in the CFQUERY/CFSTOREDPROC) you can use cfdbinfo to get database information.
http://livedocs.adobe.com/coldfusion/8/htmldocs/help.html?content=Tags_d-e_01.html for details.
Search through the entire codebase for instances of the tag
<CFQUERY>
(and additionally<CFSTOREDPROC>
).Look at the value entered into the attribute "datasource", collect them all up.
If you have access to CF Admin:
Log into the ColdFusion Administrator, navigate to Datasources, and match the datasource names with the ones you found in your search.
Examine the DSN settings. They are your databases.
If you do not have access to CF Admin:
- Pass the names of the datasources to
<CFDBINFO>
and dump out the results (thnx to TheCycoONE)
Shawn hit it: you'll have to get into the ColdFusion Administrator's Datasource settings. Find the name of the datasource in your Application.cfm/cfc/direct in the query, then in click that DSN in the administrator. It should tell you which db (type) connector it's using, and the general location.
精彩评论