10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
Help with Perl script :
I have a web.xml file with a line
<display-name>some_text_here</display-name>
Need to append the current date and time stamp to the string and save the XML file
Something like
<display-name>some_text_here._01_23_2014_03_56_33</display-name>
-->Finally want... (5 Replies)
Discussion started by: gaurav99
5 Replies
2. Shell Programming and Scripting
Hi Folks,
Need a clarification on files with date and time stamp.
Here is my requirement. There is a file created everyday with the following format "file.txt.YYYYMMDDHHMMSS".
Now i need to check for this file and if it is available then i need to do some task to the file.
I tried... (6 Replies)
Discussion started by: jayadanabalan
6 Replies
3. Emergency UNIX and Linux Support
hi,
i have some file names. my file names are as follows:
c_abc_new.txt.xls
c_def.txt.xls
i want to append date time stamp in the below manner.
c_abc_new_YYYYMMDD_HH24MISS.txt.xls
c_def_YYYYMMDD_HH24MISS.txt.xls
check the two input file names, they differ in naming. the 1st file name... (9 Replies)
Discussion started by: Little
9 Replies
4. Shell Programming and Scripting
Hi!
Please see our current script:
#!/usr/bin/ksh
if (egrep "This string is found in the log" /a01/bpm.log)
then
mailx -s "Error from log" me@email.com, him@email.com </a01/bpm.log
fi
To the above existing script, we need to add the following change:
1) After finding the string,... (7 Replies)
Discussion started by: atechcorp
7 Replies
5. Shell Programming and Scripting
Hi
I use "touch -t xxxxxxxx" command to set date/time stamp of a file. My requirement is to read the date/time stamp of a file and apply it to another file.
Is there anyway to do it simple instead of manually taking date/stamp of first file?
TIA
Prvn (2 Replies)
Discussion started by: prvnrk
2 Replies
6. Shell Programming and Scripting
I have searched several thread and not found my solution, so I am posting a new qustion.
I have a very simple script on an AIX server that FTPs 2 files to a MS FTP server. These 2 files are created on the AIX server every hour, with a static name.
I need to FTP the files to the MS server, but... (1 Reply)
Discussion started by: sknisely
1 Replies
7. UNIX for Advanced & Expert Users
Hi,
We are using RSYNC for syncing remote directories and working great. Our requirement is to have the destination files with date/time stamp of when they're copied on to the destination server, NOT the date/time stamps of source files/directories.
As RSYNC, by default, preserving the same... (4 Replies)
Discussion started by: prvnrk
4 Replies
8. Shell Programming and Scripting
I have a directory with following files in it
ABC.000.DAT
ABC.001.DAT
ABC.002.DAT
ABC.003.DAT
I want to insert time and date stamp in file names like
ABC.000.YYYYMMDDHHMM.DAT
I able to insert the time and date stamp at the end of filename
Kindly help (1 Reply)
Discussion started by: aajmani
1 Replies
9. Shell Programming and Scripting
I'm trying to write a script that checks the DTS of a file the compares it to the current time. If greater that 60 mins has gone by and the file has not been written to alert.
So far I have the time pulled from the file but I dont know how to compare the times against a 60 min difference.
... (2 Replies)
Discussion started by: jarich
2 Replies
10. UNIX for Dummies Questions & Answers
I have to capture the creation date and time stamp for a file. The ls command doesn't list all the required information. I need year, month, day, hour, minute and second.
Any ideas... (1 Reply)
Discussion started by: Xenon
1 Replies
CAL_FROM_JD(3) 1 CAL_FROM_JD(3)
cal_from_jd - Converts from Julian Day Count to a supported calendar
SYNOPSIS
array cal_from_jd (int $jd, int $calendar)
DESCRIPTION
cal_from_jd(3) converts the Julian day given in $jd into a date of the specified $calendar. Supported $calendar values are CAL_GREGORIAN,
CAL_JULIAN, CAL_JEWISH and CAL_FRENCH.
PARAMETERS
o $jd
- Julian day as integer
o $calendar
- Calendar to convert to
RETURN VALUES
Returns an array containing calendar information like month, day, year, day of week, abbreviated and full names of weekday and month and
the date in string form "month/day/year".
EXAMPLES
Example #1
cal_from_jd(3) example
<?php
$today = unixtojd(mktime(0, 0, 0, 8, 16, 2003));
print_r(cal_from_jd($today, CAL_GREGORIAN));
?>
The above example will output:
Array
(
[date] => 8/16/2003
[month] => 8
[day] => 16
[year] => 2003
[dow] => 6
[abbrevdayname] => Sat
[dayname] => Saturday
[abbrevmonth] => Aug
[monthname] => August
)
SEE ALSO
cal_to_jd(3), jdtofrench(3), jdtogregorian(3), jdtojewish(3), jdtojulian(3), jdtounix(3).
PHP Documentation Group CAL_FROM_JD(3)