tracksqltime.sql
This PL/SQL block identifies recently active SQL queries from a specific application server and provides details on their performance and execution plans. Here is a breakdown of what the script does:
This PL/SQL block identifies recently active SQL queries from a specific application server and provides details on their performance and execution plans. Here is a breakdown of what the script does:
🎯 Table of Contents 🤔 What is Git? Git is a version control system – think of it as a time machine for your code! Real-World Analogy Imagine you’re writing a book: Why Use Git? ✅ Track Changes: See what changed and when✅ Collaborate: Multiple people can work on the same project✅ Backup: Your code is saved on GitHub (cloud)✅ Undo Mistakes:…
In PostgreSQL on Linux, it is crucial to understand that the OS user and the database user (often both named postgres) are two completely separate entities with separate credentials. Here is the breakdown of how they interact: 1. Are the passwords the same? No. * OS User (postgres): This is a Linux system account created…
Find the SPID from Oracle’s SID using below SQL. REM **** This is used to get SPID from SID.col username format a30col machine format a20col program format a40accept _sid prompt ‘Enter Oracle Session ID ->’select a.sid, b.pid, b.spid, a.username, a.program,a.machinefrom v$session a,V$process bwhere a.paddr = b.addrand a.sid = &_sid/ Use ORADEBUG command as below. oradebug…
Read More “Trace a SQL session from another session using ORADEBUG” »
Here’s an expanded and in-depth comparison of SQL Server vs Oracle architecture — organized into major categories with detailed breakdowns. ✅ SQL Server vs Oracle Architecture – In-Depth Comparison Category SQL Server Oracle Database Core Architecture Type Thread-based, single-process architecture. Process-based, multi-process architecture (each background task is a separate OS process). Platform Windows (originally), now…
You can determine if a SQL Server database is actively being used by any users, both currently and historically (to some extent). ✅ Part 1: Check Current Active Usage 🔹 1. Who Is Connected Right Now (to a DB)? 🔍 Shows who is currently active in a specific database, with login, host, and command info….
Read More “SQL Server: How to see historical transactions” »
To check if there are any active transactions in SQL Server, you have several tools at your disposal depending on how deep you want to inspect. ✅ Option:1 See Transactions via sys.dm_tran_active_transactions Value Type 1 Read/write transaction 2 Read-only transaction 3 System transaction 4 Distributed transaction ✅ Option:2 See Transactions by Session (sp_who2 or sys.dm_exec_requests)…
Read More “SQL Server: How to see current transactions or requests” »
Below is a side-by-side comparison of Oracle PL/SQL and SQL Server T-SQL for someone coming from a PL/SQL background. This will help you quickly understand the syntax and behavior differences. 🔄 PL/SQL vs T-SQL Syntax Comparison Concept / Operation Oracle PL/SQL Syntax SQL Server T-SQL Syntax Anonymous Block BEGIN … END; BEGIN … END (no…
To check whether you are using SQL Server Standard, Enterprise, or another edition, you can use one of the following methods: 1. Using SQL Query (Recommended) Run this SQL query in SQL Server Management Studio (SSMS): Example Output: 2. Using SQL Server Management Studio (SSMS) 3. Using Command Prompt Run this command in Command Prompt…
To check which SQL Server version and edition you are running, you can use the following methods: 1. Using SQL Query (Most Reliable) Run the following SQL query in SQL Server Management Studio (SSMS) or any query tool: This will return a string containing the SQL Server version, edition, and service pack (if any). 2….
