Skip to content
pvmehta.com

pvmehta.com

  • Home
  • About Me
  • Toggle search form
  • Linux CPU info. Linux/Unix
  • Vivek’s egrep commands to trace problem. (on linux x86-64) Linux/Unix
  • Jai Shree Ram PHP/MYSQL/Wordpress
  • Jai Shree Ram Oracle
  • Important Script Method for tuning Oracle
  • create database syntax Oracle
  • proc.sql Oracle
  • When to rebuld B-tree index Oracle
  • 556976.1 Oracle Clusterware: Components installed Oracle
  • Adding a new disk and mount it automatically. on VMWARE LINUX Linux/Unix
  • 272332.1 CRS 10g Diagnostic Collection Guide Oracle
  • Histogram Overview Oracle
  • Very Good Oralce Internal Tuning Book Oracle
  • How can I tell if ASO is installed ? Oracle
  • All Hints for Oracle Databases Oracle

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

Post navigation

Previous Post: Pending Transaction Neighbors Script
Next Post: Distributed Transaction Troubleshooting.

Related Posts

  • Logic to chech # of parameters command line parameters Linux/Unix
  • Oracle GoldenGate lag monitoring shell script Linux/Unix
  • rm_backup_arch_file.ksh Linux/Unix
  • Unix command for system configuration Linux/Unix
  • Looping for remote servers and find its database from oratab file. Linux/Unix
  • send attachment from unix-shell script Linux/Unix

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 (394)
  • PHP/MYSQL/Wordpress (10)
  • POSTGRESQL (1)
  • Power-BI (0)
  • Python/PySpark (7)
  • RAC (17)
  • rman-dataguard (26)
  • shell (149)
  • SQL scripts (343)
  • SQL Server (6)
  • Uncategorized (0)
  • Videos (0)

Recent Posts

  • tracksqltime.sql05-Mar-2026
  • 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

Archives

  • 2026
  • 2025
  • 2024
  • 2023
  • 2010
  • 2009
  • 2008
  • 2007
  • 2006
  • 2005
  • Locktree.sql Oracle
  • Remove DOS CR/LFs (^M) Linux/Unix
  • pvm_metric.sql for gathering report from vmstat tables Oracle
  • Oracle Connections expire_time and firewall Oracle
  • How to Make Trace Files Created by Oracle Readable by All Users ? Oracle
  • good linux notes Linux/Unix
  • eplan9i.sql Oracle
  • Import and export statements Oracle

Copyright © 2026 pvmehta.com.

Powered by PressBook News WordPress theme