Listing 3.
Updating the scorsese Person object
in a networked ACEDB database

Lincoln D. Stein

"Web Databases the Genome Project Way"
The Perl Journal, Spring 1999
 
#!/usr/bin/perl

use Ace;

my $db = Ace->connect(-port => 200008,
		     -host => 'stein.cshl.org')
       || die "Can't connect ", Ace->error;

my $scorsese = $db->fetch(Person => 'scorsese'
       || die "Can't get scorsese object ", Ace->error;

my (@phone) = $scorsese->Phone;

unless (@phone) {
   $scorsese->add(Phone => '555-1212');
   $scorsese->commit || die "Can't commit ", Ace->error;
}