I have two columns with numbers arranged as follows:
Now I need them arranged as follows:
I got the hint that this should be possible with awk, but did not find a command to write information from two different lines of the input-file in the same line of the output-file. (like for example x2 and y3)
Thanks for your support.
Next time use CODE-tags when posting code, data or logs to enhance readability and keep formatting like indention etc., ty.
Last edited by zaxxon; 07-17-2009 at 02:07 AM..
Reason: code tags
I have a file that is semi-colon delimited and the column headers are always the same but the column number is totally random each time this file is generated. I don't have the skills to make a script for this so maybe someone can help.
I would like to be able to take this file which has over... (11 Replies)
looking to do the following...
What the data looks like
server1 02/01/2008 groups 10
server1 03/01/2008 groups 15
server1 04/01/2008 groups 20
server2 02/01/2008 users 50
server2 03/01/2008 users 75
server2 04/01/2008 users 100
server2 04/01/2008 users 125
What I would like the... (1 Reply)
Hi , I am struck while coding AWK script. Need your help to convert rows into columns. I should copy only those rows which are marked to Y in a file and ignore N rows. Please help me find a solution.
input file
1|abc|Y
2|cdf|Y
3|efg|N
4|xyz|Y
my output should be something like this... (2 Replies)
hi friends,
i am able to parse cvs diff file using bit of cut and grep commands to produce following output in text file
'''cvs-diff.txt'''
Package-Name = dev-freetype.
Old-Version = 2.4.8
New-Version = 2.4.10
Patches-removed = freetype-2.4.8-cross-compile.patch... (2 Replies)
Hi guys!
I use AWK commands under GAMS to predispose the data files to be read by GAMS.
I have a file which contains groups of data I need. Unfortunately I have the data spread in 3 rows for each subject.
Here's an example (the file is really long)
1 0 2.0956 100.00 250.00 100.00 2.0956... (4 Replies)
I have 1 row which contains abouts 20000 base64 string.
e.g:
/p4bdllBS8qcvW/69GUYej8nEv6gwt7UAYl0g==WZdjwTUQX9UEKsT/zWaZdQ==uI would like rearrange this file by base64 strings. So the output should be this ( 1 string in 1 row):
69GUYej8nEv6gwt7UAYl0g==
WZdjwTUQX9UEKsT/zWaZdQ==How could I do... (4 Replies)
Hello gurus,
I have two variable columns 1 and 2 , and their respective groups in 3 and 4
var1 var2 gr1 gr2
a b g h
c d h g
d f d h
f g h g
d r h d
p q a b
h y h g
r t g h
I want to rearrange the rows in such a way that all similarly grouped (var1 var2) pairs are together . The... (4 Replies)
Hello
I've four fields . They are First Name, Last Name, Age, Country. So when I run a Unix command, I get below output with these fields comes every time in different order as you can see. Some times first name is the first row and other time last name is first row in the output and etc etc..... (9 Replies)
Discussion started by: rprpr
9 Replies
LEARN ABOUT PHP
pdoexception
PDOEXCEPTION(3) 1 PDOEXCEPTION(3)The PDOException classINTRODUCTION
Represents an error raised by PDO. You should not throw a PDOException from your own code. See Exceptions for more information about
Exceptions in PHP.
CLASS SYNOPSIS
PDOException
PDOExceptionextends
RuntimeException
Properties
o public array$errorInfo
o protected string$code
Inherited properties
o protected string$message
o protected int$code
o protected string$file
o protected int$line
Inherited methods
o finalpublic string Exception::getMessage (void )
o finalpublic Exception Exception::getPrevious (void )
o finalpublic mixed Exception::getCode (void )
o finalpublic string Exception::getFile (void )
o finalpublic int Exception::getLine (void )
o finalpublic array Exception::getTrace (void )
o finalpublic string Exception::getTraceAsString (void )
o public string Exception::__toString (void )
o finalprivate void Exception::__clone (void )
PROPERTIES
o $errorInfo
- Corresponds to PDO.errorInfo(3) or PDOStatement.errorInfo(3)
o $code
- SQLSTATE error code. Use Exception.getCode(3) to access it.
PHP Documentation Group PDOEXCEPTION(3)