Sponsored Content
Top Forums Shell Programming and Scripting How to copy particular record with cp command Post 302358834 by thegeek on Monday 5th of October 2009 01:59:19 AM
Old 10-05-2009
Some observations.,

1. Put the code in CODE tags for better visibility

2. cp is not intended for copying particular records, refer, man cp -> http://linux.die.net/man/1/cp
Code:
$ whatis cp
cp (1)               - copy files and directories

 

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

fl command - set record length

Hi, I have a KSH shell script running on hpux that uses the fl command - ex: cat /foo | fl 50 > bar This command will take each record in the file foo, make it 50 characters long and then write it to the file bar. my problem is that I am porting my scripts over to solaris which doesn't... (2 Replies)
Discussion started by: Tom Siegel
2 Replies

2. UNIX for Dummies Questions & Answers

command to remove last record on file

Hi, First time on the forum. I have converted some files using the Unix to DOS command but need to strip off the last record that is generated from this conversion that contains just a ^Z. Is there any command that would accomplish this without having to do stream editing? (4 Replies)
Discussion started by: mheinen
4 Replies

3. UNIX for Advanced & Expert Users

Command nee to cut the record

I have a file which contains a record like follows /dir1/dir2/dir3/file.dat I need command to so that output can be only file.dat (6 Replies)
Discussion started by: sreenusola
6 Replies

4. UNIX for Dummies Questions & Answers

Need a command to get part of a record from file

I have a file which contains a record like follows /dir1/dir2/dir3/file.dat I need command so that output can be only file.dat (4 Replies)
Discussion started by: sreenusola
4 Replies

5. UNIX for Advanced & Expert Users

command to insert a record at a particular loaction

Hi, Is there any command to insert a line in between two lines? My input data is as below: 1|ETG|63121387883|Alternate|Y 3|79.58|||GBP|| 4|001137001 4|0011372 5|1021701 5|1021901 1|ETG|63121387884|Alternate|Y 3|79.58|||GBP|| 4|001137001 5|1021702 5|1021802... (1 Reply)
Discussion started by: laxmi131
1 Replies

6. Shell Programming and Scripting

Unix command to extract a record from a table

Suppose there is a table like the following...I just wanted to know if there is any command using which we can get the record/name of the person who joined before 2005.. Sl Name des y.o.joining 1 Ram Engineer 2001 2 Hari Doctor 2004 3 David Plumber 2005 4 Rahim painter 2007 5 gurmeet... (1 Reply)
Discussion started by: satyajit007
1 Replies

7. Shell Programming and Scripting

Shell script for searching a record,copy to a file and then delete it

Hi, I have a requirement in hand: I have a file with millions of records say file 1.I have another file, say file 2 which has 2000 records in it. The requirement is to read file2 , and remove the read record from file 1 and move i to a seperate file, file 3. For eg: Read file 2, get the... (5 Replies)
Discussion started by: kumara2010
5 Replies

8. Shell Programming and Scripting

Record all users' command

Hi experts, .history can record one user's own command history, but my request is, I want to record all users who run commands on that box, and export the commands to a file somewhere, which record the userid, time and full command. Is it possible? I just need for audit, and trace back, if... (3 Replies)
Discussion started by: newoz
3 Replies

9. UNIX for Dummies Questions & Answers

how to copy files and record original file location?

:EDIT: I think my post name should have been labeled: how to copy files and record original file location. not "retain". Hello, this is my first post! I searched the forums a lot before posting, but was unable to answer my question. Here's my problem: There are several hundred text files... (4 Replies)
Discussion started by: willie8605
4 Replies

10. AIX

Record topas command output

How to record output of below command in a text file. topas -P or is there any other command which will do the same thing in AIX. I would like to get a report something similar to below commands. top -b prstat -c (5 Replies)
Discussion started by: NarayanaPrakash
5 Replies
PX_GET_INFO(3)															    PX_GET_INFO(3)

px_get_info - Return lots of information about a paradox file

SYNOPSIS
array px_get_info (resource $pxdoc) DESCRIPTION
PARAMETERS
o $pxdoc - Resource identifier of the paradox database as returned by px_new(3). RETURN VALUES
Returns an associated array with lots of information about a paradox file. This array is likely to be extended in the future. o fileversion -Version of file multiplied by 10, e.g. 70. o tablename -Name of table as stored in the file. If the database was created by pxlib, then this will be the name of the file without the extension. o numrecords -Number of records in this table. o numfields -Number of fields in this table. o headersize -Number of bytes used for the header. This is usually 0x800. o recordsize -Number of bytes used for each record. This is the sum of all field sizes (available since version 1.4.2). o maxtablesize - This value multiplied by 0x400 is the size of a data block in bytes. The maximum number of records in a datablock is the integer part of (maxtablesize * 0x400 - 8) / recordsize. o numdatablocks - The number of data blocks in the file. Each data block contains a certain number of records which depends on the record size and the data block size (maxtablesize). Data blocks may not necessarily be completely filled. o numindexfields - Number of fields used for the primary index. The fields do always start with field number 1. o codepage - The DOS codepage which was used for encoding fields with character data. If the target encoding is not set with px_set_targeten- coding(3) this will be the encoding for character fields when records are being accessed with px_get_record(3) or px_retrieve_record(3). SEE ALSO
px_numfields(3), px_numrecords(3). PHP Documentation Group PX_GET_INFO(3)
All times are GMT -4. The time now is 03:38 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy