my $sth = $dbh->prepare($SQLQueryString);
my $array_ref = $dbh->selectall_arrayref( $SQLQueryString, { Slice =>
+{} }, @SQLvars );
First of all, you are preparing a statement handle, and then not using it (but using the database handle instead). Second, DBI does not expect named parametres (at least the way you're writing your placeholders), nor will that function accept an array of hashrefs. Instead, something like this would work:
$aref = $dbh->selectall_arrayref($sql, {stuff => 'here'}, 'TESTA1', 'T
+ESTA2', 'TESTA3');