Skip to content
pvmehta.com

pvmehta.com

  • Home
  • About Me
  • Toggle search form
  • Privileges Required to Create Procedures and Functions that uses objects from other schema. Oracle
  • Backup and Recovery Scenarios Oracle
  • Guide to Linux System Command Mastery Linux/Unix
  • move_arch_files.ksh Linux/Unix
  • create PLAN_TABLE command. Oracle
  • changing kernel parameter in Oracle Enterpise Linux Linux/Unix
  • Goldengate document from Porus Oracle
  • longtx.sql Oracle
  • Python class import from different folders Python/PySpark
  • Space padding in korn shell Linux/Unix
  • normal maintenance for exp-imp and renaming table Oracle
  • Export With Query Another Example. Oracle
  • catting.sh Linux/Unix
  • Building Our Own Namespaces with “Create Context” Oracle
  • Find average Row Length and other table size calculation. metalink notes Oracle

Year: 2010

ORA-01220

Posted on 12-Mar-2010 By Admin No Comments on ORA-01220

Oracle Error :: ORA-01220 file based sort illegal before database is open Cause A query issued against a fixed table or view required a temporary segment for sorting before the database was open. Only in-memory sorts are supported before the database is open. Action Re-phrase the query to avoid a large sort, increase the values…

Read More “ORA-01220” »

Oracle, SQL scripts

Oracle Release Explaination

Posted on 07-Mar-2010 By Admin No Comments on Oracle Release Explaination

11.1.0.6.0 11 : Major Release Number 1 : Maintenance Release Number 0 : AppServer Release Number 6 : Component-Specific Release Number 0 : Platform specific release number.

Oracle, SQL scripts

How to specify 2 arch location to avoid any kind of DB hanging.

Posted on 03-Mar-2010 By Admin No Comments on How to specify 2 arch location to avoid any kind of DB hanging.

Scenario: I wish to configure two locations for log archives in the way that archives should get stored on location “A” and when it gets filled or become unavailable due to any reason then logs should automatically start using location “B” for onward. In short failure of location A should start storing archives on location…

Read More “How to specify 2 arch location to avoid any kind of DB hanging.” »

Oracle, SQL scripts

Sending SQLPLUS output in HTML format

Posted on 17-Feb-201025-May-2023 By Admin No Comments on Sending SQLPLUS output in HTML format

SET MARKUP HTML ON SPOOL ON generates an HTML page for each subsequently spooled file. The HTML tags in a spool file are closed when SPOOL OFF is executed or SQL*Plus exits. You can use SET MARKUP HTML ON SPOOL OFF to generate HTML output suitable for embedding in an existing web page. HTML output…

Read More “Sending SQLPLUS output in HTML format” »

Oracle, SQL scripts

Generating XML from SQLPLUS

Posted on 10-Feb-2010 By Admin No Comments on Generating XML from SQLPLUS

set pages 0 set linesize 150 set long 9999999 set head off SQL> select dbms_xmlgen.getxml(‘select employee_id, first_name, 2 last_name, phone_number from employees where rownum < 6') xml 3 from dual 100 Steven King 515.123.4567 101 Neena Kochhar 515.123.4568 102 Lex De Haan 515.123.4569 103 Alexander Hunold 590.423.4567 104 Bruce Ernst 590.423.4568

Oracle, SQL scripts

Query to Generate aggregate on every 30 mins.

Posted on 09-Feb-2010 By Admin No Comments on Query to Generate aggregate on every 30 mins.

select to_char(first_time, ‘RRRRMMDDHH24’), COUNT (CASE WHEN TO_NUMBER(TO_CHAR(FIRST_time, ‘MI’)) 30 THEN 1 ELSE NULL END) COUNT2 FROM V$LOG_HISTORY GROUP BY to_char(first_time, ‘RRRRMMDDHH24’) order by 1 / TO_CHAR(FI COUNT1 COUNT2 ———- ———- ———- 2010020906 3 1 2010020907 3 1 2010020908 3 1 2010020909 3 1 2010020910 3 1 2010020911 3 1 2010020912 3 1 2010020913 3 1…

Read More “Query to Generate aggregate on every 30 mins.” »

Oracle, SQL scripts

Distributed Transaction Troubleshooting.

Posted on 08-Feb-2010 By Admin No Comments on Distributed Transaction Troubleshooting.

SQL> select * from sys.pending_trans$ where local_tran_id = ‘26.2.2712168’; no rows selected SQL> select * from sys.pending_sessions$ where local_tran_id = ‘26.2.2712168’; no rows selected SQL> select * from sys.pending_sub_sessions$ where local_tran_id = ‘26.2.2712168’; no rows selected SQL> select * from dba_2pc_neighbors; no rows selected SQL> select * from dba_2pc_pending; no rows selected SQL> commit force…

Read More “Distributed Transaction Troubleshooting.” »

Oracle, SQL scripts

Deleting first line and lastline of a file using sed

Posted on 04-Feb-2010 By Admin No Comments on Deleting first line and lastline of a file using sed

Delete last line of a file. =========================== sed ‘$d’ < input_file > output_file Delete First line of a file. ============================ sed ‘1d’ input_file > output_file

Linux/Unix, shell

Pending Transaction Neighbors Script

Posted on 03-Feb-2010 By Admin No Comments on Pending Transaction Neighbors Script

COL LOCAL_TRAN_ID FORMAT A13 COL IN_OUT FORMAT A6 COL DATABASE FORMAT A25 COL DBUSER_OWNER FORMAT A15 COL INTERFACE FORMAT A3 SELECT LOCAL_TRAN_ID, IN_OUT, DATABASE, DBUSER_OWNER, INTERFACE FROM DBA_2PC_NEIGHBORS / SQL> CONNECT SYS@hq.acme.com AS SYSDBA SQL> @neighbors_script LOCAL_TRAN_ID IN_OUT DATABASE DBUSER_OWNER INT ————- —— ————————- ————— — 1.15.870 out SALES.ACME.COM SYS C

Oracle, SQL scripts

Pending Distributed Transations

Posted on 03-Feb-2010 By Admin No Comments on Pending Distributed Transations

COL LOCAL_TRAN_ID FORMAT A13 COL GLOBAL_TRAN_ID FORMAT A30 COL STATE FORMAT A8 COL MIXED FORMAT A3 COL HOST FORMAT A10 COL COMMIT# FORMAT A10 SELECT LOCAL_TRAN_ID, GLOBAL_TRAN_ID, STATE, MIXED, HOST, COMMIT# FROM DBA_2PC_PENDING /

Oracle, SQL scripts

Posts pagination

Previous 1 … 3 4 5 6 Next

Categories

  • AWS (2)
  • Azure (1)
  • Linux/Unix (149)
  • Oracle (392)
  • PHP/MYSQL/Wordpress (10)
  • Power-BI (0)
  • Python/PySpark (7)
  • RAC (17)
  • rman-dataguard (26)
  • shell (149)
  • SQL scripts (341)
  • Uncategorized (0)
  • Videos (0)

Recent Posts

  • load SPM baseline from cursor cache05-Jun-2025
  • Drop all SPM baselines for SQL handle05-Jun-2025
  • Load SPM baseline from AWR05-Jun-2025
  • Drop specific SQL plan baseline – spm05-Jun-2025
  • findinfo.sql (SQL for getting CPU and Active session info)27-May-2025
  • SQL Tracker by SID sqltrackerbysid.sql22-Apr-2025
  • How to connect to Oracle Database with Wallet with Python.21-Mar-2025
  • JSON/XML Types in Oracle18-Mar-2025
  • CPU Core related projections12-Mar-2025
  • Exadata Basics10-Dec-2024

Archives

  • 2025
  • 2024
  • 2023
  • 2010
  • 2009
  • 2008
  • 2007
  • 2006
  • 2005
  • Adding a new disk and mount it automatically. on VMWARE LINUX Linux/Unix
  • Search and replace pattern Linux/Unix
  • Query to Generate aggregate on every 30 mins. Oracle
  • UNderstand and eliminate Latch contention. Oracle
  • Set Role explaination. Oracle
  • Adding addidional hard drive and attach it to a linux box. Linux/Unix
  • How does one SELECT a value from a table into a Unix variable? From SQL to Shell Linux/Unix
  • Gather Stats manually using DBMS_STATS after disabling DBMS_SCHEDULER jobs as previous entry Oracle

Copyright © 2025 pvmehta.com.

Powered by PressBook News WordPress theme