Results 1 to 2 of 2
  1. #1
    Join Date
    Feb 2002
    Posts
    3

    Unanswered: droping new tables

    Got problem droping tables. Our application inserts new table in our database once a users has a successfull logon on the application. Now when I run "info" from dbaccess, table menu tab it list all the tables in the database including the new tables created by the application.

    These new tables are accumulating everyday. Meaning every users logon is equavalent to one table and informix assgins unique name but always starts with something like "btv_". So we wanted to create a script that will drop those tables. I have this sql script just to list the new tables but when I run this sql script it doesnt find the new tables. Here's the sql script

    select database sysmaster
    select tabname from systabnames
    where dbsname = "dbname" and tabname = "btv_%"
    order by tabname

    btv_% is just a wildcard to filter all tables that start with this name. Unfornately it wont show when you run the script. Is every databases has it's own sysmaster? Am I missing something here?

    THanks a lot
    Joey

  2. #2
    Join Date
    Mar 2002
    Posts
    1
    Hope I can help.
    Is every databases has it's own sysmaster? No, one sysmaster for all the database.

    Try this:

    select database {your database} (not sysmaster)
    select tabname from systables
    where tabname = "btv_%"
    order by tabname

    What you are looking for is the "System Catalog Tables". Every database has the own system tables. One sysmaster for all databases.



Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •