Sponsored Content
Top Forums UNIX for Dummies Questions & Answers Create a table - very new to unix Post 302438375 by aj250 on Monday 19th of July 2010 01:01:48 PM
Old 07-19-2010
Code:
$ cat  Headings
Location  Lat  Long  Time  ID  Mon

I need the location from file jg.table, which has the following info: lat and long are the fourth and fifth columns, and time is the last column.

Code:
1611400 Nawiliwili  Hawaii  21.955 -159.357    1.5271 1955-2006
1612340 Honolulu    Hawaii  21.307 -157.867    1.4984 1905-2006
1612480 Mokuoloe    Hawaii  21.437 -157.793    1.3076 1957-2006
1615680 Kahului     Hawaii  20.898 -156.472    2.3161 1947-2006
1617760 Hilo        Hawaii  19.730 -155.057    3.2686 1927-2006

Then I need the ID and mon from the list Cmonu.list in which the id is the first part and the mon is the information following it:
Code:
ANP1-Ground,Pillar
ANP2-Ground,Pillar
AOML-Ground,Pillar
ARP3-Ground,Pillar
AV09-Ground,Braced
BARH-Roof,Middle
BRMU-Roof,Middle

Let me know if this isn't what you're looking for or if you need anything else!

Last edited by Scott; 07-19-2010 at 03:11 PM.. Reason: Added more code tags
 

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

MySql: create table error

Hi, iam learning MySql. Iam trieing to create a table in the database "guestbook" at the command line in mysql heres what i type but i get a error mysql>create table guestbook ->( -> name varchar(40) null. -> url varchar(40) null. -> comments ... (3 Replies)
Discussion started by: perleo
3 Replies

2. Shell Programming and Scripting

create new table/field

Dear Folks, If I have 2 files, say A and B in format: A: $1 $2 01032 12856 01041 13351 01042 11071 01042 12854 01042 12862 01042 12866 . . . and B: (2 Replies)
Discussion started by: Gr4wk
2 Replies

3. Shell Programming and Scripting

How to create a C structure using table description.

There is table 'DEPT' in the database with the following desciption: Name Null? Type ------- -------- ------------------------ DEPTNO NOT NULL NUMBER(2) DNAME NULL VARCHAR2(14) LOC NULL VARCHAR2(13) Using shell script, I need to create a structure for the... (2 Replies)
Discussion started by: ehari
2 Replies

4. Shell Programming and Scripting

to create an output file as a table

Hi, I have four input files and would like to create an output file as a table. Please check the example below. File 1. 111111 222222 333333 444444 File 2. 555555 666666 777777 888888 File 3. aaaaa bbbbb ccccc ddddd (2 Replies)
Discussion started by: marcelus
2 Replies

5. Shell Programming and Scripting

Create table

Hi I want create table based on csv file .I have come up with some informations getting columns names and then no idea from that .Please any help file.txt col1|col2|col3|col4|col5 1234|zxxxx|xcvvv|300|null file.sh file=$1 c1=`head -1 $file|tr "|" "\n" |cat -n` echo "$c1"... (31 Replies)
Discussion started by: mohan705
31 Replies

6. UNIX and Linux Applications

create table via stored procedure (passing the table name to it)

hi there, I am trying to create a stored procedure that i can pass the table name to and it will create a table with that name. but for some reason it creates with what i have defined as the variable name . In the case of the example below it creates a table called 'tname' for example ... (6 Replies)
Discussion started by: rethink
6 Replies

7. Shell Programming and Scripting

Create Pivot table

I would like to use awk to parse a file with three columns in, like: Chennai,01,1 Chennai,07,1 Chennai,08,3 Chennai,09,6 Chennai,10,12 Chennai,11,19 Chennai,12,10 Chennai,13,12 Kerala,09,2 AP,10,1 AP,11,1 Delhi,13,1 Kerala,13,3 Chennai,00,3 Chennai,01,1 Chennai,02,1 Chennai,07,5 (3 Replies)
Discussion started by: boston_nilesh
3 Replies

8. Shell Programming and Scripting

Create Script from table

I have a table ABC with 4 columns and below data Col1,Col2,Col3,Col4 prod,10,12,joba prod,10,11,jobb qa,10,12,jobc I want to create an output file like this Server:prod StartTime:10 EndTime:12 JobName:joba Server:prod StartTime:10 EndTime:11 JobName:jobb (3 Replies)
Discussion started by: traininfa
3 Replies

9. Shell Programming and Scripting

Create table using tbl command

Hi, I required the output like attached: I tried using the below command and i'm getting error: file with data: .TS box; cB s s c|c|c PO Download statistics - Host to SOM Time;Receive Time;Processing Time;PO count 4.30 AM OMHPO File;Tue Feb 21 04:39:55 EST 2012;Tue Feb... (3 Replies)
Discussion started by: cns1710
3 Replies

10. Shell Programming and Scripting

Create table within awk-if statement

Hi I am trying to create a table within an awk if statement awk -F, '{ if ($8 ~ /Match/) BEGIN{print "<table>"} {print "<tr>";for(i=1;i<=NF;i++)print "<td>" $i"</td>";print "</tr>"} END{print "</table>"}' SN1.csv | mailx -s "Your details" abc@123.com But this doesnt work.. Please suggest (8 Replies)
Discussion started by: sidnow
8 Replies
NAD2NAD(1)                                                    General Commands Manual                                                   NAD2NAD(1)

NAME
nad2nad - North American Datum conversion filter SYNOPSIS
nad2nad [ -eEfihortwW [ args ] ] [ +args ] file[s] DESCRIPTION
Program nad2nad is a filter to convert data between North America Datum 1927 (NAD27) and North American Datum 1983. nad2nad can optionally process both State Plane Coordinate System (SPCS) and Universal Transverse Mercator (UTM) grid data as well as geographic data for both input and output. This can also be accomplished with the cs2cs program. The following control parameters can appear in any order: -[i|o] keyword[,keyword] The -i and -o option expect keyword arguments which define various characteristics and processing modes of the respective input data. Usage allows multiple arguments to be included with a - operator when separated by commas. Datum conversion requires the data to be in geographic coordinates, but nad2nad will allow conversion of data to and from SPCS or UTM grid systems. The following are keywords and arguments recognized by both the -i and -o that will apply to respective input and output conversion of user data to internal geographic coordinates: 27|83 datum of data utm=n UTM coordinates in meters for zone n spcs=n for data in SPCS coordinates, where n is state zone number. feet data units are in U.S. Surveyor's feet. This is allowed only when the spcs option been previously used. Default coordi- nates are in meters. bin for data in binary form. rev data in lat-lon order rather than default lon-lat order. hp=ss use high precision conversion zone ss. Certain States have ancillary correction tables to further refine the basic conus table. Ss key and States are: FL Florida MD Maryland TN Tennessee WI Wisconsin WO Washington, Oregon and northern part of California. -ta A specifies a character employed as the first character to denote a control line to be passed through without processing. This option applicable to ascii input only. (# is the default value). -e string String is an arbitrary string to be output if an error is detected during data transformations. The default value is: * *. Note that if the -o bin option is employed, an error is output as HUGE_VAL for both values. -r region specifies which regional conversion table to employ which are identified by the following: conus - conterminous 48 States alaska - State of Alaska hawaii - State of Hawaii prvi - Puerto Rico and Virgin Islands stgeorge - St. George Is, Alaska stpaul - St. Paul Is, Alaska stlrnc - St. Lawrence Is, Alaska -E Input coordinates are echoed to output before ouput values. -f format Format is a printf format string to control the form of the output values. For inverse projections, the output will be in degrees when this option is employed. If a format is specified for inverse projection the output data will be in decimal degrees. The default format is %.2f for forward projection and DMS for inverse. -[w|W]n N is the number of significant fractional digits to employ for seconds output (when the option is not specified, -w3 is assumed). When -W is employed the fields will be constant width and with leading zeroes. One or more files (processed in left to right order) specify the source of data to be transformed. A - will specify the location of pro- cessing standard input. If no files are specified, the input is assumed to be from stdin. For ASCII input data the two data values must be in the first two white space separated fields and when both input and output are ASCII all trailing portions of the input line are appended to the output line. Input geographic data (longitude and latitude) must be in DMS format when neither utm nor spcs is specified, otherwise in meters or feet (feet option used). Input data fields must be separated by white space and not have imbedded white space. Output data will be in tab separated fields of DMS or grid coordinates in meters or feet. Any data after the two input values are echoed after the two output data values. SEE ALSO
cs2cs(1U), proj(1U), Cartographic Projection Procedures for the UNIX Environment--A User's Manual, (Evenden, 1990, Open-file report 90-284). HOME PAGE
http://www.remotesensing.org/proj 2000/03/21 Rel. 4.4 NAD2NAD(1)
All times are GMT -4. The time now is 11:24 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy