in reply to Autoincrement table name in the database

my output is only one table "tito$e". so my question is why doesn't it increment the tito0 to tito6 and creates those tables.

Because qw(...) doesn't interpolate. Use my $x = "tito$e"; instead.