Skip to content
pvmehta.com

pvmehta.com

  • Home
  • About Me
  • Toggle search form
  • Database link password in user_db_links Oracle
  • Find average Row Length and other table size calculation. metalink notes Oracle
  • AWR license Oracle
  • Another export with Query Oracle
  • Implementing Listener Security Oracle
  • Temporary Tablespsace Temp tablespace behaviour Oracle
  • Running some SQL on multiple databases connecting using monitoring userid and password Linux/Unix
  • This is im telling Kishore Oracle
  • Specify the Rollback segment to use in Transaction Oracle
  • Pending Transaction Neighbors Script Oracle
  • run this before doing any dbchange pvm_pre_change.sql Oracle
  • findx.sql /* Find Indexes on specified USER.TABLE_NAME */ Oracle
  • Oracle 11g RAC on OEL 5 and Vmware 2 Oracle
  • Good links for x$ tables in oracle. Oracle
  • Reading parameter file and printing Linux/Unix

Remove duplicate rows from table

Posted on 15-Jan-2008 By Admin No Comments on Remove duplicate rows from table

declare

cursor c1 is

select distinct PRODUCT_SKU, FIT_ID from geo_florist order by PRODUCT_SKU, FIT_ID;

begin

for cur1 in c1 loop

delete from geo_florist a

where a.rowid != ( select max(b.rowid) from geo_florist b

where a.product_sku = b.product_sku

and a.fit_id = b.fit_id)

and a.product_sku = cur1.product_sku

and a.fit_id = cur1.fit_id;

if (mod(c1%rowcount, 1000) = 0) then commit;

end if;

end loop;

end;

/

Oracle, SQL scripts

Post navigation

Previous Post: on IBM-AIX for display
Next Post: find the files that are 1 day old.

Related Posts

  • 276434.1 Modifying the VIP or VIP Hostname of a 10g or 11g Oracle Clusterware Node Oracle
  • Find Time Consuming SQL Statements in Oracle 10g Oracle
  • standard Monitoring – 1 Oracle
  • ext#.sql Oracle
  • Facts about SCN and Rollback Segment Oracle
  • How to find who is using which Rollback segment and how many rows or blocks in that rollback segments, Oracle

Leave a Reply Cancel reply

Your email address will not be published. Required fields are marked *

Categories

  • Ansible (0)
  • AWS (2)
  • Azure (1)
  • Django (0)
  • GIT (1)
  • Linux/Unix (149)
  • MYSQL (5)
  • Oracle (393)
  • PHP/MYSQL/Wordpress (10)
  • POSTGRESQL (1)
  • Power-BI (0)
  • Python/PySpark (7)
  • RAC (17)
  • rman-dataguard (26)
  • shell (149)
  • SQL scripts (342)
  • SQL Server (6)
  • Uncategorized (0)
  • Videos (0)

Recent Posts

  • Complete Git Tutorial for Beginners25-Dec-2025
  • Postgres DB user and OS user.25-Dec-2025
  • Trace a SQL session from another session using ORADEBUG30-Sep-2025
  • SQL Server Vs Oracle Architecture difference25-Jul-2025
  • SQL Server: How to see historical transactions25-Jul-2025
  • SQL Server: How to see current transactions or requests25-Jul-2025
  • T-SQL Vs PL/SQL Syntax25-Jul-2025
  • Check SQL Server edition25-Jul-2025
  • Checking SQL Server Version25-Jul-2025
  • Oracle vs MYSQL Architecture differences (For DBAs)24-Jul-2025

Archives

  • 2025
  • 2024
  • 2023
  • 2010
  • 2009
  • 2008
  • 2007
  • 2006
  • 2005
  • How to see which patches are applied. Oracle
  • Guide to Linux System Command Mastery Linux/Unix
  • Logic to chech # of parameters command line parameters Linux/Unix
  • Add new columns in dataframe Python/PySpark
  • Generating XML from SQLPLUS Oracle
  • How to start CRS manually Oracle
  • Validating ORACLE_SID againt oratab file. Linux/Unix
  • Oracle 10g for solaris 10 Oracle

Copyright © 2026 pvmehta.com.

Powered by PressBook News WordPress theme