IUBio

AcePerl: create new object

Jan Aerts aerts.jan at advalvas.be
Tue Sep 10 07:16:39 EST 2002


Hi.

I'm trying to write a script in which I can create objects (e.g. STS,
BAC, ...) and insert these objects in an AceDB database.
Unfortunately, very strange things happen. When I run the script (see
code below), _no_ new object is created. But when I change the name of
the object (in the code: replace "TestSTS" with e.g. "TestSTS1") and I
run the script for the first time after this change, it _sometimes_
inserts the object in the database (this is not always the case...).

A second problem: if the object gets inserted in the database, you
can't click it to get its properties (in the code below: you can't
access the STS_length or Oligo's). And the name does not appear as
"TestSTS", but as "TestSTS;".

I've ploughed through perldoc Ace and perldoc Ace::Object, but I can't
figure this one out.

I'm running acedb4_9j and AcePerl (Ace.pm version = 1.83) on a SuSE
Linux 7.3.

I hope someone can help me out with this.

Kind regards,
ir Jan Aerts (aerts.jan at advalvas.be)
Animal Breeding and Genetics Group
Wageningen University
The Netherlands

<START CODE>
: use Ace;
:
: my $db = Ace->connect(-path => "/home/acedb/chickace");
: 
: my $obj = new Ace::Object(-class => 'STS'
:                          ,-name => "TestSTS"
:                          ,-database => $db);
: $obj->add(STS_length => 800);
: $obj->add(Oligo_1 => "OL_1");
: $obj->add(Oligo_2 => "OL_2");
:   
: $obj->commit;
: 
: $db->close();
<END CODE>





More information about the Acedb mailing list

Send comments to us at biosci-help [At] net.bio.net