COMPGROUPS.NET | Search | Post Question | Groups | Stream | About | Register

### PL/Perl: when to set @INC?

• Email
• Follow

This is a question about PL/Perl, PostgreSQL's Perl procedural
language.

I have a database where I want to make heavy use of PL/Perl stored
procedures.  Also, I'd like these procedures to be able to load
Perl modules that reside outside the paths in the default @INC, so
I'd like to modify @INC appropriately as soon as possible after
the PostgreSQL server is started.

Does anyone know how to do this?

TIA!

Kynn

--
NOTE: In my address everything before the first period is backwards;
and the last period, and everything after it, should be discarded.
 0
Reply kj 2/23/2008 10:12:24 PM

See related articles to this posting

kj <socyl@987jk.com.invalid> wrote:

> I'd like these procedures to be able to load
> Perl modules that reside outside the paths in the default @INC, so
> I'd like to modify @INC appropriately as soon as possible after
> the PostgreSQL server is started.
>
> Does anyone know how to do this?

perldoc -q INC

How do I add a directory to my include path (@INC) at runtime?

--
email: perl -le "print scalar reverse qq/moc.noitatibaher\100cmdat/"
 0

>kj <socyl@987jk.com.invalid> wrote:

>> I'd like these procedures to be able to load
>> Perl modules that reside outside the paths in the default @INC, so
>> I'd like to modify @INC appropriately as soon as possible after
>> the PostgreSQL server is started.
>>
>> Does anyone know how to do this?

>    perldoc -q INC

>        How do I add a directory to my include path (@INC) at runtime?

Not what I was trying to find out, but maybe this is not the right
forum for my question...  My apologies.

kynn
--
NOTE: In my address everything before the first period is backwards;
and the last period, and everything after it, should be discarded.
 0
Reply kj 2/24/2008 5:08:53 PM

2 Replies
53 Views

Similar Articles

12/10/2013 9:38:36 PM
page loaded in 93238 ms. (0)

Similar Artilces:

duplicates in @INC
Hi, perl -le 'print join "\n", @INC' shows me this: /usr/lib/perl5/5.8.0/i386-linux-thread-multi /usr/lib/perl5/5.8.0 /usr/lib/perl5/site_perl/5.8.0/i386-linux-thread-multi /usr/lib/perl5/site_perl/5.8.0 /usr/lib/perl5/site_perl /usr/lib/perl5/vendor_perl/5.8.0/i386-linux-thread-multi /usr/lib/perl5/vendor_perl/5.8.0 /usr/lib/perl5/vendor_perl /usr/lib/perl5/5.8.0/i386-linux-thread-multi /usr/lib/perl5/5.8.0 . See the first 2 search paths and the last 2 ( before the . ) are duplicates and I want to remove the duplicate...

Perl and Linux
The ActiveState version of Perl runs quite well with Windows. Can anyone comment on how well it runs with Linux? Is Linux actually the preferred operating system for Perl? Or might that be Unix? On Sat, 22 Jan 2011 17:16:44 -0600, E.D.G. wrote: > The ActiveState version of Perl runs quite well with Windows. Can > anyone comment on how well it runs with Linux? Almost all distributions of Linux come with a recent version of Perl. (If they don't, they're either really specialized or a fringe distribution). > Is Linux actually the preferred operating syst...

memoir: setting the margins
hello here is a MWE with memoir class <MWE> \documentclass[a4paper,12pt,article]{memoir} \usepackage{fixltx2e} \usepackage[french]{babel} \usepackage[T1]{fontenc} \usepackage[latin9]{inputenc} \usepackage{microtype} \usepackage{lmodern} \usepackage{lipsum} %%%%% classe MEMOIR \settypeblocksize{25.7cm}{17cm}{*} \setlrmargins{2cm}{*}{*} \setulmargins{2cm}{*}{*} \begin{document} \lipsum \end{document} </MWE> I would like to have all four margins equal to 2cm. Obviously, I'm missing something :( Any hint appreciated many thanks in advance -- Le TeXnicien de surface Le TeXni...

Perl question 66993
I have a file name result01182006.xml which is named according to the date. I know how to split it to get the values $a = "result01182006.xml";$a =~ /^(result)(\d{2})(\d{2})(\d{4})/; print "$1$2 $3$4\n"; In the contents of this file i I need to replace every instance of 1/7/2006 to 01/18/2006. Change the date of "Sat 07 Jan 2006" to corresponding day which 01/18/2006 falls on, so it should be changed to "Wed 18 Jan 2006 and change the string result01072006 to result01182006 Please can somebody help here.. Working on no sleep whatsover in 24 hrs. Sib...

setting up my own POP3 server
Hi, I am trying to learn about POP3 servers. Sorry for wasting bandwidth with a stupid question, but I am fairly new and naive on Internet topics... I found this toy POP3 server: http://code.activestate.com/recipes/534131. I start that server on my Windows XP machine: python pop_server.py 110 message.txt and I get: pypopper INFO - pypopper POP3 serving 'message.txt' on localhost: 110 I then try to have my gmail account retrieve my "mail" (= the contents of message.txt) on that server. In order to do that, in gmail, I select "Settings", then...

equivalent of perl qw operator
I have a feeling I've seen it in the pickaxe book but I can't seem to find it again. Is there a way to write this differently? array = [ 'element1', 'element2', ...] In perl I could do @array = qw( element1 element2 ...) without the quotes. thanks vlad Page 15 of the Pick Axe book, as a matter of fact. It's %w{ } -Augie On 4/11/07, Vlad Ciubotariu <vcciubot@uwaterloo.ca> wrote: > I have a feeling I've seen it in the pickaxe book but I can't seem to find > it again. > > Is there a way to write this differently? > > array = [ ...

/dev/video settings question
I grab images by opening /dev/video (a PCI BT848 device) and issuing ioctl () calls (and a mmap() call), but after bootup it doesn't work because the capabilities height and width are wrong - ({576, 924} instead of the correct values {480, 768}). By running the "tvtime" program, these somehow are changed and everything works. How do I do it with ioctls()? There does not appear to be a VIDIOCSCAP defined? I use SuSE 9.1 kernel 2.6. -Mike Mike wrote: > I grab images by opening /dev/video (a PCI BT848 device) and issuing > ioctl () calls (and a mmap() call), but after boo...

generating perl code from awk
Hi, I have rather simple awk script which I would like to convert to Perl. I am using a2p but unfortunately it gives me a syntax error. ---- syntax error in file tntvenn.awk at line 22 Translation aborted due to syntax errors. ---- for ( char in chars ) { common = 1 ; out = "" for ( name in names ) => if ( (name,char) in data ) out = out char ": " data[name,char] "\n" else common = 0 if ( common ) print out } } Line 22 is the line starting with => Any clues as to what's problem? Thanks, -F ...

Setting focus to an external application
I have contained in a listbox the Window's caption, the class name for the window, and the hWND of the window. Is there a way, using the data from above, to activate/set focus to that window? One assumes you could use this API function: Private Declare Function SetFocus Lib "user32" _ (ByVal hwnd As Long) As Long however, depending on the circumstances you may have to declare it using an alias so that your code does not confuse it with Access's SetFocus. Salad, Are you looking to do something like this ---- Dim AccessAppExtDb As Application Dim DbCurrentDatabase A...

set width of columns in layoutmanager
Hi, I hope you can help me... How do i change the widths of the columns in my gridlayout? i have a 9x9 grid and i want the outer 8 to be small, the the centre cell large, so i need to set the top and bottom row heights to small, and the left and right column widths to small. How can i achieve this? Thanks!!! :) Anrew Andrew Bullock wrote: > > How do i change the widths of the columns in my gridlayout? > i have a 9x9 grid and i want the outer 8 to be small, the the centre > cell large, so i need to set the top and bottom row heights to small, > and the left and rig...

C64 Rom set authors
Who wrote the software for the C64 roms (including the 1541)? Names, history? Christian On Wed, 23 Jun 2004, Christian Lott wrote: > Who wrote the software for the C64 roms (including the 1541)? > > Names, history? I'm going to go out on a limb and say Fred Bowen was probably responsible for the 64 (and possibly the 1540/1541) kernel. When Bill Herd spoke in Louisville a few years back, he referred to Mr. Bowen as "the kernel-meister", and said he did the kernel in pretty much everything Commodore produced. The character ROM is from the VIC-20, whose characte...

help! perl proxy problem?
i'm trying to run cgi-perl on apache (mandrake linux). my httpd.conf snippet says: <IfDefine PERLPROXIED> RewriteEngine on RewriteRule ^proxy:.* - [F] RewriteRule ^(.*\/perl\/.*)$http://%{HTTP_HOST}:8200$1 [P] RewriteRule ^(.*\/cgi-perl\/.*)$http://%{HTTP_HOST}:8200$1 [P] </IfDefine> when trying to access my url via 67.9.187.201/perl/myperl.pl, i get a proxy error. the error log says: (111)Connection refused: proxy connect to 67.9.187.201 port 8200 failed i'm running the server behind a firewall. my lan ip address is: 192.168.0.1 do i need t...

Any 3270 emulation for perl yet?
I searched for a perl 3270 emulator several years ago, and could find none. I wound up using the s3270 emulator wrapped in a perl script. I've been searching again, and still do not see a perl based 3270 emulator. Since a perl 3270 emulator apparently still does not exist, I guess the question is why? It would seem a natural for perl, to connect to a 3270 and screen scrape, or whatever. -Thanks Fred <itfred@cdw.com> writes: > I've been searching again, and still do > not see a perl based 3270 emulator. Since a perl 3270 > emulator apparently still does not exi...

File | Open How to set view?
I select File | Open It ALWAYS defaults to the Thumbnail view. I would prefer the list or details view. It WAS defaulting to the list view until I had to replace my harddrive and reinstall. I've messed with all the Remember view stuff in Windows Explorer. No help there. I seem to remember there was a way to change this, but I've been digging with Google for the last hour and can't find it. Anyone know how to permanently set this? Thanks T.O. ...

setting margins in memoir style
I'm still new here ;) I have been told that the settings I was using: \setlength\topmargin{-0.25in} \setlength\evensidemargin{-0.25in} \setlength\textheight{8.5in} \setlength\textwidth{6.5in} I should really avoid, as I am using memoir. Fair enough. But in trying to use the settings in memoir, I have only achieved things that are absurd, with the foremargin disappearing, or the typeblock being too narrow. What I am trying to achieve is a printable width of 6.5 inches on a letterpaper sheet. The instructions above, though they may not have been the right approach, gave acceptable result...

How do I set or clear the Sign Flag?
I'm trying to draw pixels in GEOS and while I have no problem displaying text or bitmap graphics, and using the GraphicsString command, the DrawPoint requires the Sign Flag and Carry Flag to be set. I know SEC sets the Carry Flag, but how can I set the Sign Flag? Also, for those in the know, several Graphics routines ask you to set the Pattern Byte in a. I've tried several things and I'm not getting a solid line. You'd think 1 would give you a solid line, because pattern #1 is all black. Right now, if I draw a vertical line on the screen from scanline 199 to scanline 0...

Setting up virtual server with Nexland Pro400
Hey all, I can't seem to setup a virtual server with the Nexland Pro400. I've even tried "exposing" the internal server which has the webserver i'd like to see from the internet. No luck. Has anyone had this problem with this router/firewall before? If so, any help would be greatly appreciated. Please email david . best @ NO sympatico . SPAM .ca (remove the spaces and NO SPAM). Thanks On 28 Sep 2003 13:36:25 -0700, Dave spoketh >Hey all, > > I can't seem to setup a virtual server with the Nexland Pro400. >I've even tried "exposing&qu...

Perl OLE Excel
I try to calculate the standard deviation of average of C2:C35. But I get random range in the worksheet G$i. It's not showing as: D2 =STDEVA(C2:C35,D2) D3 =STDEVA(C2:C35,D3) ...... It's showing as: D2 =STDEVA(C2:C35,D2) D3 =STDEVA(C2:C31,D3) D4 =STDEVA(C2:C33,D4) ...... Any one know why? I tried with " " doesn't help and q { } show nothing since it's like ' '. Thanks. my$lastRowStd = 35; my $i=2; while($i<=$lastRowStd) {$Range = $CurrentSheet->Range("G$i"); $Range->{Value} = qq {=STDEVA(C2:C$lastRowStd,D$i)};$i++; } On F...

File type compatibility issue with Perl
Hey everyone, perhaps someone could shed some light on this issue. I'm writing a script that maintains an addressbook online with a Perl flatfile database. The script was working fine until I renamed the database files from ".txt". to ".db" All entries in the database are on separate lines. When the database had a ".txt" extension, and I viewed the data, all data appeared on separate lines as constructed. Name 1 Name 2 Name 3 When I renamed the extensions to ".db", the data appears on a single line. Name 1Name 2Name 3 Can anyone tell me why this ...

Windows Server 2003 Set-up Question
When it comes to Choosing a License Mode you have the option of choosing Per Server or Per Device/User. I know in Per Server you get 5 licenses standard, which really ends up only allowing 2 people to remote in at a time. Thus I was thinking of trying the Per User. Per User though means each User has to have a CAL. My question is does XP Prof. come with it's own CAL for accessing a 2003 Server? Thus enabling everyone to just use their own to connect instead of the servers. Or if I select Per User, does that mean I have to buy a CAL for each of my XP clients?? Please let me know. Thank...