The code below retrieves all the tnsnames on the system on which it is run
(at least for Solaris which is all I run)
HTH!
#!/usr/local/bin/perl -w
#use strict;
use CGI::Carp qw{fatalsToBrowser};
use DBI;
@data_sources = DBI->data_sources('Oracle');
$i = 0;
while (defined $data_sources[$i]) {
print ("-->$data_sources[$i]\n");
$i++;
}
Stephane Faroult wrote:
>
> [EMAIL PROTECTED] wrote:
> >
> > Thank you Steve, this is a great resource, as it
> > will save duplicating effort.
> >
> > I'll go update my script now...
> >
> > Jared
>
> If I may suggest something, Jared, I am a bit of a Perl illiterate
> (shame! shame!) but it looks to me that you supply the dbname on the
> command line. I think that it would be great if you could, possibly
> optionally, check all tnsnames.ora entries. For what I have heard of the
> text processing capabilities of perl, and for having done it in C, it
> shouldn't be too difficult and would be much appreciated by large shops.
>
> --
> Regards,
>
> Stephane Faroult
> Oriole Ltd
> --
> Please see the official ORACLE-L FAQ: http://www.orafaq.com
> --
> Author: Stephane Faroult
> INET: [EMAIL PROTECTED]
>
> Fat City Network Services -- (858) 538-5051 FAX: (858) 538-5051
> San Diego, California -- Public Internet access / Mailing Lists
> --------------------------------------------------------------------
> To REMOVE yourself from this mailing list, send an E-Mail message
> to: [EMAIL PROTECTED] (note EXACT spelling of 'ListGuru') and in
> the message BODY, include a line containing: UNSUB ORACLE-L
> (or the name of mailing list you want to be removed from). You may
> also send the HELP command for other information (like subscribing).
--
Charlie Mengler Maintenance Warehouse
[EMAIL PROTECTED] 10641 Scripps Summit Ct.
858-831-2229 San Diego, CA 92131
You can lead some people to knowledge, but you can't make them think!
--
Please see the official ORACLE-L FAQ: http://www.orafaq.com
--
Author: Charlie Mengler
INET: [EMAIL PROTECTED]
Fat City Network Services -- (858) 538-5051 FAX: (858) 538-5051
San Diego, California -- Public Internet access / Mailing Lists
--------------------------------------------------------------------
To REMOVE yourself from this mailing list, send an E-Mail message
to: [EMAIL PROTECTED] (note EXACT spelling of 'ListGuru') and in
the message BODY, include a line containing: UNSUB ORACLE-L
(or the name of mailing list you want to be removed from). You may
also send the HELP command for other information (like subscribing).