Sponsored Content
Top Forums Shell Programming and Scripting find files older than a given file Post 302081262 by tayyabq8 on Monday 24th of July 2006 07:25:29 AM
Old 07-24-2006
Yes "_" is delimiter here, I used it because "/" was in our search string also, so to avoid confusion it was "_" there, you can use any character as delimiter, but you have to take care of it in your syntax later on.

Regards,
Tayyab
 

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

Find files older than 20 days & not use find

I need to find files that have the ending of .out and that are older than 20 days. However, I cannot use find as I do not want to search in the directories that are underneath the directory that I am searching in. How can this be done?? Find returns files that I do not want. (2 Replies)
Discussion started by: halo98
2 Replies

2. Shell Programming and Scripting

only find files older than x minutes old

I am looking for a way to show files that have been created within a certain period (say anything older than 10 minutes or so). Is there a command/series of commands I can do this with? As an example, I have the following in a directory: -rw-r--r-- 1 owner group 70175 May 16 09:10... (1 Reply)
Discussion started by: dsimpg1
1 Replies

3. UNIX for Advanced & Expert Users

how to find files older than 4hours in HP-UX

Hi, I want to find the files older than 4 hours and remove them in HP-UX 11.23. Can anyone tell me how to do this? Thanks, GK (3 Replies)
Discussion started by: caprikar
3 Replies

4. Solaris

Find files older than x days and create a consolidated single tar file.

Hello, I need help in finding files older than x days and creating a single consolidated tar file combining them. Can anyone please provide me a script? Thanks, Dawn (3 Replies)
Discussion started by: Dawn Bosch
3 Replies

5. Shell Programming and Scripting

Find files older than 8 hours

I need a script to find files older than 8 hours... I know i can use mmin but the same is not working...the same only support mtime... This is the script i created..but the same is only giving 1 hour old..as I have given dt_H as 1 only...but if i give 8..it can go in -(negative)..how to get the... (5 Replies)
Discussion started by: cotton
5 Replies

6. UNIX for Dummies Questions & Answers

Find files older than 2010?

Hi, I need to delete all files, in a folder, older than 2010 that is 2009, 2008 ,.. files... Can anyone suggest the command for that,... Thanks ---------- Post updated at 03:29 PM ---------- Previous update was at 02:53 PM ---------- humm,.. ok right now I am using the following:... (4 Replies)
Discussion started by: Mack1982
4 Replies

7. Shell Programming and Scripting

Find files older than X with a weird file format

I have an issue with a korn shell script that I am writing. The script parses through a configuration file which lists a heap of path/directories for some files which need to be FTP'd. Now the script needs to check whether there are any files which have not been processed and are X minutes old. ... (2 Replies)
Discussion started by: MickAAA
2 Replies

8. UNIX for Advanced & Expert Users

find files older than 30 days old

Hello, I have a script which finds files in a directory that are older than 30 days and remove them. The problem is that these files are too many and when i run this command: find * -mtime +30 | xargs rm I run this command inside the directory and it returns the error: /usr/bin/find:... (8 Replies)
Discussion started by: omonoiatis9
8 Replies

9. Shell Programming and Scripting

Find older files than specified date

Hi, I need to find out list of files which are older than specific date. I am using 'find, and newer' commands but its not giving the correct result. Can you please help to findout the list of files. thanks (2 Replies)
Discussion started by: Satyak
2 Replies

10. UNIX for Dummies Questions & Answers

Find all log files under all file systems older than 2 days and zip them

Hi All, Problem Statement:Find all log files under all file systems older than 2 days and zip them. Find all zip files older than 3days and remove them. Also this has to be set under cron. I have a concerns here find . -mtime +2 -iname "*.log" -exec gzip {} Not sure if this will work as... (4 Replies)
Discussion started by: saurabh.mishra
4 Replies
fmlcut(1F)							   FMLI Commands							fmlcut(1F)

NAME
fmlcut - cut out selected fields of each line of a file SYNOPSIS
fmlcut -clist [filename...] fmlcut -flist [-dchar] [-s] [filename...] DESCRIPTION
The fmlcut function cuts out columns from a table or fields from each line in filename; in database parlance, it implements the projection of a relation. fmlcut can be used as a filter; if filename is not specified or is -, the standard input is read. list specifies the fields to be selected. Fields can be fixed length (character positions) or variable length (separated by a field delimiter character), depending on whether -c or -f is specified. Note: Either the -c or the -f option must be specified. OPTIONS
list A comma-separated list of integer field numbers (in increasing order), with optional - to indicate ranges. For example: 1,4,7; 1-3,8; -5,10 (short for 1-5,10); or 3- (short for third through last field). -clist If -c is specified, list specifies character positions (for instance, -c1-72 would pass the first 72 characters of each line). Note: No space intervenes between -c and list. -flist If -f is specified, list is a list of fields assumed to be separated in the file by the default delimiter character, TAB, or by char if the -d option is specified. For example, -f1,7 copies the first and seventh field only. Lines with no delimiter characters are passed through intact (useful for table subheadings), unless -s is specified. Note: No space intervenes between -f and list. The following options can be used if you have specified -f. -dchar If -d is specified, char is the field delimiter. Space or other characters with special meaning to FMLI must be quoted. Note: No space intervenes between -d and char . The default field delimiter is TAB. -s Suppresses lines with no delimiter characters. If -s is not specified, lines with no delimiters will be passed through untouched. EXAMPLES
Example 1: Getting login IDs and names The following example gets the login IDs and names. example% fmlcut -d: -f1,5 /etc/passwd Example 2: Getting the current login name The next example gets the current login name. example% `who am i | fmlcut -f1 -d" "` ATTRIBUTES
See attributes(5) for descriptions of the following attributes: +-----------------------------+-----------------------------+ | ATTRIBUTE TYPE | ATTRIBUTE VALUE | +-----------------------------+-----------------------------+ |Availability |SUNWcsu | +-----------------------------+-----------------------------+ SEE ALSO
fmlgrep(1F), attributes(5) DIAGNOSTICS
fmlcut returns the following exit values: 0 when the selected field is successfully cut out 2 on syntax errors The following error messages may be displayed on the FMLI message line: ERROR: line too long A line has more than 1023 characters or fields, or there is no new-line character. ERROR: bad list for c/f option Missing -c or -f option or incorrectly specified list. No error occurs if a line has fewer fields than the list calls for. ERROR: no fields The list is empty. ERROR: no delimiter Missing char on -d option. NOTES
fmlcut cannot correctly process lines longer than 1023 characters, or lines with no newline character. SunOS 5.10 5 Jul 1990 fmlcut(1F)
All times are GMT -4. The time now is 11:45 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy