Development > Utilities > Verifications > Database processor > SQL Server processor 

This function is used to view the different processes and current locks in the database when the database used is SQL Server™.

Important remark

Warning, this type of functionfacilitates, via a user interface that is homogenous with the software, the launch of procedures devolved to a database administrator. It is constructed to be launched by such an administrator (normally called DBA).

It therefore assumes a prior knowledge of database functioning and optimization in order to be used profitably.

However, an inappropriate usage of the function may pose serious performance problems and place the security of the software usage in peril.

Prerequisites

SEEREFERTTO Refer to documentation Implementation

Screen management

This function is used to view the processes and the locks corresponding to these processes in the database.
These elements are presented in two tabs : the first provides a list of the processes, the second gives the list of locks.

The function is used to identify the blocking locks. After verification of the blocking and blocked processes, it will be possible to kill the blocking process.

Header

Presentation

Used to identify the characteristics of the database used.

Close

 

Fields

The following fields are present on this tab :

  • Database (field BDDNAM)

Nom de la base de données

  • Version (field VER)

Numéro de version de la base de données

  • field VERDES

Description de la version de la base de données

Close

 

Tab Processes

Presentation

On entry to this function, the processes connected to the current folder are displayed by default.

If the processes in all the solution folders are required, it is necessary to modify the Processes filter.
If the process display sort is to be modified, it is necessary to modify the Process sort and Direction.
It will then be necessary to refresh the display using the bottom of the screen.

This screen is made up of two sections :

Processes

This first section contains a grid that presents the processes running on the database.

Display options

This section is used to modify the filter options and the process sort.
The filter is used to restrict the processes display and as a result the display of the locks.
It will be necessary to refresh the display using the button at the bottom of the scree to take into account the new display options.

Close

 

Fields

The following fields are present on this tab :

Table

  • ID of process (field SPID)

Identifier for the process in the database

  • Connection user (field LOGNAM)

Name of the database user

  • Database (field DBNAM)

Nom de la base de données

  • Connection date (field LOGDAT)

Connection date

  • field LOGHOU

Connection time

  • Status (field STA)

Status of the connection

  • Application (field APP)

Program in the process of execution.

  • field CMD

Command actually executed

  • Last execution (field LASDAT)

Date of the last execution for an SQL instruction on the connection

  • field LASHOU

Time of the last execution for an SQL instruction on the connection

  • Host machine (field MAC)

Name or the computer or the machine (defined by the operating system) from which the user is connected.

  • Process host (field OSPRO)

Identifier for the process on the machine (defined by the operating system).

  • CPU (field CPU)

Total UC time for the execution of the process

  • Memory (field MEMUSE)

Number of cache pages for the procedures actually allocated to the processes. A negative number indicates that the process liberates the memory allocated to another process.

  • Phys IO (field PHYIO)

Total number of write and read operations on the disk for the process.

  • ID of blocking process (field BLOCKID)

Identifier for the blocking process

Block number 2

  • Filter process (field FLT)

Used to restrict or not the list of processes.

It is possible to display

  • The processes on the current folder (by default)
  • All the database processes (all the folders)
  • field FILLER0

 

  • Sort of processes (field TRI)

Used to sort the list of processes. There is the possibility to specify the sense of the sort.

  • Sign (field TYPTRI)

 

Close

 

Functions accessed by right click on the grid

Detail

Fields

The following fields are present in this window :

Block number 1

  • ID of process (field SPID)

Identifier for the process in the database

  • Database (field DBNAM)

Nom de la base de données

  • Connection user (field LOGNAM)

Name of the database user

  • Last execution (field LASDAT)

Date of the last execution for an SQL instruction on the connection

  • field LASHOU

Time of the last execution for an SQL instruction on the connection

  • Host machine (field MAC)

Name or the computer or the machine (defined by the operating system) from which the user is connected.

Last SQL instruction

  • field SQLTXT

Text for the last SQL instruction executed on the connection

Close

Used to view the text for the last SQL instruction for the process.

End process

Used to immediately kill the selected process.

Only a database user having the role sysadminor processadmincan carry out this action. It will therefore be necessary to give the name of the user having sufficient rights plus their password.

 

Fermer

 

Tab Locks

Presentation

The second tab displays the list of locks in place and pending on the database that corresponds to the processes in the first tab.

This is used to distinguish in the case of blocking locks:

  • which process is blocking
  • which process is blocked and which is the process that it blocks.

Close

 

Fields

The following fields are present on this tab :

Table

  • ID of process (field SPID)

Identifier for the process in the database

  • Database (field DBNAM)

Nom de la base de données

  • User (field LOGNAM)

Name of the database user

  • Host machine (field MAC)

Name or the computer or the machine (defined by the operating system) from which the user is connected.

  • Owner (field OBJOWN)

Owner of the object currently being locked.

  • Object (field OBJNAM)

Name of the object or the transaction currently being locked.

  • Index (field INDNAM)

Nom de l'index en cours de verrouillage.

  • Type (field TYPLCK)

Locked resource type.

Possible values:

 1. NUL = NULL resource (not used).
 2. DB  = Database.
 3. FIL = File.
 4. IDX = Index/Object.
 5. TAB = Table.
 6. PAG = Page.
 7. KEY = Key.
 8. EXT = Extension.
 9. RID = RID (Line ID).
10. APP = Application.
11. MD  = METADATA.
12. HBT = HOBT.
13. AU  = ALLOCATION_UNIT.

  • Resource (field RES)

Textual description of a locking resource

  • Method (field MODE)

Locking request method. This column corresponds to the locking method of the requestor and represents the method granted, the conversion method or the pending method.

Possible values:

0 = NULL. No access is accorded to the resource. Serves as reserved space.
1 = Sch-S (Stability of the structure). Guarantees that the element of a structure, such as a table or an index, is not deleted when a session containing a structure stability lock on the structure element.
2 = Sch-M (Modification of the structure). Must contained by all sessions destined to be modify the structure of the specified resource. Guarantee that no other session makes reference to the indicated object.
3 = S (Shared). The session maintaining the lock can have a shared access to the resource.
4 = U (Update). Indicates that an update lock has been set on the resources that can finally be updated. Used to avoid current blocking forms that arise when several sessions lock the resources for any potential update.
5 = X (Exclusive). The session maintaining the lock can have a exclusive access to the resource.
6 = IS (Shared intent). Indicates the intention to place the S lock on certain sub-ordinate resources in the locking hierarchy.
7 = IU (Update intent). Indicates the intention to place the U lock on certain sub-ordinate resources in the locking hierarchy.
8 = IX (Exclusive intent). Indicates the intention to place the X lock on certain sub-ordinate resources in the locking hierarchy.
9 = SIU (Update of the Shared intent locks). Signals the shared access to a resource with the goal of setting the update locks on the sub-ordinate resources in the locking hierarchy.
10 = SIX (Exclusive Share intent). Signals the shared access to a resource with the goal of setting the exclusive locks on the sub-ordinate resources in the locking hierarchy.
11 = UIX (Exclusive Update intent). Signals an update lock on a resource with the goal of setting exclusive locks on the sub-ordinate resources in the locking hierarchy.
12 = BU. Used by the operations by block.
13 = RangeS_S (shared keys lock and shared resource lock). Indicates an analysis by range.
14 = RangeS_U(shared keys lock and resource update lock). Indicates an update by range.
15 = RangeI_N (extended key insertion lock and NULL resource lock). Used to test the extensions before the insertion of a new key in an index.
16 = RangeI_S. Key conversion lock, created by a superposition of the RangeI_N and S locks.
17 = RangeI_U. Key conversion lock, created by a superposition of the RangeI_N and U locks.
18 = RangeI_X. Key conversion lock, created by a superposition of the RangeI_N and X locks.
18 = RangeX_S. Key conversion lock, created by a superposition of the RangeI_N and RangeS_S locks.
20 = RangeX_U. Key conversion lock, created by a superposition of the RangeI_N and RangeS_U locks.
21 = RangeX_X (Exclusive resource lock, exclusive extended). Conversion lock used when the update of a key is expected.

  • Lock status (field LCKSTA)

Status of the locking request.

Possible values:

1 = Granted
2 = In conversion
3 = Pending

  • Delay of SPID (field WAIT)

Identifier for the blocking process

Close

 

Functions accessed by right click on the grid

Detail

Fields

The following fields are present in this window :

Block number 1

  • ID of process (field SPID)

Identifier for the process in the database

  • Database (field DBNAM)

Nom de la base de données

  • Connection user (field LOGNAM)

Name of the database user

  • Last execution (field LASDAT)

Date of the last execution for an SQL instruction on the connection

  • field LASHOU

Time of the last execution for an SQL instruction on the connection

  • Host machine (field MAC)

Name or the computer or the machine (defined by the operating system) from which the user is connected.

Last SQL instruction

  • field SQLTXT

Text for the last SQL instruction executed on the connection

Close

Used to view the text for the last SQL instruction for the process.

 

Fermer

 

Specific Buttons

This button, also accessible using the short cut, used to refresh the display of the tabs.

Error messages

In addition to the generic error messages, the following messages can appear during the entry :

"Verify the parameterization of the solution from the console (solution.xml file)."

Required information cannot be recovered from the solution.xml file. The parameterization of the solution is incomplete and it is necessary to complete it using the configuration console.

Tables used

SEEREFERTTO Refer to documentation Implementation