Home > Class Reference > ENSLIB namespace > %TSQL.sys.processes

%TSQL.sys.processes

view class %TSQL.sys.processes

SQL Table Name: %TSQL_sys.processes

View Query:
		select	JobNumber as spid, 
			1 as kpid,
			null as blocked,
			ClientNodeName as clienthostname,
			ClientExecutableName as clientapplname, 
			PidExternal as hostprocess,	
			Routine As program_name, 
			GlobalReferences as physical_io,
			MemoryUsed As memusage, 
			CURRENT_TIMESTAMP as login_time,
			Priority as priority, 
			ClientNodeName as clientname, 
			State as status, 
			$TSQL_HOST_NAME() as hostname,
			CurrentLineAndRoutine as cmd,
			OSUserName as nt_username, 	
			UserName as loginame,
			ClientIPAddress, 
			CurrentDevice, 
			CurrentSrcLine, 
			InTransaction, 
			JobType, 
			LastGlobalReference, 
			LinesExecuted, 
			Location,
			MemoryAllocated,
			NameSpace,
			OpenDevices, 
			Pid, 
			StartupClientIPAddress, 
			StartupClientNodeName, 
			UserInfo
			from %SYS.ProcessQuery
Query analysis:
Col Schema Table Col Name Col Label Datatype ODBC Type Code Length Precision Scale
1 %SYS ProcessQuery JobNumber spid %Library.Integer 4 4 10 0
2 kpid %Library.Integer 4 1 1 0
3 blocked %Library.String 12 1 1 0
4 %SYS ProcessQuery ClientNodeName clienthostname %Library.String 12 50 50 0
5 %SYS ProcessQuery ClientExecutableName clientapplname %Library.String 12 50 50 0
6 %SYS ProcessQuery PidExternal hostprocess %Library.String 12 50 50 0
7 %SYS ProcessQuery Routine program_name %Library.String 12 50 50 0
8 %SYS ProcessQuery GlobalReferences physical_io %Library.BigInt -5 8 19 0
9 %SYS ProcessQuery MemoryUsed memusage %Library.Integer 4 4 10 0
10 login_time %Library.TimeStamp 11 16 19 0
11 %SYS ProcessQuery Priority priority %Library.Integer 4 4 10 0
12 %SYS ProcessQuery ClientNodeName clientname %Library.String 12 50 50 0
13 %SYS ProcessQuery State status %Library.String 12 50 50 0
14 hostname %Library.String 12 255 255 0
15 %SYS ProcessQuery CurrentLineAndRoutine cmd %Library.String 12 50 50 0
16 %SYS ProcessQuery OSUserName nt_username %Library.String 12 50 50 0
17 %SYS ProcessQuery UserName loginame %Library.String 12 50 50 0
18 %SYS ProcessQuery ClientIPAddress ClientIPAddress %Library.String 12 50 50 0
19 %SYS ProcessQuery CurrentDevice CurrentDevice %Library.String 12 50 50 0
20 %SYS ProcessQuery CurrentSrcLine CurrentSrcLine %Library.String 12 50 50 0
21 %SYS ProcessQuery InTransaction InTransaction %Library.Integer 4 4 10 0
22 %SYS ProcessQuery JobType JobType %Library.Integer 4 4 10 0
23 %SYS ProcessQuery LastGlobalReference LastGlobalReference %Library.String 12 50 50 0
24 %SYS ProcessQuery LinesExecuted LinesExecuted %Library.BigInt -5 8 19 0
25 %SYS ProcessQuery Location Location %Library.String 12 50 50 0
26 %SYS ProcessQuery MemoryAllocated MemoryAllocated %Library.Integer 4 4 10 0
27 %SYS ProcessQuery NameSpace NameSpace %Library.String 12 50 50 0
28 %SYS ProcessQuery OpenDevices OpenDevices %Library.String 12 50 50 0
29 %SYS ProcessQuery Pid Pid %Library.Integer 4 4 10 0
30 %SYS ProcessQuery StartupClientIPAddress StartupClientIPAddress %Library.String 12 50 50 0
31 %SYS ProcessQuery StartupClientNodeName StartupClientNodeName %Library.String 12 50 50 0
32 %SYS ProcessQuery UserInfo UserInfo %Library.String 12 16 16 0