Number format conversion in UNIX


 
Thread Tools Search this Thread
Top Forums Shell Programming and Scripting Number format conversion in UNIX
# 1  
Old 01-09-2008
Number format conversion in UNIX

Hi All,

I want to convert Scientific number format into normal number format using unix script or using any command of unix.

e.g 1.55397e+09 into 1553970000

Thanks in advance
Kamal
# 2  
Old 01-09-2008
Code:
# printf "%8.3f" 1.55397e+09
1553970000.000

Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

Date format conversion

Hi, i have to check the file whether it is created today. here is the ls -l o/p -rw-r----- 20000 50000 130 Dec 12 10:21 file.txt im able to check if file is created today or not if the timestamp is in 2014-12-12 format by comparing $(date +Y-%m-%d) but stuckup as it is of format Dec 12... (6 Replies)
Discussion started by: JSKOBS
6 Replies

2. Shell Programming and Scripting

Date conversion and Format

Hello , I have a record in below format Hostname | Query: 0 | Release: 0 | files: 2 | Files_examined: 2 | SET timestamp=1396778638; | select * from test I need output in below format Hostname | 0 | 0 | 2 | 2 | 04/06/2014|03:03:58 | select * from test I was able to get above output... (1 Reply)
Discussion started by: Tomlight
1 Replies

3. Shell Programming and Scripting

Format conversion

Can you help me get the desired output? Below is the input CONA= 0. 5. 10. 15. 20. 25. 30. 35. 40. 45. 50. 55. 60. 65. 70. 75. 80. 85. 90. 95. 100. 105. 110. PLANA= 0. 15. 30. 45. 60. 75. 90. 105. 120. 135. 150. 165. 180. ITABLE= 87.3 171.4 242.9 297.6 322.8 325.6 306.8 284.5 273.4 272.2 270.2... (6 Replies)
Discussion started by: Ravi S M
6 Replies

4. Shell Programming and Scripting

Date conversion from 24 hr format to 12 hr format

hi i want to convert date procured from sone operation which will be in 24hr format to 12 hr format displaying AM and PM # date -d @1362545068 Tue Mar 5 23:44:28 EST 2013 # this Tue Mar 5 23:44:28 EST 2013 i want to convert it so that output is as below Tue... (2 Replies)
Discussion started by: vivek d r
2 Replies

5. Shell Programming and Scripting

Date format conversion

Hi All, Can someone please let me know how can i convert the date format in unix as follow: From: 24 Oct 2011 i.e $(date +'%d %b %Y') To: 111024 i.e $(date +%y%m%d) Thanks in advance (3 Replies)
Discussion started by: davidtd
3 Replies

6. Homework & Coursework Questions

Unix/Linux Math Decimal to Whole Number Format?

Use and complete the template provided. The entire template must be completed. If you don't, your post may be deleted! 1. The problem statement, all variables and given/known data: The problem? I hope I fill this out correctly. I have a program that runs like a cash register. It works and... (6 Replies)
Discussion started by: Iceman69
6 Replies

7. UNIX for Dummies Questions & Answers

date format conversion

hi, i have a file in which i get date format as 22/APR/2010... now i want the date format to be in 22-04-2010 if the month changes to may the file should also have 05 as month.... pls help (3 Replies)
Discussion started by: siva_nagarajan
3 Replies

8. Shell Programming and Scripting

format conversion

Is there any direct way in shell to convert exponential to other formats. For example 1.5e-07 to 0.150u. Or does shell support this microns, nano meter notations? (1 Reply)
Discussion started by: abhijanvt
1 Replies

9. Shell Programming and Scripting

conversion of EBCIDIC to ASCII format

Hi all, I need help on above said subject. I have a flat file which is in EBCDIC format,i want to convert into ASCII fromat using 'MFSORT'. file contains COMP-3 value in some positions. Can you please provide the SCRIPT SYNTAX.(assume that file is of 80 byte length and it is having COMP-3... (2 Replies)
Discussion started by: vijayakumarg
2 Replies

10. Windows & DOS: Issues & Discussions

conversion of unix time format

help me to convert unix time format into windows time format using java i have linux time ex. 1075329297.572 (2 Replies)
Discussion started by: sari
2 Replies
Login or Register to Ask a Question