RE: Win2k Perl accessing Oracle Parameters?
Title: RE: Win2k Perl accessing Oracle Parameters? Thanks for the input, both of you!!! -Original Message- From: Jared Still [mailto:[EMAIL PROTECTED]] Sent: Tuesday, October 29, 2002 5:35 PM To: Multiple recipients of list ORACLE-L Subject: Re: Win2k Perl accessing Oracle Parameters? In addition to BIshop's excellent response, be sure to install the latest version of Tie:Registry. The one that comes with ActiveState Perl doesn't work properly. The current version (as installed from ActiveState via PPM) is I believe 1.24. Just reinstall it. Jared On Tuesday 29 October 2002 01:53, Bishop Lewis wrote: Here's something to read registry keys I used a while back. Obviously needs the win32 module installed. use Win32::Registry; $terminal = $ARGV[0]; $HKEY_LOCAL_MACHINE-Connect ($terminal, $hNode) || die Cannot connect to $node; $hNode-Open (SOFTWARE\\Microsoft\\Windows NT\\CurrentVersion\\Winlogon, $hKey) || die Cannot open registry !; $hKey-GetValues (\%values); $hKey-Close (); $hNode-Close (); foreach $value (keys(%values)) { $RegType = $values{$value}-[1]; $RegValue = $values{$value}-[2]; $RegKey = $values{$value}-[0]; if ($RegKey eq DefaultUserName) {$username = $RegValue; print $RegValue\n; } } exit; Modify accordingly. HTH. Lewis Bishop --- Barclays Enable - ISS - E-NTRUST/Bexleyheath NT Oracle Database Consultant Watling Street, Bexleyheath, Kent, DA6 7RR (Mail Van R) Phone : 020 8298 3418 Mobile: 07950 380857 Email : [EMAIL PROTECTED] Enabling Competitive Advantage for Barclays in IT and Business Processing -Original Message- Sent: 29 October 2002 08:43 To: Multiple recipients of list ORACLE-L This header confirms that this email message has been swept for the presence of computer viruses. Corporate IT THE WOOLWICH -- Hello All, I am writing an perl script. I cann't figure out and have been going through the docs, but cann't find exactly what I need. A way to access Oracle Parameters as they are set up in the Win2k registary. I am specifically thinking of ORACLE_HOME. I do know how to obtain an environmental variable/parameter with $ENV{}. But the ORACLE_HOME is not an environmental parameter per se. I have a workaround by setting it up in the enviroment, however I would like to write this script with the aim at it being machine unspecific. (Jared, hope you can answer me on this. Want to get a copy of your book, unfortunately with the exchange rate and import taxes etc it will cost me R590,00. Quiet a chunk of the ole budget, maybe early next year.) Regards Denham Eva Oracle DBA UNIX is basically a simple operating system, but you have to be a genius to understand the simplicity. Dennis Ritchie. _ DISCLAIMER This message is for the named person's use only. It may contain confidential, proprietary or legally privileged information. No confidentiality or privilege is waived or lost by any mistransmission. If you receive this message in error, please immediately delete it and all copies of it from your system, destroy any hard copies of it and notify the sender. You must not, directly or indirectly, use, disclose, distribute, print, or copy any part of this message if you are not the intended recipient. TFMC, its holding company, and any of its subsidiaries each reserve the right to monitor and manage all e-mail communications through its networks. Any views expressed in this message are those of the individual sender, except where the message states otherwise and the sender is authorized to state them to be views of any such entity. _ _ This e-mail message has been scanned for Viruses and Content and cleared by MailMarshal - For more information please visit http://www.marshalsoftware.com www.marshalsoftware.com _ --_=_NextPart_001_01C27F2F.5CF0F180 Content-Type: text/html Content-Transfer-Encoding: quoted-printable !DOCTYPE HTML PUBLIC -//W3C//DTD HTML 3.2//EN html xmlns:v=3Durn:schemas-microsoft-com:vml = xmlns:o=3Durn:schemas-microsoft-com:office:office = xmlns:w=3Durn:schemas-microsoft-com:office:word = xmlns:st1=3Durn:schemas-microsoft-com:office:smarttags = xmlns=3Dhttp://www.w3.org/TR/REC-html40 head META HTTP-EQUIV=3DContent-Type CONTENT=3Dtext/html; = charset=3Dus-ascii meta name=3DProgId content=3DWord.Document meta name=3DGenerator content=3DMicrosoft Word 10 meta name=3DOriginator content=3DMicrosoft Word 10 link rel=3DFile-List href="3Dcid:[EMAIL PROTECTED] link rel=3DEdit-Time-Data href="3Dcid:[EMAIL PROTECTED] !--[if !mso] style v\:* {behavior:url(#default#VML);} o\:* {behavior:url(#default#VML);} w\:* {behavior:url(#default#VML);} .shape {behavior:url(#default#VML);} /style ![endif]-- titleWin2k Perl accessing Oracle Parameters?/title o:SmartTagType = namespaceuri=3Durn:schemas-microsoft-com:office:smarttags name=3Ddate/ o:Sm
RE: Win2k Perl accessing Oracle Parameters?
Here's something to read registry keys I used a while back. Obviously needs the win32 module installed. use Win32::Registry; $terminal = $ARGV[0]; $HKEY_LOCAL_MACHINE-Connect ($terminal, $hNode) || die Cannot connect to $node; $hNode-Open (SOFTWARE\\Microsoft\\Windows NT\\CurrentVersion\\Winlogon, $hKey) || die Cannot open registry !; $hKey-GetValues (\%values); $hKey-Close (); $hNode-Close (); foreach $value (keys(%values)) { $RegType = $values{$value}-[1]; $RegValue = $values{$value}-[2]; $RegKey = $values{$value}-[0]; if ($RegKey eq DefaultUserName) {$username = $RegValue; print $RegValue\n; } } exit; Modify accordingly. HTH. Lewis Bishop --- Barclays Enable - ISS - E-NTRUST/Bexleyheath NT Oracle Database Consultant Watling Street, Bexleyheath, Kent, DA6 7RR (Mail Van R) Phone : 020 8298 3418 Mobile: 07950 380857 Email : [EMAIL PROTECTED] Enabling Competitive Advantage for Barclays in IT and Business Processing -Original Message- Sent: 29 October 2002 08:43 To: Multiple recipients of list ORACLE-L This header confirms that this email message has been swept for the presence of computer viruses. Corporate IT THE WOOLWICH -- Hello All, I am writing an perl script. I cann't figure out and have been going through the docs, but cann't find exactly what I need. A way to access Oracle Parameters as they are set up in the Win2k registary. I am specifically thinking of ORACLE_HOME. I do know how to obtain an environmental variable/parameter with $ENV{}. But the ORACLE_HOME is not an environmental parameter per se. I have a workaround by setting it up in the enviroment, however I would like to write this script with the aim at it being machine unspecific. (Jared, hope you can answer me on this. Want to get a copy of your book, unfortunately with the exchange rate and import taxes etc it will cost me R590,00. Quiet a chunk of the ole budget, maybe early next year.) Regards Denham Eva Oracle DBA UNIX is basically a simple operating system, but you have to be a genius to understand the simplicity. Dennis Ritchie. _ DISCLAIMER This message is for the named person's use only. It may contain confidential, proprietary or legally privileged information. No confidentiality or privilege is waived or lost by any mistransmission. If you receive this message in error, please immediately delete it and all copies of it from your system, destroy any hard copies of it and notify the sender. You must not, directly or indirectly, use, disclose, distribute, print, or copy any part of this message if you are not the intended recipient. TFMC, its holding company, and any of its subsidiaries each reserve the right to monitor and manage all e-mail communications through its networks. Any views expressed in this message are those of the individual sender, except where the message states otherwise and the sender is authorized to state them to be views of any such entity. _ _ This e-mail message has been scanned for Viruses and Content and cleared by MailMarshal - For more information please visit http://www.marshalsoftware.com www.marshalsoftware.com _ --_=_NextPart_001_01C27F2F.5CF0F180 Content-Type: text/html Content-Transfer-Encoding: quoted-printable !DOCTYPE HTML PUBLIC -//W3C//DTD HTML 3.2//EN html xmlns:v=3Durn:schemas-microsoft-com:vml = xmlns:o=3Durn:schemas-microsoft-com:office:office = xmlns:w=3Durn:schemas-microsoft-com:office:word = xmlns:st1=3Durn:schemas-microsoft-com:office:smarttags = xmlns=3Dhttp://www.w3.org/TR/REC-html40; head META HTTP-EQUIV=3DContent-Type CONTENT=3Dtext/html; = charset=3Dus-ascii meta name=3DProgId content=3DWord.Document meta name=3DGenerator content=3DMicrosoft Word 10 meta name=3DOriginator content=3DMicrosoft Word 10 link rel=3DFile-List href=3Dcid:filelist.xml;01C27F2F.66CF0930 link rel=3DEdit-Time-Data href=3Dcid:editdata.mso;01C27F2F.66CF0930 !--[if !mso] style v\:* {behavior:url(#default#VML);} o\:* {behavior:url(#default#VML);} w\:* {behavior:url(#default#VML);} .shape {behavior:url(#default#VML);} /style ![endif]-- titleWin2k Perl accessing Oracle Parameters?/title o:SmartTagType = namespaceuri=3Durn:schemas-microsoft-com:office:smarttags name=3Ddate/ o:SmartTagType = namespaceuri=3Durn:schemas-microsoft-com:office:smarttags name=3Dtime/ o:SmartTagType = namespaceuri=3Durn:schemas-microsoft-com:office:smarttags name=3Dplace/ o:SmartTagType = namespaceuri=3Durn:schemas-microsoft-com:office:smarttags name=3DPostalCode/ o:SmartTagType = namespaceuri=3Durn:schemas-microsoft-com:office:smarttags name=3DCity/ !--[if gte mso 9]xml o:OfficeDocumentSettings o:DoNotRelyOnCSS/ /o:OfficeDocumentSettings /xml![endif]--!--[if gte mso 9]xml w:WordDocument w:SpellingStateClean/w:SpellingState w:GrammarStateClean/w:GrammarState w:DocumentKindDocumentEmail/w:DocumentKind w:EnvelopeVis/
Re: Win2k Perl accessing Oracle Parameters?
In addition to BIshop's excellent response, be sure to install the latest version of Tie:Registry. The one that comes with ActiveState Perl doesn't work properly. The current version (as installed from ActiveState via PPM) is I believe 1.24. Just reinstall it. Jared On Tuesday 29 October 2002 01:53, Bishop Lewis wrote: Here's something to read registry keys I used a while back. Obviously needs the win32 module installed. use Win32::Registry; $terminal = $ARGV[0]; $HKEY_LOCAL_MACHINE-Connect ($terminal, $hNode) || die Cannot connect to $node; $hNode-Open (SOFTWARE\\Microsoft\\Windows NT\\CurrentVersion\\Winlogon, $hKey) || die Cannot open registry !; $hKey-GetValues (\%values); $hKey-Close (); $hNode-Close (); foreach $value (keys(%values)) { $RegType = $values{$value}-[1]; $RegValue = $values{$value}-[2]; $RegKey = $values{$value}-[0]; if ($RegKey eq DefaultUserName) {$username = $RegValue; print $RegValue\n; } } exit; Modify accordingly. HTH. Lewis Bishop --- Barclays Enable - ISS - E-NTRUST/Bexleyheath NT Oracle Database Consultant Watling Street, Bexleyheath, Kent, DA6 7RR (Mail Van R) Phone : 020 8298 3418 Mobile: 07950 380857 Email : [EMAIL PROTECTED] Enabling Competitive Advantage for Barclays in IT and Business Processing -Original Message- Sent: 29 October 2002 08:43 To: Multiple recipients of list ORACLE-L This header confirms that this email message has been swept for the presence of computer viruses. Corporate IT THE WOOLWICH -- Hello All, I am writing an perl script. I cann't figure out and have been going through the docs, but cann't find exactly what I need. A way to access Oracle Parameters as they are set up in the Win2k registary. I am specifically thinking of ORACLE_HOME. I do know how to obtain an environmental variable/parameter with $ENV{}. But the ORACLE_HOME is not an environmental parameter per se. I have a workaround by setting it up in the enviroment, however I would like to write this script with the aim at it being machine unspecific. (Jared, hope you can answer me on this. Want to get a copy of your book, unfortunately with the exchange rate and import taxes etc it will cost me R590,00. Quiet a chunk of the ole budget, maybe early next year.) Regards Denham Eva Oracle DBA UNIX is basically a simple operating system, but you have to be a genius to understand the simplicity. Dennis Ritchie. _ DISCLAIMER This message is for the named person's use only. It may contain confidential, proprietary or legally privileged information. No confidentiality or privilege is waived or lost by any mistransmission. If you receive this message in error, please immediately delete it and all copies of it from your system, destroy any hard copies of it and notify the sender. You must not, directly or indirectly, use, disclose, distribute, print, or copy any part of this message if you are not the intended recipient. TFMC, its holding company, and any of its subsidiaries each reserve the right to monitor and manage all e-mail communications through its networks. Any views expressed in this message are those of the individual sender, except where the message states otherwise and the sender is authorized to state them to be views of any such entity. _ _ This e-mail message has been scanned for Viruses and Content and cleared by MailMarshal - For more information please visit http://www.marshalsoftware.com www.marshalsoftware.com _ --_=_NextPart_001_01C27F2F.5CF0F180 Content-Type: text/html Content-Transfer-Encoding: quoted-printable !DOCTYPE HTML PUBLIC -//W3C//DTD HTML 3.2//EN html xmlns:v=3Durn:schemas-microsoft-com:vml = xmlns:o=3Durn:schemas-microsoft-com:office:office = xmlns:w=3Durn:schemas-microsoft-com:office:word = xmlns:st1=3Durn:schemas-microsoft-com:office:smarttags = xmlns=3Dhttp://www.w3.org/TR/REC-html40; head META HTTP-EQUIV=3DContent-Type CONTENT=3Dtext/html; = charset=3Dus-ascii meta name=3DProgId content=3DWord.Document meta name=3DGenerator content=3DMicrosoft Word 10 meta name=3DOriginator content=3DMicrosoft Word 10 link rel=3DFile-List href=3Dcid:filelist.xml;01C27F2F.66CF0930 link rel=3DEdit-Time-Data href=3Dcid:editdata.mso;01C27F2F.66CF0930 !--[if !mso] style v\:* {behavior:url(#default#VML);} o\:* {behavior:url(#default#VML);} w\:* {behavior:url(#default#VML);} .shape {behavior:url(#default#VML);} /style ![endif]-- titleWin2k Perl accessing Oracle Parameters?/title o:SmartTagType = namespaceuri=3Durn:schemas-microsoft-com:office:smarttags name=3Ddate/ o:SmartTagType = namespaceuri=3Durn:schemas-microsoft-com:office:smarttags name=3Dtime/ o:SmartTagType = namespaceuri=3Durn:schemas-microsoft-com:office:smarttags name=3Dplace/ o:SmartTagType = namespaceuri=3Durn:schemas-microsoft-com:office:smarttags name=3DPostalCode/
RE: Win2k Perl accessing Oracle Parameters?
Jared: PPM search Tie::Registry PPM search Win32::Registry Packages available from http://ppm.ActiveState.com/cgibin/PPM/ppmserver.pl?urn:/ PPMServer: Win32-Registry-File [1.09] Perl interface to MS-Windows registry files. PPM Is 1.09 really what I want to install? Cary Millsap Hotsos Enterprises, Ltd. http://www.hotsos.com Upcoming events: - Hotsos Clinic, Dec 9-11 Honolulu - 2003 Hotsos Symposium on OracleR System Performance, Feb 9-12 Dallas - Jonathan Lewis' Optimising Oracle, Nov 19-21 Dallas -Original Message- Still Sent: Tuesday, October 29, 2002 9:35 AM To: Multiple recipients of list ORACLE-L In addition to BIshop's excellent response, be sure to install the latest version of Tie:Registry. The one that comes with ActiveState Perl doesn't work properly. The current version (as installed from ActiveState via PPM) is I believe 1.24. Just reinstall it. Jared On Tuesday 29 October 2002 01:53, Bishop Lewis wrote: Here's something to read registry keys I used a while back. Obviously needs the win32 module installed. use Win32::Registry; $terminal = $ARGV[0]; $HKEY_LOCAL_MACHINE-Connect ($terminal, $hNode) || die Cannot connect to $node; $hNode-Open (SOFTWARE\\Microsoft\\Windows NT\\CurrentVersion\\Winlogon, $hKey) || die Cannot open registry !; $hKey-GetValues (\%values); $hKey-Close (); $hNode-Close (); foreach $value (keys(%values)) { $RegType = $values{$value}-[1]; $RegValue = $values{$value}-[2]; $RegKey = $values{$value}-[0]; if ($RegKey eq DefaultUserName) {$username = $RegValue; print $RegValue\n; } } exit; Modify accordingly. HTH. Lewis Bishop --- Barclays Enable - ISS - E-NTRUST/Bexleyheath NT Oracle Database Consultant Watling Street, Bexleyheath, Kent, DA6 7RR (Mail Van R) Phone : 020 8298 3418 Mobile: 07950 380857 Email : [EMAIL PROTECTED] Enabling Competitive Advantage for Barclays in IT and Business Processing -Original Message- Sent: 29 October 2002 08:43 To: Multiple recipients of list ORACLE-L This header confirms that this email message has been swept for the presence of computer viruses. Corporate IT THE WOOLWICH -- Hello All, I am writing an perl script. I cann't figure out and have been going through the docs, but cann't find exactly what I need. A way to access Oracle Parameters as they are set up in the Win2k registary. I am specifically thinking of ORACLE_HOME. I do know how to obtain an environmental variable/parameter with $ENV{}. But the ORACLE_HOME is not an environmental parameter per se. I have a workaround by setting it up in the enviroment, however I would like to write this script with the aim at it being machine unspecific. (Jared, hope you can answer me on this. Want to get a copy of your book, unfortunately with the exchange rate and import taxes etc it will cost me R590,00. Quiet a chunk of the ole budget, maybe early next year.) Regards Denham Eva Oracle DBA UNIX is basically a simple operating system, but you have to be a genius to understand the simplicity. Dennis Ritchie. _ DISCLAIMER This message is for the named person's use only. It may contain confidential, proprietary or legally privileged information. No confidentiality or privilege is waived or lost by any mistransmission. If you receive this message in error, please immediately delete it and all copies of it from your system, destroy any hard copies of it and notify the sender. You must not, directly or indirectly, use, disclose, distribute, print, or copy any part of this message if you are not the intended recipient. TFMC, its holding company, and any of its subsidiaries each reserve the right to monitor and manage all e-mail communications through its networks. Any views expressed in this message are those of the individual sender, except where the message states otherwise and the sender is authorized to state them to be views of any such entity. _ _ This e-mail message has been scanned for Viruses and Content and cleared by MailMarshal - For more information please visit http://www.marshalsoftware.com www.marshalsoftware.com _ --_=_NextPart_001_01C27F2F.5CF0F180 Content-Type: text/html Content-Transfer-Encoding: quoted-printable !DOCTYPE HTML PUBLIC -//W3C//DTD HTML 3.2//EN html xmlns:v=3Durn:schemas-microsoft-com:vml = xmlns:o=3Durn:schemas-microsoft-com:office:office = xmlns:w=3Durn:schemas-microsoft-com:office:word = xmlns:st1=3Durn:schemas-microsoft-com:office:smarttags = xmlns=3Dhttp://www.w3.org/TR/REC-html40; head META HTTP-EQUIV=3DContent-Type CONTENT=3Dtext/html; = charset=3Dus-ascii meta name=3DProgId content=3DWord.Document meta name=3DGenerator content=3DMicrosoft Word 10 meta name=3DOriginator content=3DMicrosoft Word 10 link rel=3DFile-List href=3Dcid:filelist.xml;01C27F2F.66CF0930 link rel=3DEdit-Time-Data
RE: Win2k Perl accessing Oracle Parameters?
Cary, Here's what my search of Registry revealed: PPM search Registry Packages available from http://ppm.ActiveState.com/cgibin/PPM/ppmserver.pl?urn:/PPMServer: Win32-Registry-File [1.09] Perl interface to MS-Windows registry files. Win32-TieRegistry [0.24] Powerful and easy ways to manipulate a registry [on Win32 for now]. Win32-TieRegistry-Dump [0.03] dump Win32 registry tree Win32-TieRegistry-PMVersionInfo [0.2 ] store in Win32 Registry PM $VERSION info XML-Registry[0.02] Perl module for loading and saving an XML registry. PPM The version that usually comes with ActiveState Perl is 0.23, not 1.23 as I implied before. The version you want is version 0.24. HTH Jared Cary Millsap [EMAIL PROTECTED] Sent by: [EMAIL PROTECTED] 10/29/2002 09:13 AM Please respond to ORACLE-L To: Multiple recipients of list ORACLE-L [EMAIL PROTECTED] cc: Subject:RE: Win2k Perl accessing Oracle Parameters? Jared: PPM search Tie::Registry PPM search Win32::Registry Packages available from http://ppm.ActiveState.com/cgibin/PPM/ppmserver.pl?urn:/ PPMServer: Win32-Registry-File [1.09] Perl interface to MS-Windows registry files. PPM Is 1.09 really what I want to install? Cary Millsap Hotsos Enterprises, Ltd. http://www.hotsos.com Upcoming events: - Hotsos Clinic, Dec 9-11 Honolulu - 2003 Hotsos Symposium on OracleR System Performance, Feb 9-12 Dallas - Jonathan Lewis' Optimising Oracle, Nov 19-21 Dallas -Original Message- Still Sent: Tuesday, October 29, 2002 9:35 AM To: Multiple recipients of list ORACLE-L In addition to BIshop's excellent response, be sure to install the latest version of Tie:Registry. The one that comes with ActiveState Perl doesn't work properly. The current version (as installed from ActiveState via PPM) is I believe 1.24. Just reinstall it. Jared On Tuesday 29 October 2002 01:53, Bishop Lewis wrote: Here's something to read registry keys I used a while back. Obviously needs the win32 module installed. use Win32::Registry; $terminal = $ARGV[0]; $HKEY_LOCAL_MACHINE-Connect ($terminal, $hNode) || die Cannot connect to $node; $hNode-Open (SOFTWARE\\Microsoft\\Windows NT\\CurrentVersion\\Winlogon, $hKey) || die Cannot open registry !; $hKey-GetValues (\%values); $hKey-Close (); $hNode-Close (); foreach $value (keys(%values)) { $RegType = $values{$value}-[1]; $RegValue = $values{$value}-[2]; $RegKey = $values{$value}-[0]; if ($RegKey eq DefaultUserName) {$username = $RegValue; print $RegValue\n; } } exit; Modify accordingly. HTH. Lewis Bishop --- Barclays Enable - ISS - E-NTRUST/Bexleyheath NT Oracle Database Consultant Watling Street, Bexleyheath, Kent, DA6 7RR (Mail Van R) Phone : 020 8298 3418 Mobile: 07950 380857 Email : [EMAIL PROTECTED] Enabling Competitive Advantage for Barclays in IT and Business Processing -Original Message- Sent: 29 October 2002 08:43 To: Multiple recipients of list ORACLE-L This header confirms that this email message has been swept for the presence of computer viruses. Corporate IT THE WOOLWICH -- Hello All, I am writing an perl script. I cann't figure out and have been going through the docs, but cann't find exactly what I need. A way to access Oracle Parameters as they are set up in the Win2k registary. I am specifically thinking of ORACLE_HOME. I do know how to obtain an environmental variable/parameter with $ENV{}. But the ORACLE_HOME is not an environmental parameter per se. I have a workaround by setting it up in the enviroment, however I would like to write this script with the aim at it being machine unspecific. (Jared, hope you can answer me on this. Want to get a copy of your book, unfortunately with the exchange rate and import taxes etc it will cost me R590,00. Quiet a chunk of the ole budget, maybe early next year.) Regards Denham Eva Oracle DBA UNIX is basically a simple operating system, but you have to be a genius to understand the simplicity. Dennis Ritchie. _ DISCLAIMER This message is for the named person's use only. It may contain confidential, proprietary or legally privileged information. No confidentiality or privilege is waived or lost by any mistransmission. If you receive this message in error, please immediately delete it and all copies of it from your system, destroy any hard copies of it and notify the sender. You must not, directly or indirectly, use, disclose, distribute, print, or copy any part of this message if you are not the intended recipient. TFMC, its holding company, and any of its subsidiaries each reserve the right to monitor and manage all e-mail communications through its networks. Any views expressed in this message