Search Results

Search: Posts Made By: fwabbly
3,825
Posted By fwabbly
I have a variable with the date stored in the...
I have a variable with the date stored in the format MMDDhhmmYY and i cant change that i just have to work from that
3,825
Posted By fwabbly
btw all im really looking for is an idea of how...
btw all im really looking for is an idea of how to solve this rather than actual code.

Thanks
3,825
Posted By fwabbly
any ideas?
i need to compare to dates/times given in the format MMDDhhmmYY. That is month, day, hour, minute, year. It is a 24 hour clock. I need to compare two dates to check that they are, say, less than 900...
43,283
Posted By fwabbly
thanks. its always the little things!
thanks. its always the little things!
43,283
Posted By fwabbly
multiply variable
I need to multiply the value of a variable and then store it in another variable. I have EXPHOURINSEC=$(($EXPDATEHOUR * 3600)) but i get an error saying the * is unexpected.

Im using ksh
1,777
Posted By fwabbly
yeh i was being a bit special there! thanks
yeh i was being a bit special there! thanks
1,777
Posted By fwabbly
my problem isnt with getting to the numbers...
my problem isnt with getting to the numbers (altho your suggestions are nicer!). The code i used with sed got the numbers but it doesnt seem to store them in the new variables. when i run the script...
1,777
Posted By fwabbly
variables
Here is my code:

DATETIME=1214163003

echo $DATETIME | sed 's/....//' | sed 's/....$//' | read DATEHOUR
echo $DATETIME | sed 's/......//' | sed 's/..$//' | read DATEMIN

echo $DATEHOUR
echo...
1,367
Posted By fwabbly
thats great thanks
thats great thanks
1,367
Posted By fwabbly
thanks. now how do i store the output of that to...
thanks. now how do i store the output of that to either HOUR again or a new variable?
1,367
Posted By fwabbly
sed help
I need to replace the first character of a variable but only if it is a 0. For example i have a variable called HOUR and when its value is 01, 02, etc i need to just get rid of the 0. however when...
Showing results 1 to 11 of 11

 
All times are GMT -4. The time now is 05:31 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy