11-17-2012
Yes, I only need one | between them.
As I said I'd like to make from a file like this:
/22/
/23/
/24/
a file which has only one line and contains all of the previous file's lines next to each other separated by a | .
for example:
/23/|/24/|/25/
---------- Post updated at 05:35 AM ---------- Previous update was at 05:08 AM ----------
Please someone help me with this problem.
10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
Hi,
I have a name.txt which is stored:
APPLE
ORANGE
RED
BLUE
GREEN
and my script is:
$name=`cat name.txt
for file_number in `ls 1 /appl/CH_DATA/archive/CACHE/CDBACKUP$name*.archived
however, my script cannot read name.txt and put into my scrip line, I would like the output is to... (18 Replies)
Discussion started by: happyv
18 Replies
2. Shell Programming and Scripting
Hi all,
For a intro UNIX course I'm taking, I need to use the command "tr" to display a file on standard output without any newlines (all on one line).
I assume I would start with "cat filename | tr" but don't know what to put after tr.
Any ideas would be lovely!
Thanks. (3 Replies)
Discussion started by: otes4
3 Replies
3. Shell Programming and Scripting
Hi,
my xml files looks something like this
<Instance Name="New York">
<Description></Description>
<Instance Name="A">
<Description></Description>
<PropertyValue Key="false" Name="Building A" />
</Instance>
<Instance Name="B">
... (4 Replies)
Discussion started by: tententen
4 Replies
4. Shell Programming and Scripting
I have one base file, and multiple target files-- each have uniform line structure so no need to use grep to find things-- can just define sections by line number.
My question is quite simple-- can I use sed to copy a defined block of lines (say lines 5-10) from filename1.txt to overwrite an... (3 Replies)
Discussion started by: czar21
3 Replies
5. UNIX for Dummies Questions & Answers
I have a diff command that does what I want but when comparing large text/log files, it uses up all the memory I have (sometimes over 8gig of memory)
diff file1.txt file2.txt | grep '^<'| awk '{$1="";print $0}' | sed 's/^ *//'
Is there a better more efficient way to find the lines in one file... (5 Replies)
Discussion started by: raptor25
5 Replies
6. Shell Programming and Scripting
i have hundreds of thousands of txt files as below,
RADARSAT 1 SCENE DESCRIPTION
SCENE_ID c0005098
MDA ORDER NUMBER
GEOGRAPHICAL AREA CIS ScanSar Canada
SCENE START TIME APR 02 1997 23:05:10.222
SCENE STOP TIME APR 02 1997 23:02:49.695... (5 Replies)
Discussion started by: sunnydanniel
5 Replies
7. Shell Programming and Scripting
I want to add/append the info in the following format to my.txt file.
20130702|abcd20130702.txt FN|SN|DOB
I tried the below script but it throws me some exceptions.
<#!/bin/sh
dt = date '+%y%m%d'members;
echo $dt+|+members+$dt;
/usr/bin/awk -f
BEGIN { FS="|"; OFS="|"; } { print... (6 Replies)
Discussion started by: harik1982
6 Replies
8. UNIX for Dummies Questions & Answers
Hi All
Is there a way to export every line into new txt file where by the title of each txt output are same as the line ?
I have this txt files containing names:
Kandra Vanhooser
Rhona Menefee
Reynaldo Hutt
Houston Rafferty
Charmaine Lord
Albertine Poucher
Juana Maes
Mitch Lobel... (2 Replies)
Discussion started by: Nexeu
2 Replies
9. Shell Programming and Scripting
Hello,
I haven't been here for a while and I might be forgetting some things.
I have an input text like this
titleA
http://myurl/bla/blabla/1234
http://myurl/bla/blabla/6789
titleB
http://myurl/bla/blabla/5678
http://myurl/bla/blabla/1234
titleC
http://myurl/bla/blabla/9123... (10 Replies)
Discussion started by: Kibou
10 Replies
10. Shell Programming and Scripting
i would like to insert a line from 2.txt into 1.txt between " and "
or a way of adding to the end of each line " _01_ and have the numbers
correspond to the line #
1.txt=
foofoo "" _01_
foofoo "" _02_
foofoo "" _03_
foofoo "" _04_
2.txt= ... (6 Replies)
Discussion started by: klein
6 Replies
LEARN ABOUT OPENSOLARIS
dfstab
dfstab(4) File Formats dfstab(4)
NAME
dfstab - file containing commands for sharing resources across a network
DESCRIPTION
dfstab resides in directory /etc/dfs and contains commands for sharing resources across a network. dfstab gives a system administrator a
uniform method of controlling the automatic sharing of local resources.
Each line of the dfstab file consists of a share(1M) command. The dfstab file can be read by the shell to share all resources. System
administrators can also prepare their own shell scripts to execute particular lines from dfstab.
The contents of dfstab put into effect when the command shown below is run. See svcadm(1M).
/usr/sbin/svcadm enable network/nfs/server
SEE ALSO
share(1M), shareall(1M), sharemgr(1M), svcadm(1M)
NOTES
Do not modify this file directly. This file is reconstructed and only maintained for backwards compatibility. Configuration lines could be
lost.
Use the sharemgr(1M) command for all share management.
SunOS 5.11 15 Aug 2008 dfstab(4)