03-08-2013
10 More Discussions You Might Find Interesting
1. UNIX for Dummies Questions & Answers
Hi,
I am using a query like below in my shell script :
{
{
echo "set echo off"
echo "set head off"
echo "whenever sqlerror exit -1;
select NUMBER ||','||
FNAME ||','||
LOC ||','||
... (2 Replies)
Discussion started by: deepakgang
2 Replies
2. Shell Programming and Scripting
Hi all,
Does anyone know how to format the output from mysql from within a shell script?
i.e.
RESULT=`mysql command`
echo ${RESULT}
the ${RESULT} only displays the output on one line instead of how mysql would display it as columns etc (3 Replies)
Discussion started by: muay_tb
3 Replies
3. Shell Programming and Scripting
a job extracts orcle data into unix as flat file.
a single record breaks into two record in unix flat file. This is the case only for 6 records out of 60 lack records.
(its not single record in two line. but its single record into record. ie., \n come into picture)
can you tell me what... (6 Replies)
Discussion started by: Gopal_Engg
6 Replies
4. UNIX for Dummies Questions & Answers
Hi,
I am very new to shell scripting and trying to write a simple shell script in which i am trying to achieve the following:
1. Connect to oracle database hosted on a different server
2. fire a query on the oracle db
3. store the output in a variable
4. use this variable for further logic... (1 Reply)
Discussion started by: shrutihardas
1 Replies
5. Shell Programming and Scripting
Hi,
I am very new to shell scripting and trying to write a simple shell script in which i am trying to achieve the following:
1. Connect to oracle database hosted on a different server
2. fire a query on the oracle db
3. store the output in a variable
4. use this variable for further logic... (26 Replies)
Discussion started by: shrutihardas
26 Replies
6. Shell Programming and Scripting
Hi
I have developed bash script to connect to database and execute .sql files. I am logging some statements in to log file using echo. While logging I am adding the date in front of the log statements which makes sense. I am unable to add date in front of output from the sqlplus and sqlldr,... (8 Replies)
Discussion started by: murtymvvs
8 Replies
7. Shell Programming and Scripting
Hello everyone,
I have a RHEL 5 system and have been trying to get a batch of 3-4 scripts each in a separate variables and they are not working as expected.
I tried using following syntax which I saw a lot of people on this site use and should really work, though for some reason it doesn't... (3 Replies)
Discussion started by: rockf1bull
3 Replies
8. Shell Programming and Scripting
Good afternoon!
I have been lurking in this forum for awhile now. I have just recently started posting. I think this is a really good site. With that being said, I don't like to just run and get an answer before I try my best first.
I have poured some blood, sweat and tears into... (4 Replies)
Discussion started by: brianjb
4 Replies
9. Shell Programming and Scripting
I have logged into oracle using SQLPLUS. When I type any kind of query, there is only 1 answer - '2'.
What is wrong with it? (1 Reply)
Discussion started by: Subhasis
1 Replies
10. UNIX for Beginners Questions & Answers
Hi,
I have some questions about sqlplus running from bash. I am still new and learning. I have the code shown below:
echo "exit" | sqlplus... (10 Replies)
Discussion started by: mohca2020
10 Replies
LEARN ABOUT DEBIAN
coro::lwp
LWP(3pm) User Contributed Perl Documentation LWP(3pm)
NAME
Coro::LWP - make LWP non-blocking - as much as possible
SYNOPSIS
use Coro::LWP; # afterwards LWP should not block
ALTERNATIVES
Over the years, a number of less-invasive alternatives have popped up, which you might find more acceptable than this rather invasive and
fragile module. All of them only support HTTP (and sometimes HTTPS).
AnyEvent::HTTP
Works fine without Coro. Requires using a very different API than LWP. Probably the best choice iff you can do with a completely
different event-based API.
LWP::Protocol::AnyEvent::http
Makes LWP use AnyEvent::HTTP. Does not make LWP event-based, but allows Coro threads to schedule unimpeded through its AnyEvent
integration.
Let's you use the LWP API normally.
LWP::Protocol::Coro::http
Basically the same as above, distinction unclear. :)
AnyEvent::HTTP::LWP::UserAgent
A different user agent implementation, not completely transparent to users, requires Coro.
DESCRIPTION
This module is an AnyEvent user, you need to make sure that you use and run a supported event loop.
This module tries to make LWP non-blocking with respect to other coroutines as much as possible, and with whatever means it takes.
LWP really tries very hard to be blocking (and relies on a lot of undocumented functionality in IO::Socket), so this module had to be very
invasive and must be loaded very early to take the proper effect.
Note that the module AnyEvent::HTTP might offer an alternative to the full LWP that is designed to be non-blocking.
Here is what it currently does (future versions of LWP might require different tricks):
It loads Coro::Select, overwriting the perl "select" builtin globally.
This is necessary because LWP calls select quite often for timeouts and who-knows-what.
Impact: everybody else uses this (slower) version of select, too. It should be quite compatible to perls builtin select, though.
It overwrites Socket::inet_aton with Coro::Util::inet_aton.
This is necessary because LWP might (and does) try to resolve hostnames this way.
Impact: some code might not expect coroutine semantics, for example, when you fork you might prefer the blocking variant because other
coroutines shouldn't actually run.
It replaces the base class of Net::HTTP, Net::FTP, Net::NNTP.
This is necessary because LWP does not always use select to see whether a filehandle can be read/written without blocking, so the base
class "IO::Socket::INET" needs to be replaced by "Coro::Socket".
Impact: Coro::Socket is not at all compatible to IO::Socket::INET. While it duplicates some undocumented functionality required by LWP,
it does not have all the methods of IO::Socket::INET and might act quite differently in practise. Also, protocols other than the above
mentioned will still block, at least some of the time.
All this likely makes other libraries than just LWP not block, but thats just a side effect you cannot rely on.
Increases parallelism is not supported by all libraries, some might cache data globally.
AUTHOR
Marc Lehmann <schmorp@schmorp.de>
http://home.schmorp.de/
perl v5.14.2 2012-04-13 LWP(3pm)