Windows – set Affinity of a process
Set the affinity of a process to allocate it to one or more CPUs – for a process taking too much cpu. Obviously, you need to know something about the process concerned. This is more…
Set the affinity of a process to allocate it to one or more CPUs – for a process taking too much cpu. Obviously, you need to know something about the process concerned. This is more…
select substr(sql_text,instr(sql_text,’INTO “‘),30) table_name, rows_processed, round((sysdate-to_date(first_load_time,’yyyy-mm-dd hh24:mi:ss’))*24*60,1) minutes, trunc(rows_processed/((sysdate-to_date(first_load_time,’yyyy-mm-dd hh24:mi:ss’))*24*60)) rows_per_min from sys.v_$sqlarea where sql_text like ‘INSERT %INTO “%’ and command_type = 2 and open_versions > 0;select substr(sql_text,instr(sql_text,’INTO “‘),30) table_name, rows_processed, round((sysdate-to_date(first_load_time,’yyyy-mm-dd hh24:mi:ss’))*24*60,1) minutes, trunc(rows_processed/((sysdate-to_date(first_load_time,’yyyy-mm-dd…
— Locking select cmd,* from sys.sysprocesses where blocked > 0 SELECT command, s.text, start_time, percent_complete, CAST(((DATEDIFF(s,start_time,GetDate()))/3600) as varchar) + ‘ hour(s), ‘ + CAST((DATEDIFF(s,start_time,GetDate())%3600)/60 as varchar) + ‘min, ‘ + CAST((DATEDIFF(s,start_time,GetDate())%60) as varchar) + ‘…
How to add a subtotal row in sql This comes from: http://stackoverflow.com/questions/19387650/how-to-add-a-subtotal-row-in-sql Name Score A 2 B 3 A 1 B 3 Name Score A 2 A 1 Subtotal 3 B 3 B 3 Subtotal…
select * from gv$sysmetric_history where metric_name=”
select substr(sql_text, 1, 100), PHYSICAL_READ_REQUESTS, PHYSICAL_READ_BYTES, executions, last_load_time from v$sqlarea order by last_load_time desc
exec sp_msforeachdb ‘use [?]; SELECT ”?”, MAX(TotalSpaceMB) as MaxObjSizeMB FROM ( SELECT t.NAME AS TableName, i.name as indexName, (sum(a.total_pages) * 8) / 1024 as TotalSpaceMB FROM sys.tables t INNER JOIN sys.indexes i ON t.OBJECT_ID =…
Query Oracle from SQL Server using a linked server This post describes the basics of querying an Oracle database from Microsoft SQL Server. Oracle data can be queried from SQL Server via a linked server…
# cd /etc/yum.repos.d # wget http://public-yum.oracle.com/public-yum-ol6.repo # yum install oracle-rdbms-server-12cR1-preinstall –nogpgcheck
sp_updatestats