Sybase ASE 12 question
Sybase ASE will not allow you to directly delete rows from multiple tables using a wild card, but it's pretty simple to create a script to find the table names, and loop through them.

You can find the tables names by querying sysobjects within the database.

To find all the tables with the prefix Table_ you would do:

select name from myDatabase..sysobjects
where type = "U"
and name like "Table\_%" escape "\"


In the above query "U" is the flag for User defined tables.  Also because _ is a single character wild card in T-SQL, we have to escape it to find the literal _.  T-SQL allows almost any character to act as the escape, but it must be defined after the like clause.  Finally % is the multi-character wild card, the T-SQL equivalent to * in *nix and DOS.

It would also be possible to use the above query to build a sql script.  We start by telling the server not to print out the number of rows affected by the query using set nocount.  This allows us to create a script that will run error-free, without needing additional editing.

set nocount on    \\supressess rows affected printout
select "delete from " +name+ " where type = 1" + char(10) + "go"
from myDatabase..sysobjects
where type = "U"
and name like "Table\_%" escape "\"
go


If you execute this from isql and using the -b flag to supress headers, and -o flag to redirect output to a file, it will build a script that can then be executed directly.

isql -Uusername -Ppassword -Sservername -b -omyScriptToDeleteData.sql -iSQLToFindTables.sql