The UNIX and Linux Forums  
Hello and Welcome from United States to the UNIX and Linux Forums! Thank You for Visiting and Joining Our Global Community.

Go Back   The UNIX and Linux Forums > Top Forums > Shell Programming and Scripting
.
google unix.com



Shell Programming and Scripting Post questions about KSH, CSH, SH, BASH, PERL, PHP, SED, AWK and OTHER shell scripts and shell scripting languages here.

More UNIX and Linux Forum Topics You Might Find Helpful
Thread Thread Starter Forum Replies Last Post
simple question on string concat the_learner High Level Programming 2 08-23-2007 11:09 PM
concat fields markjason Shell Programming and Scripting 10 10-23-2006 02:38 PM
concat string mpang_ Shell Programming and Scripting 1 07-25-2006 06:03 AM
Concat dhananjaysk Shell Programming and Scripting 1 03-20-2006 07:42 AM
Concat date drukkie UNIX for Dummies Questions & Answers 2 05-30-2002 07:36 AM

Closed Thread
English Japanese Spanish French German Portuguese Italian Dutch Swedish Russian Norwegian Hungarian Hebrew Danish Powered by Powered by Google
 
LinkBack Thread Tools Search this Thread Rate Thread Display Modes
  #1 (permalink)  
Old 12-04-2007
melanie_pfefer melanie_pfefer is offline
Registered User
  
 

Join Date: Nov 2006
Posts: 234
concat strings

Hello,

I have a list of tablespaces in oracle and I want to concatenate 'drop tablespace' on the left of each line and 'INCLUDING CONTENTS AND DATAFILES' on the right of each line.

Any idea how to do that?

many thanks.

PS: I tried to use excel and copy/paste it to vi. But I noticed many \240 between strings
  #2 (permalink)  
Old 12-04-2007
vino's Avatar
vino vino is offline Forum Staff  
Supporter (in vino veritas)
  
 

Join Date: Feb 2005
Location: Bangalore, India
Posts: 2,796
If you have it in MS-Excel, save it as a .txt file.

On the .txt file do this

Code:
sed -e "s/.*/drop tablespace & INCLUDING CONTENTS AND DATAFILES/g" file.txt
Closed Thread

Bookmarks

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On




All times are GMT -4. The time now is 09:12 PM.


Powered by: vBulletin, Copyright ©2000 - 2006, Jelsoft Enterprises Limited. Language Translations Powered by .
vBCredits v1.4 Copyright ©2007 - 2008, PixelFX Studios
The UNIX and Linux Forums Content Copyright ©1993-2009. All Rights Reserved.Ad Management by RedTyger

Content Relevant URLs by vBSEO 3.2.0