ArcSDE log file tables in a geodatabase in Oracle
A geodatabase uses log file tables to store lists of table rows.
See ArcSDE log file table configuration options for Oracle for more information.
Log file tables in ArcGIS Desktop
You cannot see log file tables in ArcGIS Desktop. Rather, you cause log file tables to be created and populated when you make a selection in ArcMap that returns a set of more than 100 features.
Log file tables in an Oracle database
When you first install ArcSDE and create your geodatabase in Oracle, the default log file configuration uses shared ArcSDE log files. Shared log files are shared by all sessions that connect as the same user. So if you have multiple users connecting with the same user account, all those sessions will be inserting and deleting records from the same log file data table. The log files are created the first time a selection set of 100 or more records is created using ArcGIS.
Which log file tables you see in your geodatabase depends on which log file configuration is used.
Shared log file tables
If you use the default shared log files, two tables per DBMS user ID are created and stored in the schema of that DBMS user— SDE_LOGFILES and SDE_LOGFILE_DATA. Once created, these tables remain in the geodatabase; however, all log file entries are deleted when the connecting application deletes all of its log files.
The dashed lines in this and subsequent diagrams denote implicit relationships between tables.
Session-based log file tables
If you alter your log file configuration to use session-based log files, you will see the SDE_LOGFILES, SDE_LOGFILE_DATA, and SDE_SESSION<SDE_ID> tables in the geodatabase. These tables are created in the schema of the user whose session caused the tables to be created. Though created, the SDE_LOGFILE_DATA table is not populated. The SDE_LOGFILES and SDE_LOGFILE_DATA tables remain in the geodatabase, and the SDE_LOGFILES table is truncated when the connecting application disconnects. The SDE_SESSION<SDE_ID> table is truncated when the connecting application no longer needs the log file records (for ArcMap, this means there is no longer a selection set), and the table is dropped when the session disconnects.
Stand-alone log file tables
If you use stand-alone log files, for each selection set above the selection threshold made by a session, a new SDE_LOGDATA_<SDE_ID>_<#> table is created for each layer. The SDE_LOGFILES and SDE_LOGFILE_DATA tables are also created per session, but the SDE_LOGFILE_DATA table is not populated. Both of these tables are created in the schema of the user who caused them to be created.
The SDE_LOGDATA_<SDE_ID>_<#> tables are truncated when the connecting session no longer needs the log files, and the tables are dropped when the session disconnects. The SDE_LOGFILES table is truncated when the connecting application disconnects.
Pools of log file tables
The SDE_LOGFILE_POOL table is created and stored in the schema of the ArcSDE administrator when the geodatabase is created. If you use a pool of stand-alone or session-based log files owned by the ArcSDE administrator, this table is used, plus SDE_LOGPOOL_<TABLE_ID> tables are created in the geodatabase. The number of SDE_LOGPOOL_<TABLE_ID> tables created depends on the number you specify for the LOGFILEPOOLSIZE in the sde_server_config table. In the example below, LOGFILEPOOLSIZE is set to 10; therefore, SDE_LOGPOOL_<TABLE_ID> tables 1 through 10 are created.
All the tables created for pools of log files are created in the ArcSDE administrator's schema.
If MAXSTANDALONELOGS is set to a number greater than 0, and a user that can create tables in the database creates a selection set that exceeds the threshold for log files to be created, a stand-alone log file table is created in that user's schema.
System tables for log files
The following are the definitions for the tables that are used for ArcSDE log files.
SDE_LOGDATA<SDE_ID>_<#>
The SDE_LOGDATA_<SDE_ID>_<#> table contains the list of business table records that are part of a stand-alone log file. The name of the table contains the session ID and stand-alone log file sequence. This table is owned by the user who caused the table to be created.
Field name |
Field type |
Description |
Null? |
---|---|---|---|
SDE_ROW_ID |
NUMBER(38) |
The ROW ID or SHAPE ID of the business table row being logged |
NOT NULL |
SDE_LOGFILE_DATA
The SDE_LOGFILE_DATA table contains the list of business table records that are part of each log file. It is owned by the user who caused the table to be created.
Field Name |
Field Type |
Description |
Null? |
---|---|---|---|
LOGFILE_DATA_ID |
NUMBER(38) |
Identifies to which log file the ROW ID belongs and is a reference to the logfile metadata in the SDE_LOGFILES table |
NOT NULL |
SDE_ROW_ID |
NUMBER(38) |
The ROW ID or SHAPE ID of the business table row being logged |
NOT NULL |
ROW_ID |
NUMBER(38) |
Uniquely identifies a record and enables removal of duplicate LOGFILE_DATA_ID or SDE_ROW_ID values |
NOT NULL |
SDE_LOGFILE_POOL
The SDE_LOGFILE_POOL table maintains the list of log files currently checked out. This table is created upon geodatabase creation and is owned by the ArcSDE administrator.
Field name |
Field type |
Description |
Null? |
---|---|---|---|
TABLE_ID |
NUMBER(38) |
Identifies the log file pool table |
NOT NULL |
SDE_ID |
NUMBER(38) |
Identifies which ArcSDE connection is currently using the given log file pool table The SDE_ID is a reference to the SDE_ID column of the PROCESS_INFORMATION table. If SDE_ID is NULL, this log file pool table is not currently in use. |
SDE_LOGFILES
The SDE_LOGFILES table contains the log file metadata. It is owned by the user who caused it to be created.
Field name |
Field type |
Description |
Null? |
---|---|---|---|
LOGFILE_NAME |
NVARCHAR2(256) |
A unique user-defined (or application-defined) defined name for the log file |
NOT NULL |
LOGFILE_ID |
NUMBER(38) |
Uniquely identifies the log file |
NOT NULL |
LOGFILE_DATA_ID |
NUMBER(38) |
Identifies to which log file the row id belongs |
NOT NULL |
REGISTRATION_ID |
NUMBER(38) |
The registration ID of the business table for which IDs are being logged in this log file |
NOT NULL |
FLAGS |
NUMBER(38) |
A bitmask of values that indicate properties of the log file |
NOT NULL |
SESSION_TAG |
NUMBER(38) |
A unique identifier for a connection's session, which allows a given ArcSDE connection to purge all temporary log files belonging to its session, for example. |
NOT NULL |
LOGFILE_DATA_DB |
NVARCHAR2(32) |
The name of the database in which the table that's holding the IDs for this log file is stored Not used in Oracle |
|
LOGFILE_DATA_OWNER |
NVARCHAR2(32) |
The name of the owner of the table that's holding the IDs for this log file |
|
LOGFILE_DATA_TABLE |
NVARCHAR2(98) |
The name of the table that is holding the ids for this log file This could be the traditional SDE_LOGFILE_DATA, or a log pool table, a session table, or a stand-alone SDE_LOGDATA<SDE_ID>_<#> table. |
|
COLUMN_NAME |
NVARCHAR2(32) |
The name of the column in the business table that is being logged Generally, this is the ROW ID or SHAPE ID, but you can also specify an arbitrary integer column to be logged. |
SDE_LOGPOOL_<table_ID>
The SDE_LOGFILE_POOL table maintains the list of log files currently checked out. This table is created upon geodatabase creation and is owned by the ArcSDE administrator.
Field name |
Field type |
Description |
Null? |
---|---|---|---|
LOGFILE_DATA_ID |
NUMBER(38) |
Identifies to which log file the ROW ID belongs and is a reference to the logfile metadata in the SDE_LOGFILES table |
NOT NULL |
SDE_ROW_ID |
NUMBER(38) |
The ROW ID or SHAPE ID of the business table row being logged |
NOT NULL |
SDE_SESSION<SDE_ID>
The SDE_SESSION<SDE_ID> table is created when you are using session-based log files. This table is used to track log file records when a connected session creates a selection set that exceeds the application threshold (100 records in ArcMap). The SDE_SESSION<SDE_ID> table is dropped when the session disconnects.
Field name |
Field type |
Description |
Null? |
---|---|---|---|
LOGFILE_DATA_ID |
NUMBER(38) |
Identifies to which log file the ROW ID belongs and is a reference to the logfile metadata in the SDE_LOGFILES table |
NOT NULL |
SDE_ROW_ID |
NUMBER(38) |
The ROW ID or SHAPE ID of the business table row being logged |
NOT NULL |
Log file tables in an XML document
Log file tables are not stored in XML documents. This means if you export your geodatabase schema to an XML workspace document, after you import the schema, log file tables will get re-created the next time users create a selection set that exceeds the log file threshold.