<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>Question Re: Drop corrupt table in Technology Q&amp;A</title>
    <link>https://community.sap.com/t5/technology-q-a/drop-corrupt-table/qaa-p/13828368#M4859211</link>
    <description>&lt;P&gt;Do you "mini-backup" to text files (like Foxhound) or also to a separate database via proxy tables (so both databases are only weakly connected)?&lt;/P&gt;</description>
    <pubDate>Tue, 06 Jul 2021 09:36:55 GMT</pubDate>
    <dc:creator>VolkerBarth</dc:creator>
    <dc:date>2021-07-06T09:36:55Z</dc:date>
    <item>
      <title>Drop corrupt table</title>
      <link>https://community.sap.com/t5/technology-q-a/drop-corrupt-table/qaq-p/13828361</link>
      <description>&lt;P&gt;We had a hard crash of a database which has left at least one (that we know of) table corrupt.  We're not able to validate, query, drop, truncate the table without taking down the database.  I am able to query the objects: SELECT sc.* FROM dbo.syscolumns sc INNER JOIN sysobjects so ON sc.id = so.id WHERE so.name = 'fileusertypes'.
We want to just kill the table but don't know how at this point.  Suggestions?  TIA
SQL Anywhere 12 &lt;/P&gt;</description>
      <pubDate>Fri, 02 Jul 2021 11:37:19 GMT</pubDate>
      <guid>https://community.sap.com/t5/technology-q-a/drop-corrupt-table/qaq-p/13828361</guid>
      <dc:creator>former_SQLA_member1694892</dc:creator>
      <dc:date>2021-07-02T11:37:19Z</dc:date>
    </item>
    <item>
      <title>Re: Drop corrupt table</title>
      <link>https://community.sap.com/t5/technology-q-a/drop-corrupt-table/qaa-p/13828362#M4859205</link>
      <description>&lt;P&gt;Some corruptions may prevent operations to remove the table. I assume that since you are only looking at "dropping" that you have no viable backup that can be used?  That would be the easiest approach and should get you to a recovered database vs a data salvage.&lt;/P&gt;
&lt;P&gt;In any event, an approach to take in the absence of a backup can be&lt;/P&gt;
&lt;UL&gt;
&lt;LI&gt;Unload "schema only" i.e., dbunload -n&lt;/LI&gt;
&lt;LI&gt;Unload "data only" but exclude the corrupt table(s) i.e., dbunload -e
   &amp;lt;exclude_table_list&amp;gt; -d&lt;/LI&gt;
&lt;LI&gt;
&lt;P&gt;(Optional) Attempt to select around the damage using an ASC ordered query on the table and a DESC
   ordered query on the table unloading each order to a file, i.e., &lt;/P&gt;
&lt;P&gt;unload select * from ... order by ... ASC to &amp;lt;file&amp;gt; append on;
unload select * from ... order by ... DESC to &amp;lt;file&amp;gt; append on;&lt;/P&gt;
&lt;/LI&gt;
&lt;LI&gt;
&lt;P&gt;Init new database with the shema from step 1&lt;/P&gt;
&lt;/LI&gt;
&lt;LI&gt;Load the data using the unload from step 2 and the optional Step 3&lt;/LI&gt;
&lt;/UL&gt;</description>
      <pubDate>Fri, 02 Jul 2021 13:40:56 GMT</pubDate>
      <guid>https://community.sap.com/t5/technology-q-a/drop-corrupt-table/qaa-p/13828362#M4859205</guid>
      <dc:creator>chris_keating</dc:creator>
      <dc:date>2021-07-02T13:40:56Z</dc:date>
    </item>
    <item>
      <title>Re: Drop corrupt table</title>
      <link>https://community.sap.com/t5/technology-q-a/drop-corrupt-table/qaa-p/13828363#M4859206</link>
      <description>&lt;P&gt;Thank-you so much for your input!
This is a datamart db, and for the most part can be recre"ted via our nightly pipeline.  For that reason, we are continually truncating the log file (-m option).  However, there are a couple of transactional tables in the datamart and of course they are the ones corrupted.  We believe there are 2, based on multiple queries.  We can't even "select top n..." from either.  Our thought was to drop them and recover data from a 2 day old backup.&lt;BR /&gt;
Although I thought of the unload, which was unsuccessful, I did NOT know about the exclude table option so thank-you for that!  It may be our best bet and thank-you again.
A side question... 
Although the majority of the tables are fine, if we try to query via sybase central by clicking on a good table name and right clicking, it brings the whole db down.  As soon as you click on the table.  (bringing up an empty isql window and querying is successful on good tables).  What happens within Sybase  Central when you click on a table that brings that corrupt table into play?  We just thought that was weird.
Thank-you!
Becky Snyder 
Bradley University&lt;/P&gt;</description>
      <pubDate>Fri, 02 Jul 2021 16:29:04 GMT</pubDate>
      <guid>https://community.sap.com/t5/technology-q-a/drop-corrupt-table/qaa-p/13828363#M4859206</guid>
      <dc:creator>former_SQLA_member1694892</dc:creator>
      <dc:date>2021-07-02T16:29:04Z</dc:date>
    </item>
    <item>
      <title>Re: Drop corrupt table</title>
      <link>https://community.sap.com/t5/technology-q-a/drop-corrupt-table/qaa-p/13828364#M4859207</link>
      <description>&lt;P&gt;Hm, does DBISQL only (outside of SQL Central) allow to select from "good" tables?&lt;/P&gt;
&lt;P&gt;In case of a "fragile" database, I would try to use "simpler" tools, even dbisqlc...&lt;/P&gt;</description>
      <pubDate>Fri, 02 Jul 2021 16:46:22 GMT</pubDate>
      <guid>https://community.sap.com/t5/technology-q-a/drop-corrupt-table/qaa-p/13828364#M4859207</guid>
      <dc:creator>VolkerBarth</dc:creator>
      <dc:date>2021-07-02T16:46:22Z</dc:date>
    </item>
    <item>
      <title>Re: Drop corrupt table</title>
      <link>https://community.sap.com/t5/technology-q-a/drop-corrupt-table/qaa-p/13828365#M4859208</link>
      <description>&lt;P&gt;Yes, DBISQL outside of SQL Central allows selects from good tables.&lt;/P&gt;</description>
      <pubDate>Fri, 02 Jul 2021 17:17:55 GMT</pubDate>
      <guid>https://community.sap.com/t5/technology-q-a/drop-corrupt-table/qaa-p/13828365#M4859208</guid>
      <dc:creator>former_SQLA_member1694892</dc:creator>
      <dc:date>2021-07-02T17:17:55Z</dc:date>
    </item>
    <item>
      <title>Re: Drop corrupt table</title>
      <link>https://community.sap.com/t5/technology-q-a/drop-corrupt-table/qaa-p/13828366#M4859209</link>
      <description>&lt;P&gt;Would you be interested in a blog post that describes how to create a "mini-backup" process like &lt;A href="https://www.risingroad.com/foxhound-5-0/foxhound5_help/foxhound_introduction.html#backuprestore"&gt;the one used by Foxhound&lt;/A&gt;? It works well to frequently back up and restore small but important tables while excluding large tables that are not so important.&lt;/P&gt;</description>
      <pubDate>Sat, 03 Jul 2021 13:11:00 GMT</pubDate>
      <guid>https://community.sap.com/t5/technology-q-a/drop-corrupt-table/qaa-p/13828366#M4859209</guid>
      <dc:creator>Breck_Carter</dc:creator>
      <dc:date>2021-07-03T13:11:00Z</dc:date>
    </item>
    <item>
      <title>Re: Drop corrupt table</title>
      <link>https://community.sap.com/t5/technology-q-a/drop-corrupt-table/qaa-p/13828367#M4859210</link>
      <description>&lt;P&gt;Yes! Sounds like a nice solution for our datamarts. Some have their own more transactional tables.&lt;/P&gt;</description>
      <pubDate>Tue, 06 Jul 2021 07:52:34 GMT</pubDate>
      <guid>https://community.sap.com/t5/technology-q-a/drop-corrupt-table/qaa-p/13828367#M4859210</guid>
      <dc:creator>former_SQLA_member1694892</dc:creator>
      <dc:date>2021-07-06T07:52:34Z</dc:date>
    </item>
    <item>
      <title>Re: Drop corrupt table</title>
      <link>https://community.sap.com/t5/technology-q-a/drop-corrupt-table/qaa-p/13828368#M4859211</link>
      <description>&lt;P&gt;Do you "mini-backup" to text files (like Foxhound) or also to a separate database via proxy tables (so both databases are only weakly connected)?&lt;/P&gt;</description>
      <pubDate>Tue, 06 Jul 2021 09:36:55 GMT</pubDate>
      <guid>https://community.sap.com/t5/technology-q-a/drop-corrupt-table/qaa-p/13828368#M4859211</guid>
      <dc:creator>VolkerBarth</dc:creator>
      <dc:date>2021-07-06T09:36:55Z</dc:date>
    </item>
  </channel>
</rss>

