Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Mailing Lists -> Oracle-L -> RE: PERL?

RE: PERL?

From: Yong Huang <yong321_at_yahoo.com>
Date: Wed, 10 Dec 2003 07:39:33 -0800
Message-ID: <F001.005D9708.20031210073933@fatcity.com>


Dan,

If I were to use Expect.pm in Perl, I would program in Expect directly. If we can have one less layer of wrapping, why not? On the other hand, sqlplus is not an application that insists on terminal input as telnet does. So you can use a shell here document or coprocess to talk to it; Expect is an overkill. (Some people use Expect to simply ftp files without knowing that ftp -n allows you to use a here document; an Expect ftp script is necessary only if you need to respond differently to each of the ftp errors).

Yong Huang

Daniel Hanks wrote:

I think Perl with Expect.pm could likely do this without much effort. Expect allows you to interact with just about anything that uses a terminal. One fun case comes to mind. We have this LED sign (think large rectangular array of LEDs), with an undocumented serial interface protocol. All that came with it to control it was this old DOS program which would talk to the sign over a serial port. So I whipped up a Perl script which used Expect to interact with dosemu (a Linux DOS emulator) to run the program, which interacted with the sign, all running on Linux. Works pretty good.

Expect.pm is also nice to interact with network hardware that offers telnet/shell command interfaces. Interacting with sqlplus via Expect.pm would be pretty easy as well, I would think. It basically works like this:


Do you Yahoo!?
New Yahoo! Photos - easier uploading and sharing. http://photos.yahoo.com/
-- 
Please see the official ORACLE-L FAQ: http://www.orafaq.net
-- 
Author: Yong Huang
  INET: yong321_at_yahoo.com

Fat City Network Services    -- 858-538-5051 http://www.fatcity.com
San Diego, California        -- Mailing list and web hosting services
---------------------------------------------------------------------
To REMOVE yourself from this mailing list, send an E-Mail message
to: ListGuru_at_fatcity.com (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).
Received on Wed Dec 10 2003 - 09:39:33 CST

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US