This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function GetApplicationVersion:string; | |
var | |
verblock:PVSFIXEDFILEINFO; | |
versionMS,versionLS:cardinal; | |
verlen:cardinal; | |
rs:TResourceStream; | |
m:TMemoryStream; | |
p:pointer; | |
s:cardinal; | |
begin |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
unit BufferedFileStream; | |
interface | |
uses | |
SysUtils, Math, Classes, Windows; | |
type | |
TBaseCachedFileStream = class(TStream) | |
private |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
SELECT owner | |
, segment_name | |
, segment_type | |
, tablespace_name | |
, bytes / 1048576 MB | |
, initial_extent | |
, next_extent | |
, extents | |
, pct_increase | |
FROM DBA_SEGMENTS |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
SELECT df.tablespace_name "Tablespace" | |
, totalusedspace "Used MB" | |
, (df.totalspace - tu.totalusedspace) "Free MB" | |
, df.totalspace "Total MB" | |
, ROUND(100 * ((df.totalspace - tu.totalusedspace) / df.totalspace)) "Pct. Free" | |
FROM (SELECT tablespace_name, ROUND(SUM(bytes) / 1048576) TotalSpace | |
FROM dba_data_files | |
GROUP BY tablespace_name) df | |
, (SELECT ROUND(SUM(bytes) / (1024 * 1024)) totalusedspace, tablespace_name | |
FROM dba_segments |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# View registry settings | |
Get-ItemProperty HKLM:\SYSTEM\CurrentControlSet\Enum\HID\*\*\Device` Parameters FlipFlopWheel -EA 0 | |
# Change registry settings | |
# Reverse mouse wheel scroll FlipFlopWheel = 1 | |
# Normal mouse wheel scroll FlipFlopWheel = 0 | |
Get-ItemProperty HKLM:\SYSTEM\CurrentControlSet\Enum\HID\*\*\Device` Parameters FlipFlopWheel -EA 0 | ForEach-Object { Set-ItemProperty $_.PSPath FlipFlopWheel 1 } | |
# Restore default scroll direction | |
# Get-ItemProperty HKLM:\SYSTEM\CurrentControlSet\Enum\HID\*\*\Device` Parameters FlipFlopWheel -EA 1 | ForEach-Object { Set-ItemProperty $_.PSPath FlipFlopWheel 0 } |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
SELECT LISTAGG ( | |
'GRANT ' | |
|| PRIVILEGE | |
|| ' ON ' | |
|| :TARGET_TABLE_OWNER | |
|| '.' | |
|| :TARGET_TABLE_NAME | |
|| ' TO ' | |
|| GRANTEE, | |
'; ' || CHR (10)) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
TYPE varchar_tab IS TABLE OF VARCHAR2(100); | |
FUNCTION split_string(in_comma_separated_values IN VARCHAR2) RETURN varchar_tab | |
PIPELINED IS | |
val VARCHAR2(32); | |
i_from PLS_INTEGER := 1; | |
i_to PLS_INTEGER; | |
len PLS_INTEGER; | |
BEGIN | |
len := LENGTH(in_comma_separated_values); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
select s.inst_id, | |
SQL.SQL_TEXT as "OPERATION", | |
to_char(START_TIME, 'dd/mm/yyyy hh24:mi:ss') Start_Time, | |
to_char(LAST_UPDATE_TIME, 'dd/mm/yyyy hh24:mi:ss') Last_Update_Time, | |
round(TIME_REMAINING/60,1) as "MINUTES_REMAINING", | |
round((SOFAR/TOTALWORK) * 100,2) as PCT_DONE | |
from gv$session s, | |
gv$sqlarea sql, | |
gv$session_longops op | |
where |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public static class UIHelper | |
{ | |
private static float | |
x, y, | |
width, height, | |
margin, | |
controlHeight, | |
controlDist, | |
nextControlY; | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
create global temporary table run_stats | |
( runid varchar2(15), | |
name varchar2(80), | |
value int ) | |
on commit preserve rows; | |
create or replace view stats | |
as select 'STAT...' || a.name name, b.value | |
from v$statname a, v$mystat b | |
where a.statistic# = b.statistic# |
OlderNewer