RE: Semi-OT: Vi Question/Need

From: <Christopher.Taylor2_at_parallon.net>
Date: Fri, 15 Mar 2013 14:06:38 -0500
Message-ID: <F05D8DF1FB25F44085DB74CB916678E8858316568D_at_NADCWPMSGCMS10.hca.corpad.net>



Except I wanted to do it in one command through the whole file using search/replace.

Basically, search for cursor postion X, then delete to end of line through each line of the file.

Shift-D requires me to position the cursor using the keys to the cursor position on each line and hit shift-d.

Chris

-----Original Message-----
From: Powell, Mark [mailto:mark.powell2_at_hp.com] Sent: Friday, March 15, 2013 1:48 PM
To: Taylor Christopher - Nashville; oracle-l_at_freelists.org Subject: RE: Semi-OT: Vi Question/Need

You mean <shift>d delete to end of line ?

-----Original Message-----
From: oracle-l-bounce_at_freelists.org [mailto:oracle-l-bounce_at_freelists.org] On Behalf Of Christopher.Taylor2_at_parallon.net Sent: Friday, March 15, 2013 9:36 AM
To: oracle-l_at_freelists.org
Subject: Semi-OT: Vi Question/Need

What is the simplest way to delete from a line POSITION to end of line through the whole file? The piece I can't figure out is to start the delete/strip portion at a specific line position on a line. Here's what I'm looking at:

At Id0 (line 4) I want to strip everything from position 73 (the 4th PIPE to end of line). I can't seem to find the right combo of search/replace.

(The reason for doing this is I can strip that off for 2 plans and then compare the plans using WinMerge to quickly id the diffs.



| Id | Operation | Name | E-Rows |E-Bytes| Cost (%CPU)| E-Time | Pstart| Pstop |


| 0 | SELECT STATEMENT | | | | 83263 (100)| | | |
| 1 | HASH UNIQUE | | 77 | 9779 | 83263 (1)| 00:06:13 | | |
| 2 | FILTER | | | | | | | |
| 3 | HASH JOIN ANTI | | 1107 | 137K| 83262 (1)| 00:06:13 | | |
| 4 | HASH JOIN | | 1149 | 126K| 82910 (1)| 00:06:11 | | |
| 5 | VIEW | index$_join$_004 | 2172 | 30408 | 358 (2)| 00:00:02 | | |
| 6 | HASH JOIN | | | | | | | |
| 7 | INDEX FAST FULL SCAN | PAYER_PK | 2172 | 30408 | 148 (2)| 00:00:01 | | |
| 8 | INDEX FAST FULL SCAN | PAYER_UK | 2172 | 30408 | 208 (1)| 00:00:01 | | |
| 9 | HASH JOIN | | 4818 | 465K| 82552 (1)| 00:06:09 | | |
| 10 | PARTITION LIST SINGLE | | 25467 | 596K| 1871 (1)| 00:00:09 | KEY | KEY |
| 11 | TABLE ACCESS FULL | MON_ACCOUNT | 25467 | 596K| 1871 (1)| 00:00:09 | 28 | 28 |
| 12 | TABLE ACCESS BY INDEX ROWID| MON_ACCOUNT_PAYER | 110K| 3775K| 34594 (1)| 00:02:35 | | |
| 13 | NESTED LOOPS | | 320K| 22M| 80676 (1)| 00:06:01 | | |
| 14 | VIEW | index$_join$_003 | 3 | 120 | 3 (0)| 00:00:01 | | |
| 15 | HASH JOIN | | | | | | | |
| 16 | INDEX FAST FULL SCAN | MON_STATUS_IDX01 | 3 | 120 | 1 (0)| 00:00:01 | | |
| 17 | INDEX FAST FULL SCAN | MON_STATUS_UK | 3 | 120 | 1 (0)| 00:00:01 | | |
| 18 | INDEX RANGE SCAN | MON_ACCT_PAYER_FK_MON_STATUS | 114K| | 225 (2)| 00:00:02 | | |
| 19 | PARTITION LIST SINGLE | | 75699 | 1034K| 350 (1)| 00:00:02 | KEY | KEY |
| 20 | INDEX RANGE SCAN | WQ_ORG_ACCOUNT_PK | 75699 | 1034K| 350 (1)| 00:00:02 | 31 | 31 |
| 21 | VIEW | index$_join$_005 | 1 | 10 | 1 (100)| 00:00:01 | | |
| 22 | HASH JOIN | | | | | | | |
| 23 | INDEX RANGE SCAN | MON_STATUS_PK | 1 | 10 | 0 (0)| | | |
| 24 | INLIST ITERATOR | | | | | | | |
| 25 | INDEX RANGE SCAN | MON_STAT_FK_MON_STAT_CAT | 1 | 10 | 4 (0)| 00:00:01 | | |
| 26 | TABLE ACCESS BY INDEX ROWID | MON_PROJECT | 1 | 9 | 1 (0)| 00:00:01 | | |
| 27 | INDEX UNIQUE SCAN | MON_PROJECT_PK | 1 | | 0 (0)| | | |

Chris Taylor
Oracle DBA
Parallon IT&S

--
http://www.freelists.org/webpage/oracle-l


--
http://www.freelists.org/webpage/oracle-l
Received on Fri Mar 15 2013 - 20:06:38 CET

Original text of this message