- Support Home >
- Knowledge Base >
- Technical Articles >
- Article Detail
HowTo: Compress a versioned database to state 0
| Article ID: | 29160 |
|---|---|
| Software: | ArcGIS - ArcInfo 9.0, 9.1, 9.2, 9.3 ArcIMS 9.0, 9.0.1, 9.1, 9.2, 9.3 ArcSDE 9.0, 9.1, 9.2, 9.3 |
| Platforms: | N/A |
Summary
If the instance has not been compressed to state 0 and there is an attempt to unregister a class as versioned, a warning message may be encountered.
The warning may occur because the delta tables of the versioned class still contain rows that have not been compressed and are still being referenced by a version.
The frequency required for compressing is dependent upon the volume of edits. There is no harm in executing compress frequently; for example, daily, and it may be beneficial. The compress command removes as many un-referenced states as possible and, if applicable, moves rows from the delta tables to the base tables. Edits that are still referenced by a version continue to reside in the delta tables.
Procedure
- Reconcile and post all versions which are ready to be applied to the DEFAULT version. Alternately, delete the versions.
- Delete all versions; excluding the sde.DEFAULT version.
- Verify no users are connected. A connection acquires a state lock and a locked state can not be compressed.
- Compress the database.
-show me- Compress the database using command line:sdeversion -o compress [-N] -u sde -p sde_password -i <ArcSDE_service> -s <server_name>
-D <database>
Alternately, compress the database using the Compress Database tool in ArcCatalog. Add this tool as follows:
1. Navigate to Tools > Customize
2. Drag and drop the compress database tool to the menu bar in ArcCatalog. Now this tool is available to be used for compressing the SDE databases. - Verify the DEFAULT version references state_id 0 by describing the version with the ArcSDE utility sdeversion –o describe once the compress command completes. The output should show the value for the DEFAULT version’s state_id to be 0. The delta tables of the versioned class should be empty.
- Analyze the database to update database statistics for best performance.
Created: 4/25/2005
Last Modified: 9/8/2008