Software :: Get Parts Of One Column And Prints All Columns?
Dec 13, 2010
I used awk and cut command but still I did not get the output I want...
I have 6 columns in the file, and the 6th column is too long. what I want is to print all columns form 1-5 and a part of 6th column.
Example: aa bb cc dd ee ff33ff
from the above example I want only to get the 1-5 columns and the numbers from 6th column so the output shoud be as:
aa bb cc dd ee 33
View 2 Replies
ADVERTISEMENT
May 19, 2014
I'm struggling on installing a KONICA-MINOLTA printer magicolor 4695MF printing properly with Linux Mint Debian Edition (up to date). The test page works fine...
KONICA-MINOLTA delivers 2 PPDs: one for standard printing and one for OpenOffice printing (available on the KONICA-MINOLTA support site).
Leaving a side the one for OpenOffice which is poor in using the capabilities of the printer, I concentrate only on the global one (M4695PX.ppd).
It's much more difficult for other applications, starting with EVINCE: some PDF files are printed properly (i.e. those generated in OpenOffice by the CUPS PDF printer), others come out as one only blank page, regardless to the original length of the document.
So documents received from 3rd party may be "printable" or not. And trust Murphy, the most critical aren't printed...
Attached, the troubleshooting file generated by [system-config-printer] => [URL] ...
View 0 Replies
View Related
Jul 19, 2010
How would i calculate following values.Initial file
10 3
20 4
How would i calculate 3rd column which should be addition of value in 1 and 2nd column.File after calculation
10 3 13
20 4 24
View 14 Replies
View Related
Jul 15, 2010
I have a multicolumn datas, like
a1 b1 ... f1
a2 b2 ... f2
. . ... .
[code]...
I would like to make a file with all these data in one column, like
a1
a2
.
.
[code]....
Can it be done with awk or some other command? Also, is it possible then do add another column in front of this one with numbers of the lines (for every previous column), like
1 a1
2 a2
. .
. .
[code].....
View 14 Replies
View Related
Mar 7, 2010
i use this script to get the time and date of back and fourth transactions for a particular execution id. I use a substr command on the 5th column to to cut the milli seconds off the time value. - otherwise the times would look like 08:30:04.235
grep <executionID> <auditfile> | awk '{ print $1, $2, $3, $4, substr($5,1,8}
FIX -> Mon 3/1/2010 08:30:04
FIX <- Mon 3/1/2010 08:32:36
FIX <- Mon 3/1/2010 08:35:08
[code].....
anyhow - i append two sed commands to further clarify the direction of the message.
awk '{ print $1, $2, $3, $4, substr($5,1,8} | sed -e 's/->/ ->IN/g' | sed -e 's/<-/<-OUT/g'
FIX -> IN Mon 3/1/2010 08:30:04
FIX <- OUT Mon 3/1/2010 08:32:36
[code]....
I tried using an awk gsub () command within the string instead of the two seds, but it did not work:
awk '{ print gsub(/<regex>/, <replace with>,$1), $2, $3, $4, substr($5,1,8}
the sed works ok, but it would be cooler to make the replacement within the awk command:
gsub(/->/,-> IN, $1)
Is there a way where i could replace the value of the $1 column in the awk print string?
View 1 Replies
View Related
Jun 13, 2010
I have a very dumb questions regarding run-parts utility. I've created few shell scripts, chmod them to be executable, placed them into one particular directory and tried to run them using run-parts utility like this
run-parts dir_name However it doesn't seem to be working or I might just be missing out something. I have even tried different options like --test or --list - NONE of them produced any output. If I run each of the script manually they all work just fine. Is this is a known bug or somethng ?? or am I really missing out something...how are the /etc/crontab entries then being executed when the run-parts doesn't seem to be working on such a simple case ? ps: I noticed one interesting thing though...when I run run-parts like this: run-parts --list --regex 'some_regexp_patern' dir_name -> the output actually produces a list of the files whose file names match the given regexp pattern .
View 4 Replies
View Related
Nov 7, 2010
How do I cut jpg images in two parts?
If I want to e.g. slice an jpg vertically at so and so many pixels from the bottom.
View 1 Replies
View Related
Mar 11, 2010
I just changed the printing cartridges on my printer and now it prints all red from ubuntu. However if I just print directly from the scanner there is no problem. This printer use to work no problem under ubuntu.
View 1 Replies
View Related
Apr 13, 2011
I had been playing around with various Python scripts in order to add certain columns to Nautilus, in particular bitrate, length, artist and genre for information on mp3 files. Well, I got greedy and installed something I shouldn't have and now I have massive duplicate columns available, and checking them to be visible has no effect at all. I have lost all the information that would populate the aforementioned columns.
I went to the Configuration Editor, went to apps>nautilus>list view>default visible columns and deleted the extraneous columns. I also disabled all the pythons scripts I put in ~/.nautilus/python-extensions. The extra columns never go away, and, if checked, never make visible the named information. Here is a screencap.
View 2 Replies
View Related
Aug 27, 2010
I have been messing with a2ps in order to print a text file I have that has 130 columns by 80 rows per page. It appears that a2ps automatically scales the number of rows based upon the number of columns I try to print.The file prints properly for the columns but a2ps scales the rows to be 97 rows per page. So the 80 rows print but the next 17 rows are blank. It is not scaling the font for for 80 rows.
View 1 Replies
View Related
Oct 24, 2010
How can I add columns to the right of GtkTreeView? How can I add the menu to the right of the window? How can I change the position of the icon in the GnomeMessageBox to the right of the dialog? And how can I change the arrange of the buttons from right to left in GnomeMessageBox? and position of the icon on the buttons in the GnomeMessageBox?
View 5 Replies
View Related
Jul 1, 2010
I have a file that contains a couple of email addresses and I want to extract the usernames ( Letters before @ symbol ). How can I do that using sed/awk.
I know cut will work, but the current environment doesn't allow me to use cut command. I can use either awk or sed.
View 4 Replies
View Related
Nov 14, 2010
i've got the following packages installed on a fresh fc14 installation :
cronie-1.4.5-2.fc14.i686
cronie-anacron-1.4.5-2.fc14.i686
crontabs-1.11-1.20101109git.fc14.noarch
[code]....
View 1 Replies
View Related
Mar 5, 2010
Suppose that I have this text :
1 abc
2 def
3 ghi
4 klm
Now I want to copy(yank) only the parts:
ab from line one and hi from line three at the same time
So how can this be done with vim? I know how to copy one line and one part of a line. What I want to do is to copy two parts from 2 different lines at the same time and paste them as they are some where else in the file.
View 4 Replies
View Related
Mar 11, 2010
I am completely new to Ubuntu so please make your answers really simple ! I want to set up a mail server for a home network and have been suggested I use the Ubuntu solutions. I am fairly proficient with Windows programs and even construct databases but I am a complete novice when it comes to command line instructions. Yes, I know I have been spoon fed!
I have been told that it is possible to install Server programs from the Desktop version and that they provide a GUI in most cases. Is that so? I have the desktop version running and up to date but I am unsure what to do next. Starting the Server ISO CD from Desktop seemed logical but when I did I was not sure if it was correct and backed out. I have also read a thread on this forum that suggests the use of Zimbra as a Mail Server, it sounded like my kind of solution so I think I would like to try that.
One last factor. I have an existing P2P network (2 Vista, 1 Mac Book and this Ub' desktop/server) running already which uses the Router for DNS. I suspect I am going to have to do things in a certain order if I am not going to go backwards and ruin the families email and surfing!
View 1 Replies
View Related
Jan 1, 2011
parts of my screen keep freezing and locking in place so that nothing new can be seen in that section, it happens when i click a menu or close a window, the part that freezes only goes away after i log out and then back in
View 2 Replies
View Related
Jul 10, 2009
I am having a big /home partition. I need to make it small and create one more partition from it which will be used for some other purpose. Can you tell me please how to do it?
I searched on google and found some methods which were very different from each other.I don't know which one is good, so, I thought I will ask you experts before doing anything.
View 9 Replies
View Related
May 8, 2010
I'm trying to get my program to go through the string typed in by the user and strip it of EVERYTHING but the numbers. I can't place my finger on what I'm missing.
Code:
Code: #include<iostream>
#include<string>
using namespace std ;
int main()
[Code].....
View 2 Replies
View Related
Jan 12, 2010
I have my Epson C46 working on my Ubuntu 9.10 machine, my XP machines are showing the printer as ready and will send a test page to the Ubuntu printer but it doesn't arrive at Ubuntu - doesn't show in the print job list on Ubuntu but does in XP??
File sharing is now working in both directions.
View 3 Replies
View Related
Apr 27, 2011
I have an HP J4680 all in one that, for some reason, does not process the print job immediately when I send it. When I open my printer's properties it will list the printer's state as idle and when I go into the print que it tells me the job is scheduled for . . . (some time) which is, I think, about 5 min later by the clock on the task bar. I've been all over the settings and don't see anything that looks like it applies to that. Usually I've been restarting the printer and computer and then it will print when I send the job. Tonight I waited until the time and it did print according to the scheduled time. I need to find a way to always have it print right when I send the job.
View 2 Replies
View Related
Apr 27, 2010
In spite of the fact that the printer set-up is working with the Gimp and other more involved print-capable programs.
The printer is a Dell 3100cn color laser printer.
The best driver I found was one I got off of Dell's site - it was an RPM that I aliased (I'm using Debian lenny).
I set Openoffice Writer's printer configuration to "letter."
I check the settings in the print pop-up before I print.
And then the printer asks me for A4 paper.
View 5 Replies
View Related
Aug 6, 2010
I am using xgraph with ns2. Is there any provision in xgraph to select columns. Man page didnt say anything about it.
View 1 Replies
View Related
Dec 19, 2010
I was trying to do a school assignment in LaTeX. The assignment involves having the page split into three columns: the first column is for the quote, the second is for a reaction, and the third is for questions. These columns must be able to break in the middle of a row. I was trying to accomplish this using LaTeX.
First, I tried the longtable environment, but that would not allow me to pagebreak in the middle of a row. Then, I tried parcolumns, but for some reason, the second "row" had a huge space between the first two words. Does anyone know of an environment suitable for this kind of work?
View 4 Replies
View Related
Jun 9, 2010
Say I have a text file with10 columns. I need to reorder them based on a list of column numbers that will reorder them.
My problem is this:
If I want to cut out 5 columns (columns 1,2,3,9,10) in the order 1,10,2,9,3 then I have tried using:
Code: cut -f1,10,2,9,3 my_file.txt > reordered_file.txt But this just extracts the columns in order as if I used:
Code: cut -f1,2,3,9,10 my_file.txt > reordered_file.txt How can I cut these columns and place them into the new file in the order I specify?
While this might seem quite trivial, I will actually need to do this for a file containing ~14000 columns with ~12000 columns that I need to extract in a particular order.
View 2 Replies
View Related
Mar 1, 2011
Actually build a script which can monitor the "DateTimeHourMinute" in a data file.
I wanted to compare the "DateTimeHourMinute" from the 2nd column against "DateTimeHourMinute" on the 3rd column which located in the same line.
Below is the data sample:
View 7 Replies
View Related
Mar 29, 2010
I am trying to write a script which compares a log file with reference file. The log file has a table, the LHS of the table are constants strings and RHS of table values changes if there are any changes in configuration.code...
Here I am looking for a script which compares test.log file ( whose RHS data-types are known prior whether it is digit or string) with test.Ref which is reference file for test.log file. It will be really helpful for me if any of you give some idea about writing this script.
View 2 Replies
View Related
Aug 18, 2010
I am having a souce file (say SOURCEFILE) as below with 5 columns and many rows.
pol name status loan address
123 aaa 21 100 RJY
234 bbb 31 200 RMY
345 ccc 21 300 SJY
456 ddd 41 400 pqr
i want to compare the file (say COMPAREFILE ) which is below :
123
345
I need the following output file (sayOUTPUTFILE) as below :
( ie for file COMPAREFILE i need column 2, column 4 ie name and loan from source file )
ie output file required is to be like below :
123 aaa 100
345 ccc 400
Till now iam using the following method.
1. cutting column 2nd column
2. again cutting 4th column
3. in third, step merging the 2nd and 4 th column.
method of writting single line command or any awk programme to do this in one step.
I need output file (say OUTPUTFILE) as below
View 1 Replies
View Related
Oct 10, 2010
I have three files with the following structure:
file1
1 2 3 4
5 6 7 8
[code]...
View 4 Replies
View Related
Feb 23, 2010
I have a folder with only 24 files named <number>.dat (i.e. 4.dat, 6.dat and so on) where <number> is between 0 and 256. Each file has just two columns of data and nothing else.
I'm trying to combine all the second columns ($2) together. I've been fiddling around with getline and so far have
awk '{ getline ln < "6.dat" ; print ln" "$2 }' 4.dat
which takes file 4.dat and adds $2 from 6.dat, but I want a single command to take each $2 from every file and add them to (for example) 4.dat (having $1 from 4.dat is no problem). A command that takes every file in the folder and grabs $2 and places them in a common file would be ideal. Frankly I can work around if you combine both columns from every file.
View 5 Replies
View Related
Aug 10, 2009
I bet this is a Perl one-liner (or very simple python script).I have a tab separated files in which each row looks like:Unique_Eight_Character_Sequence [3 tabs] data1~moredata1~moredata1 [3 tabs] data2~ moredata2~ moredata2 ... dataN~.The output file should have each column converted into a row (with the unique character sequence copied in for the first column), and then each "~" replaced by a comma.
View 14 Replies
View Related