Re: leytonstone.pm
* Andy Mendelsohn ([EMAIL PROTECTED]) wrote: On Tuesday, June 24, 2003, at 08:17 pm, Andrew Beattie wrote: Andy Wardley wrote: I don't remember doing anything so embarrassing that I can't face the public humiliation. Such as this... http://www.reckites.com/naked/abw.jpg Andrew Actually, Andy, I apologise for drawing you into this mess. I was sure i had one of you too - but the only ones I can find are of Messrs. D.cross, L.Brocard and P.Makepeace. And the reserve price is... i believe embarassing pictures are best displayed 12'x8' via a projector ;-) -- Greg McCarroll http://www.mccarroll.org.uk/~gem/ jabber://[EMAIL PROTECTED] msn://[EMAIL PROTECTED]
Re: leytonstone.pm
Said I: I don't remember doing anything so embarrassing that I can't face the public humiliation. Andrew Beattie wrote: Such as this... http://www.reckites.com/naked/abw.jpg I am suitably embarrassed - just look at that bouffant hairstyle! (It was the salty water, honest) A Naked Buggier
Re: XSLT processor recommendations
Jonathan Stowe wrote: On Tue, 24 Jun 2003, Robin Berjon wrote: I second that, if the perl-xml list isn't informed of the status of various Perl XML projects, no one will be up to date :) There's way too much in this space for anyone to keep up... Well I have emailed the maintainer of the FAQ but I note that it hasn't been updated for more than a year either - so maybe the whole XML on Perl thing is going down the pan ... :-) Not quite! There are several maintainers of the FAQ iirc, making something known usually goes through the list (which is a friendly and active list -- I recommend it to anyone here who may have to deal with XML in Perl). -- Robin Berjon [EMAIL PROTECTED] Research Engineer, Expwayhttp://expway.fr/ 7FC0 6F5F D864 EFB8 08CE 8E74 58E6 D5DB 4889 2488
[JOB] Windows admin
Fotango is currently looking for a very skilled Windows admin. Please send CVs to me, and I'll forward them on. Leon -- Leon Brocard.http://www.astray.com/ scribot.http://www.scribot.com/ ... What's brown and sticky? A stick!
[OT] Places to go, people to see...
Dear Mongers, It so happens that I'm expecting a visit from a delightful foreign young lady next week, who's expecting me to show her England. I have eight days, no car, and not a great deal of cash. We'll be based in Fleet (near Basingstoke). I'm half considering going down Dorset way (should be easy to get to) and camping near there for a few days. Oxford is also on the agenda for a few days (being that I live there). Can anyone suggest anywhere else in the country, that's easy to get to, is very beautiful, and is worth going to visit/stay in? We're willing to camp or stay in a nice bed and breakfast, and we're both into The Great Big Outdoors (and both have bikes we can use) ... Ideas sincerely appreciated, including pub/restaurant/bb suggestions in the area... +Pete -- If you have built castles in the air, your work need not be lost; that is where they should be. Now put the foundations under them. -- Henry David Thoreau
Re: leytonstone.pm
Thanks Paul. You had to go and organise it on a night when I have a *different* Leytonstone pub meeting to go to. You couldn't have organised it in the Walnut Tree instead? well the Hitchcock is the nearest pub to me so my house *may* be the nearest. What a coincidence! I have been told that the Hitchcock has had really good chef's in the past but I don't know how good the food is now. As it is also a hotel I hope it should be quite good. I'm tempted to ask my Walnut tree sf fan friends to go to the Hitchcock instead. Alex At 15:11 24/06/03 +0100, Ian Malpass wrote: On Tue, 24 Jun 2003, Andy Mendelsohn wrote: So, in recognition of the fact that there are perl programmers who live in the swampland east of Stratford, but primarily as an excuse to drink beer in the convivial surroundings of 'The Hitchcock' on Whipps Cross Road, E11, Paul Makepeace and my own decrepit self will be holding the inaugural meeting of leytonstone.pm on July 8th. All welcome of course. I'll be there from around 7pm(ish). Good heavens. That's not five minutes[0] from mine own good home. How handy. July 8th you say? I shall do my best. Ian [0] Actually, it's probably ten minutes. Which, I'm sure you'll agree, is not five minutes. - -- The soul would have no rainbows if the eyes held no tears. Ian Malpass [EMAIL PROTECTED]
Re: [OT] Places to go, people to see...
Peter Sergeant said: Dear Mongers, I'm half considering going down Dorset way (should be easy to get to) and camping near there for a few days. Oxford is also on the agenda for a few days (being that I live there). Can anyone suggest anywhere else in the country, that's easy to get to, is very beautiful, and is worth going to visit/stay in? We're willing to camp or stay in a nice bed and breakfast, and we're both into The Great Big Outdoors (and both have bikes we can use) ... My home thoughts from abroad: i) If she's foreign you should take her to Warwick Castle (think that's what it was called) nice grounds and very pretty. You should be able to find a camp site in the area and also make your way down to Stratford upon avon, which is very pretty in the summer. Foriegn people love it. Actually get a National Trust guide.. ii) Peak district for something full on. iii) After I graduated, I went camping in the Isle of White with my housemate who was from Singapore. Highly recommended. It's small enough to travel around and has lots of pretty sites. Needles on the west coast, for instance, is a real adventure. Pretty clifs and you get to go down by cable car. You really get the feeling that you're exploring an exciting new land; since it's small and an 'island' there's a real sense of quaintness. Great beaches in the summer, super arcades. Nice camp sites. Small roads. Regular buses all over the island. Very green. It's really great for a cheap holiday. Good for hiking. Affordable camp sites. Nice theme park. Going with a friend is a real contrast to those family holidays and school trips, which you're forced to endure as a kid. iv) Actually the south coast, is my recommendation. Take her to 'klimping' I think it's called. It's a small beach, which you might find on a map, 'just' west of Brighton. There's a small pub and an untainted beach which is really nice. There is also a really expensive guest house, however I'm sure that you'll find camping facilities in the area.Very beautiful. Work your way westards into torquey and do more camping there. Holland is not quite the same. We don't have amusment arcades by the sea side. Very depressing. I loved them as a kid. Hated their intrusion on beaches as an adult. Now miss them as an expat. Take lots of pictures and publish them, for those of us who are starting to get home sick. Have fun. R.
Re: leytonstone.pm
On Wednesday, June 25, 2003, at 10:51 am, Alex McLintock wrote: Thanks Paul. You had to go and organise it on a night when I have a *different* Leytonstone pub meeting to go to. You couldn't have organised it in the Walnut Tree instead? Blame me for choosing the Hitchcock. I'm sure Paul would've suggested the Walnut Tree. I prefer the hitch and it's got nothing to do with the fact that all my son's mates hang out at the Walnut - honest! well the Hitchcock is the nearest pub to me so my house *may* be the nearest. What a coincidence! I have been told that the Hitchcock has had really good chef's in the past but I don't know how good the food is now. As it is also a hotel I hope it should be quite good. It has had both good and bad - at one stage it had an in-house chinese restaurant and at another, a chef/landlord who used to get so paralytic that he fell down the cellar stairs, broke a few bones and as a result pretty much killed off dining there for a few months. It's now owned and run by South Africans, so I expect there'll be a braai or somesuch weirdness. andy
Re: [OT] Places to go, people to see...
On Wed, Jun 25, 2003 at 11:06:37AM +0100, Raf wrote: iii) After I graduated, I went camping in the Isle of White with my ^ Pet peeve: Wight -- Lusercop.net - LARTing Lusers everywhere since 2002
[ANNOUNCE] Social Meet Thurs 3rd July @ Calthorpe + Tonight: Emerg Social
[ First up, remember there's an emergency social meeting tonight (Weds 25th June) details: http://london.pm.org/lpma/2003-June/59.html http://london.pm.org/lpma/2003-June/60.html ] The next London Perl Mongers social meeting will take place on Thursday 3rd July 2003 at the Calthorpe Arms pub, which is located roughly halfway between Chancery Lane and Kings Cross. This is the same venue for the previous meeting on the 8th of May; The Calthorpe Arms is located at 252 Grays Inn Road on the east side - full directions at the end of this mail. http://london.pm.org/meetings/locations/calthorpe.html http://www.streetmap.co.uk/streetmap.dll?G2M?X=530780Y=182355A=YZ=1 Social meetings give people a chance to meet up for a quiet drink. Everyone's welcome, from people that are hard core Perl hackers, to those that have never touched the language that just want to pop along for a drink. We're normally in the pub by 7pm (though some people turn up earlier, and some later,) and stay there until closing time. The Calthorpe serves food, so many people choose to eat there too. People ask that I put directions on these emails. Here they are, even though it should be obvious from the map how to find the pub - it's all very easy: From Kings Cross tube: Head south down Gray's Inn Road till you see the pub on your left on the corner of Wren Street shortly before Calthorpe Street. From Chancery Lane tube: Head north up Gray's Inn Road till you see a pub on your right, shortly after Calthorpe Street on the corner of Wren Street. From Russell Square tube: Turn right on exiting the tube station and at the end of the road turn right again onto Grenvil Street. This road ends shortly, and at the end turn left onto Guildford Street. Walk along to the end of this road where it crosses Gray's Inn Road and turns into Calthorpe Street. Turn left down Gray's Inn Road and on your right on the corner of Wren Street is the pub. I hope to see you there, where amongst other things we shall plot our trip to Paris, drink the Fullars beers, and quite possibly even have the odd conversation about programming. Mark. This email probably contains numerous errors: Corrections to [EMAIL PROTECTED] -- #!/usr/bin/perl -T use strict; use warnings; print q{Mark Fowler, [EMAIL PROTECTED], http://twoshortplanks.com/};
Re: [OT] Places to go, people to see...
On Wed, 2003-06-25 at 11:34, Lusercop wrote: On Wed, Jun 25, 2003 at 11:06:37AM +0100, Raf wrote: iii) After I graduated, I went camping in the Isle of White with my ^ Pet peeve: Wight Pet peeve: Shite
Re: [OT] Places to go, people to see...
Redvers Davies wrote: On Wed, 2003-06-25 at 11:34, Lusercop wrote: Pet peeve: Wight Pet peeve: Shite I used to have a pet peeve. It was always complaining. Cats are more friendly. ti'
Re: [OT] Places to go, people to see...
On Wed, Jun 25, 2003 at 11:46:28AM +, Redvers Davies wrote: On Wed, 2003-06-25 at 11:34, Lusercop wrote: On Wed, Jun 25, 2003 at 11:06:37AM +0100, Raf wrote: iii) After I graduated, I went camping in the Isle of White with my Pet peeve: Wight Pet peeve: Shite Depends whether or not you like sailing. I haven't been sailing in far too long. -- Lusercop.net - LARTing Lusers everywhere since 2002
Re: [OT] Places to go, people to see...
From: Peter Sergeant [EMAIL PROTECTED] Date: 6/25/03 9:14:20 AM Dear Mongers, It so happens that I'm expecting a visit from a delightful foreign young lady next week, who's expecting me to show her England. I have eight days, no car, and not a great deal of cash. We'll be based in Fleet (near Basingstoke). I'm half considering going down Dorset way (should be easy to get to) and camping near there for a few days. Oxford is also on the agenda for a few days (being that I live there). Can anyone suggest anywhere else in the country, that's easy to get to, is very beautiful, and is worth going to visit/stay in? We're willing to camp or stay in a nice bed and breakfast, and we're both into The Great Big Outdoors (and both have bikes we can use) ... Ideas sincerely appreciated, including pu Surely London is the only possible answer. When furriners say they want to see England, they actually really mean that they want to see London as that's all they've ever heard of. That's all anyone ever wants to see. It's only ever worth going to some of the bits of Notlondon if you've got about two months to spare. You know I'm right. Dave... -- http://www.dave.org.uk Let me see you make decisions, without your television - Depeche Mode (Stripped)
Re: [OT] Places to go, people to see...
From: Lusercop `the.lusercop'@lusercop.net Date: 6/25/03 12:14:06 PM Depends whether or not you like sailing. I love boats. but they need to be big enough to walk around on. And preferably they should have that fine 20th Century invention - an engine. I haven't been sailing in far too long. It can _never_ be too long since I last went sailing :) Dave... -- http://www.dave.org.uk Let me see you make decisions, without your television - Depeche Mode (Stripped)
RE: [OT] Places to go, people to see...
Surely London is the only possible answer. When furriners say [..] of the bits of Notlondon if you've got about two months to spare. You mean that London!=England?? Shurely not..? ;) //L
Re: [OT] Places to go, people to see...
From: Blackwell, Lee [IT] [EMAIL PROTECTED] Date: 6/25/03 12:27:35 PM Surely London is the only possible answer. When furriners say [..] of the bits of Notlondon if you've got about two months to spare. You mean that London!=England?? Shurely not..? ;) Sadly there are large parts of England that are Notlondon. They tend to be either large tracts of greenery that are given over to inefficent food production or nasty dirty industrial towns where everyone talks with a strange accent. I've been there. It's deeply unpleasant. You can search for hours in vain for a Starbucks, and EasyInternet or even a tube station. Best avoided. Dave... -- http://www.dave.org.uk Let me see you make decisions, without your television - Depeche Mode (Stripped)
Re: [OT] Places to go, people to see...
On Wed, 25 Jun 2003 11:06:37 +0100 (BST), Raf wrote: 'klimping' I think it's called. Pet Peeve: Climping Brighton is a good suggestion, as well... -- Natalie S. Ford . [EMAIL PROTECTED] http://www.natalie.ourshack.org http://natalief.livejournal.com
Re: [OT] Places to go, people to see...
On Wed, 25 Jun 2003, Dave Cross wrote: I've been there. It's deeply unpleasant. You can search for hours in vain for a Starbucks [...] Surely that's a feature, not a bug? I dream of a place that remains uncorrupted by Seattle's twin beasts -- Starbucks, and Mudhoney. But no, it's all expensive scalded coffee cheap snotty rock roll... -- Chris Devers
Re: [OT] Places to go, people to see...
On Wed, Jun 25, 2003 at 08:50:49AM -0400, Chris Devers said: On Wed, 25 Jun 2003, Dave Cross wrote: I've been there. It's deeply unpleasant. You can search for hours in vain for a Starbucks [...] Surely that's a feature, not a bug? I dream of a place that remains uncorrupted by Seattle's twin beasts -- Starbucks, and Mudhoney. But no, it's all expensive scalded coffee cheap snotty rock roll... -- Chris Devers -- sometimes i don't know whether to laugh, cry or reboot
Re: [OT] Places to go, people to see...
On Wed, Jun 25, 2003 at 02:05:44PM +0100, Simon Wistow said: I dream of a place that remains uncorrupted by Seattle's twin beasts -- Starbucks, and Mudhoney. But no, it's all expensive scalded coffee cheap snotty rock roll... [Umm, not sure what happened there] When I was in Portland I found that practically every block, and given that each block is only about 200m long this is extra impressive, had a Starbucks on. And sometimes next to it would be a Pete's Coffee House. Pete's Coffee House looks a lot less coroporate, a lot less blandly homogenous, a lot less creepy. Except Pete's is owned by the 'bucks and is there to appeal to the cynical hipster. *sigh* -- sometimes i don't know whether to laugh, cry or reboot
Re: [OT] Places to go, people to see...
Dave Cross wrote: I love boats. but they need to be big enough to walk around on. And preferably they should have that fine 20th Century invention - an engine. How very 20th century of you. I want my boats to have a kite. http://www.kiteship.com/ Andrew
Re: [OT] Places to go, people to see...
On Wednesday, June 25, 2003, at 10:14 AM, Peter Sergeant wrote: We're willing to camp or stay in a nice bed and breakfast, and we're both into The Great Big Outdoors (and both have bikes we can use) ... That sounds like Bath and then biking the Kennett and Avon canal through Freshford (pub!) and Avoncliff (pub!) into Bradford on Avon (pubs!).
Re: [OT] Places to go, people to see...
--- Simon Wistow [EMAIL PROTECTED] wrote: On Wed, Jun 25, 2003 at 02:05:44PM +0100, Simon Wistow said: I dream of a place that remains uncorrupted by Seattle's twin beasts -- Starbucks, and Mudhoney. But no, it's all expensive scalded coffee cheap snotty rock roll... [Umm, not sure what happened there] When I was in Portland I found that practically every block, and given that each block is only about 200m long this is extra impressive, had a Starbucks on. And sometimes next to it would be a Pete's Coffee House. Pete's Coffee House looks a lot less coroporate, a lot less blandly homogenous, a lot less creepy. Except Pete's is owned by the 'bucks and is there to appeal to the cynical hipster. *sigh* ..oh don't forget starf's *not free wi-fi* :( *doublesigh* Rain. __ Do you Yahoo!? Yahoo! Calendar - Free online calendar with sync to Outlook(TM). http://calendar.yahoo.com
Re: [OT] Places to go, people to see...
On Wednesday, June 25, 2003, at 08:15 AM, Simon Wistow wrote: And sometimes next to it would be a Pete's Coffee House. don'tcha mean Peet's? which is a bay area institution? Except Pete's is owned by the 'bucks and is there to appeal to the cynical hipster. actually, i don't believe it is. i don't recall such anyway. http://www.peets.com/ there may be hope. candace
Re: [OT] Places to go, people to see...
On Wed, Jun 25, 2003 at 08:49:55AM -0500, candace said: actually, i don't believe it is. i don't recall such anyway. http://www.peets.com/ there may be hope. Hmm. You may be right. My informer will have to pay for supplying me dud anecdotes. /me checks the interweb Hmm, Yahooing for Peets Starbucks shows that this is not an uncommon tale. http://themeyers.org/cgi-bin/nopre.cgi/HomeRoast/Topic5855.htm http://www.usefulwork.com/shark/archives/000431.html Seesm that there is *some* connection. Something to do with the original owners or something. /me waves hands vigourously Simon
Dutchlander coming to london
Howdy folks, this weekend i'll be making my maiden voyage to ol' londinium. I figured it might be nice to meet up with some of you (like we will at yapc::eu a few weeks down the road, but never mind that :) for maybe a little pubcrawl on saturday. all in favour of beer, buffy and ponies, say 'aye' ;) I'm actualy staying with artur, so coordinating things is probably best done with him, since i couldn't tell piccadilly circus from the big ben if acme's life depended on it :) -- Jos Boumans If superman is so smart, why does he wear underpants over his trousers? CPANPLUS http://cpanplus.sf.net
Re: [OT] Places to go, people to see...
Dave Cross wrote: Sadly there are large parts of England that are Notlondon. They tend to be either large tracts of greenery that are given over to inefficent food production or nasty dirty industrial towns where everyone talks with a strange accent. I've been there. It's deeply unpleasant. You can search for hours in vain for a Starbucks, and EasyInternet or even a tube station. Best avoided. You are, I presume from the description, referring directly to South London here :-) Returning to the actual thread I would recommend heading out west one evening into the setting sun, visiting the cathedals at Salisbury (with a Magna Carta) and Winchester, and also Durdle Door on the Dorset Coast. If you want to visit another country and can make it as far as Wales good attractions there are Harlech Castle, Snowdonia, St Davids and the Centre for Alternative Technology. -- Steve
Re: [OT] Places to go, people to see...
On Wednesday, June 25, 2003 10:14 +0100 Peter Sergeant [EMAIL PROTECTED] wrote: It so happens that I'm expecting a visit from a delightful foreign young lady next week, who's expecting me to show her England. I have eight days, no car, and not a great deal of cash. We'll be based in Fleet (near Basingstoke). If you're in the west country, visit Maiden Castle and Salisbury cathedral. -- David Cantrell
XML::LibXML::Common encodeToUTF8() annoyances
OK, this is annoying. Code is this: #!/usr/bin/perl use warnings; use strict; use XML::LibXML::Common; my $string = 'This is a test!'; my $decoded = XML::LibXML::Common-encodeToUTF8( 'iso-8859-15', $string ); print Before: $string\nAfter: $decoded\n; However, I get this error printed to STDERR: Usage: XML::LibXML::Common::encodeToUTF8(encoding, string) at ./encoding.pl line 9. I'm failed to find any useful documentation or examples. The only one I found looks almost identical to what i have above. Any suggestions? (either to fix above, or else to do the conversion in some other way...) thanks, Toby (may not reply after tonight until monday unless glasto has ssh terms ;) -- Turning and turning in the widening gyre The falcon cannot hear the falconer; Things fall apart, the centre cannot hold; Mere anarchy is loosed upon the world.
Re: XML::LibXML::Common encodeToUTF8() annoyances
Toby Corkindale wrote: Code is this: #!/usr/bin/perl use warnings; use strict; use XML::LibXML::Common; my $string = 'This is a test!'; my $decoded = XML::LibXML::Common-encodeToUTF8( 'iso-8859-15', $string ); print Before: $string\nAfter: $decoded\n; However, I get this error printed to STDERR: Usage: XML::LibXML::Common::encodeToUTF8(encoding, string) at ./encoding.pl line 9. I'm failed to find any useful documentation or examples. The only one I found looks almost identical to what i have above. You're using it as a method call when in fact it is a function :) You should either: my $decoded = XML::LibXML::Common::encodeToUTF8( 'iso-8859-15', $string ); or use XML::LibXML::Common (:encoding); my $decoded = encodeToUTF8( 'iso-8859-15', $string ); -- Robin Berjon [EMAIL PROTECTED] Research Engineer, Expwayhttp://expway.fr/ 7FC0 6F5F D864 EFB8 08CE 8E74 58E6 D5DB 4889 2488
Re: DBD::Pg - insert_id
Not sure if postgres is similar to oracle, in this respect, but in Oracle, it's illegal to do a currval call until nextval has been called at least once on a sequence. Something that may come to bite you... Take care, Mark. On Mon, 23 Jun 2003, Toby Corkindale wrote: Date: Mon, 23 Jun 2003 08:50:41 -0700 From: Toby Corkindale [EMAIL PROTECTED] Reply-To: [EMAIL PROTECTED] To: [EMAIL PROTECTED] Subject: Re: DBD::Pg - insert_id On Fri, Jun 20, 2003 at 10:53:47AM +0100, Chisel Wright wrote: One piece of functionality I can't find in the postgres database interface is the equivalent of: $sth-{'mysql_insertid'} It would just be really nice to be able to do something like: $sql = q[INSERT INTO foo (foofield1) VALUES (?)]; $sth = $dbh-prepare($sql); $sth-execute($barbaz); return $sth-{'pg_insertid'}; Can anyone offer some clues? as above, except then return last_inserted_id($tablename); Note that this is quite safe and the value returned is the current value for YOUR session only; so no need to worry about someone else inserting something or other such race conditions. :) # Returns the last ID resulting from an INSERT command sub last_inserted_id { my $self = shift; my $table = shift; #should be safe, but check anyway if ($table =~ /(\w[\w\d\_]+)/) { $table = $1; } else { die(LBHF.pm/last_inserted_id: Invalid table name: $table\n); } my $query = $self-{db}-prepare(SELECT currval(' . $table . _id_seq')); $query-execute or mydie($self, 'SQL Error occured:' . $self-{db}-errstr); return($query-fetchrow_arrayref-[0]); } hope this helps, Toby -- Turning and turning in the widening gyre The falcon cannot hear the falconer; Things fall apart, the centre cannot hold; Mere anarchy is loosed upon the world.
RE: DBD::Pg - insert_id
Postgres uses 'oid' as a reference to the last row inserted/updated, which would compare to MySQLs 'insertid', hence use: $oid_status = $sth-{pg_oid_status} from DBD::Pg' man: = pg_size Returns a reference to an array of integer values for each column. The integer shows the storage (not display) size of the column in bytes. Variable length columns are indicated by -1. pg_type Returns a reference to an array of strings for each column. The string shows the name of the data type. pg_oid_status Returns the OID of the last INSERT command. pg_cmd_status Returns the name of the last command type. Possible types are: INSERT, DELETE, UPDATE, SELECT. === -Original Message- From: Mark Morgan [mailto:[EMAIL PROTECTED] Sent: 25 June 2003 18:13 To: [EMAIL PROTECTED] Subject: Re: DBD::Pg - insert_id Not sure if postgres is similar to oracle, in this respect, but in Oracle, it's illegal to do a currval call until nextval has been called at least once on a sequence. Something that may come to bite you... Take care, Mark. On Mon, 23 Jun 2003, Toby Corkindale wrote: Date: Mon, 23 Jun 2003 08:50:41 -0700 From: Toby Corkindale [EMAIL PROTECTED] Reply-To: [EMAIL PROTECTED] To: [EMAIL PROTECTED] Subject: Re: DBD::Pg - insert_id On Fri, Jun 20, 2003 at 10:53:47AM +0100, Chisel Wright wrote: One piece of functionality I can't find in the postgres database interface is the equivalent of: $sth-{'mysql_insertid'} It would just be really nice to be able to do something like: $sql = q[INSERT INTO foo (foofield1) VALUES (?)]; $sth = $dbh-prepare($sql); $sth-execute($barbaz); return $sth-{'pg_insertid'}; Can anyone offer some clues? as above, except then return last_inserted_id($tablename); Note that this is quite safe and the value returned is the current value for YOUR session only; so no need to worry about someone else inserting something or other such race conditions. :) # Returns the last ID resulting from an INSERT command sub last_inserted_id { my $self = shift; my $table = shift; #should be safe, but check anyway if ($table =~ /(\w[\w\d\_]+)/) { $table = $1; } else { die(LBHF.pm/last_inserted_id: Invalid table name: $table\n); } my $query = $self-{db}-prepare(SELECT currval(' . $table . _id_seq'));$query-execute or mydie($self, 'SQL Error occured:' . $self-{db}-errstr); return($query-fetchrow_arrayref-[0]); } hope this helps, Toby -- Turning and turning in the widening gyre The falcon cannot hear the falconer; Things fall apart, the centre cannot hold; Mere anarchy is loosed upon the world. This e-mail has been scanned for all viruses by Star Internet. The service is powered by MessageLabs. For more information on a proactive anti-virus service working around the clock, around the globe, visit: http://www.star.net.uk
Re: DBD::Pg - insert_id
On Wed, Jun 25, 2003 at 06:13:27PM +0100, Mark Morgan wrote: Not sure if postgres is similar to oracle, in this respect, but in Oracle, it's illegal to do a currval call until nextval has been called at least once on a sequence. Something that may come to bite you... That is the case; I'm aware of it. Not quite sure where it would be a problem though? (Assuming better error checking and handling than in the quick examples below :) cheers, Toby
Re: [OT] Places to go, people to see...
On Wednesday, June 25, 2003 14:21 +0100 Andrew Beattie [EMAIL PROTECTED] wrote: Dave Cross wrote: I love boats. but they need to be big enough to walk around on. And preferably they should have that fine 20th Century invention - an engine. How very 20th century of you. I want my boats to have a kite. I want my boats to have both oars and a sail. But you have a terrible job finding the crew for a trireme. -- David ramming speed Cantrell
Re: XML::LibXML::Common encodeToUTF8() annoyances
On Wed, Jun 25, 2003 at 07:08:42PM +0200, Robin Berjon wrote: You're using it as a method call when in fact it is a function :) You should either: my $decoded = XML::LibXML::Common::encodeToUTF8( 'iso-8859-15', $string ); or use XML::LibXML::Common (:encoding); my $decoded = encodeToUTF8( 'iso-8859-15', $string ); Gah! my head-wall; Well, cheers though :) That just about finished my SQL-query-to-XML convertor. (Used in a PerlTransHandler in Apache to use pseudo-urls, select relevant matching stuff from a DB, convert results to XML, transform with XSLT, display results.) Time for beer now. Toby -- Turning and turning in the widening gyre The falcon cannot hear the falconer; Things fall apart, the centre cannot hold; Mere anarchy is loosed upon the world.
Re: XML::LibXML::Common encodeToUTF8() annoyances
On Wed, Jun 25, 2003 at 11:00:54AM -0700, Toby Corkindale wrote: Gah! my head-wall; Your head has a wall method! What does it do? andrew -- Aquarius: (Jan. 20 - Feb. 18) The race does not always go to the swift, nor the battle to the strong, but the job of lead singer always goes to the guy with the best hair.