And then there were 5

One more to go – not bad for a small garden!

These make great hot spicy medicinal soup – can’t wait – makes the cold weather bearable.

pump_5

 

Pro Tools

Loving it – Purple is my favorite color.  Order is my favorite state of entropy. If only I had the most powerful computer around….working on it.

protools2 protools

Perl MySQL Transaction example

transactions

 

use strict;
use warnings;
use v5.10; # for say() function

use DBI;

say “Perl MySQL Transaction Demo”;

# MySQL database configurations
my $dsn = “DBI:mysql:perlmysqldb”;
my $username = “root”;
my $password = ”;

# connect to MySQL database
my %attr = (RaiseError=>1,  # error handling enabled
AutoCommit=>0); # transaction enabled

my $dbh = DBI->connect($dsn,$username,$password, \%attr);

eval{
# insert a new link
my $sql = “INSERT INTO links(title,url,target)
VALUES(?,?,?)”;
my $sth = $dbh->prepare($sql);
$sth->execute(“Comprehensive Perl Archive Network”,”http://www.cpan.org/”,”_blank”);
# get last insert id of the link
my $link_id = $dbh->{q{mysql_insertid}};

# insert a new tag
$sql = “INSERT INTO tags(tag) VALUES(?)”;
$sth = $dbh->prepare($sql);
$sth->execute(‘Perl’);

# get last insert id of the tag
my $tag_id = $dbh->{q{mysql_insertid}};

# insert a new link and tag relationship
$sql = “INSERT INTO link_tags(link_id,tag_id)
VALUES(?,?)”;
$sth = $dbh->prepare($sql);
$sth->execute($link_id,$tag_id);

# if everything is OK, commit to the database
$dbh->commit();
say “Link and tag has been inserted and associated successfully!”;
};

if($@){
say “Error inserting the link and tag: $@”;
$dbh->rollback();
}

# disconnect from the MySQL database
$dbh->disconnect();

Finally

I was afraid I wasn’t going to get any red tomatoes this year, then all of a sudden they all started turning last week.  I have about 3 times as many as this in the fridge.  Oh dear – more on the way!

tomatoes