Retrieve list of datasources

Is there a way to get a list of datasources registerted in the coldfusion administrator?
LVL 1
rot299Asked:
Who is Participating?
 
MauseCommented:
Hi

try this:

<cfscript>
factory = CreateObject("java", "coldfusion.server.ServiceFactory");
datasouorce = factory.DataSourceService.getDatasources();
</cfscript>
<cfdump var="#datasouorce#">

This will give you a structure width all datasources and some more information about the datasources

Mause
0
 
pinaldaveCommented:
I am sure that you can not get the names of them through any other way then logging in the admin of coldfusion.
Because this information is very critical.
Regards,
---Pinal
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.