Sponsored Content
Top Forums UNIX for Advanced & Expert Users Comparing wc outputs using array Post 302941788 by Deena1984 on Tuesday 21st of April 2015 07:24:11 AM
Old 04-21-2015
Thanks for the reply Rudic,

Yes, I have directed the o/p to log file. but in that log file,it simply writes all the wordcounts and row counts . doesn't do any matching comparison

Code:
 
Srccnt :
 715
441
232
273
2455
201
869
372
201
30652
339
224
1465
38439
descnt
 715
441
232
273
2455
201
869
372
201
30652
339
224
1465
38439

Can you help me in starting up with table match as you said..
Many thanks in advance

---------- Post updated at 06:24 AM ---------- Previous update was at 06:20 AM ----------

Can I store both the values in array and do comparison. could you guide me on this
 

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

Printing outputs using awk.

I have a output of a command like this. the command is : bdf|sed '/^e/d'|awk '{print$2/1048576}' output : 0 0.515625 0.481979 2 2 2 7.8125 4 2 0.488281 7.8125 3.90625 4 1.95312 1 0.488281 (4 Replies)
Discussion started by: Krrishv
4 Replies

2. Shell Programming and Scripting

compare 2 outputs

Hello, I have a shell script that is used as follows: ./script -s <Oracle_server_name> the script returns several lines in this format: parameter name required value Current Value comments --------------- ------------- -------------- --------- My objective now is to compare 2... (1 Reply)
Discussion started by: melanie_pfefer
1 Replies

3. UNIX for Dummies Questions & Answers

Comparing two strings those are outputs of echo

Hello, I have two strings those are outputs of two echo commands: $ logslist=`ls -1rt vp_lb_indv*.log | tail -1`; tail -7 $logslist | head -1 ERROR: Errors printed on pages 5,22. $ logslist=`ls -1rt vp_lb_indv*.log | tail -1`; errpages=`tail -7 $logslist | head -1`; echo... (3 Replies)
Discussion started by: memoconq
3 Replies

4. Shell Programming and Scripting

comparing variables in awk array

Hi, I am trying to sort and display the below(like) input using awk command: Input: ------ 0;A 4;A 5;A 33;A 45;A 0;B 4;B 5;B 33;B 45;B Output (desired): (5 Replies)
Discussion started by: pvamsikr
5 Replies

5. Shell Programming and Scripting

create outputs from other command outputs

hi friends, The code: i=1 while do filename=`/usr/bin/ls -l| awk '{ print $9}'` echo $filename>>summary.csv #Gives the name of the file stored at column 9 count=`wc -l $filename | awk '{print $1}'` echo $count>>summary.csv #Gives just the count of lines of file "filename" i=`expr... (1 Reply)
Discussion started by: rajsharma
1 Replies

6. Shell Programming and Scripting

Array in awk outputs multiple values

Disclaimer: OP is 100% Awk beginner. I use this code on ASCII files I need to report against. awk 'BEGIN { tokens = 0 tokens = 0 tokens = 0 } { for (token in tokens) { if ($1 == token){print $0; tokens++;}}} END {for (token in tokens){ if( tokens ==... (1 Reply)
Discussion started by: alan
1 Replies

7. Shell Programming and Scripting

Comparing two array in shell script

In shell script i have two variables with value debit_sal="DOG,HIU,JIU,GYT,PPI,KIU,HUY........." debit_req='HIU, JIU, HUY, GTR, KOI, ............" i stored this two in two array arr=$(echo $debit_sal| tr "," "\n"); arr1=$(echo $debit_req| tr ", " "\n"); #(note second arry has comma with... (5 Replies)
Discussion started by: greenworld123
5 Replies

8. UNIX for Dummies Questions & Answers

Need help with 2 similar commands with different outputs

NEVERMIND.... "$TIME" did the trick... stupid me. :o Hi, I know that this must be something pretty dumb but I cant figure it out myself. I have this: #!/bin/bash TIME="Time: 20120611" FILE=file.log grep $TIME $FILE And I get the following output: file.log:Time: 20120611... (2 Replies)
Discussion started by: RedSpyder
2 Replies

9. UNIX for Dummies Questions & Answers

gunzip outputs gibberish

I run cygwin on windows 7, and have been using the windows command line. I've been trying to gunzip some previously compressed large sequence output files in .txt.gz format. This worked for about the first 10 files and then for the rest of them the file (as viewed using the 'head' command) is... (1 Reply)
Discussion started by: woceht
1 Replies

10. Shell Programming and Scripting

Comparing files in a directory against an array of files

I hope I can explain this correctly. I am using Bash-4.2 for my shell. I have a group of file names held in an array. I want to compare the names in this array against the names of files currently present in a directory. If the file does not exist in the directory, that is not a problem.... (5 Replies)
Discussion started by: BudMan
5 Replies
iconv_1251(5)						Standards, Environments, and Macros					     iconv_1251(5)

NAME
iconv_1251 - code set conversion tables for MS 1251 (Windows Cyrillic) DESCRIPTION
The following code set conversions are supported: +-------------------------------------------------------------------------+ | Code Set Conversions Supported | +--------------+--------+--------------+--------+-------------------------+ | Code |Symbol |Target Code |Symbol | Target Output | +--------------+--------+--------------+--------+-------------------------+ |MS 1251 |win5 |ISO 8859-5 |iso5 | ISO 8859-5 Cyrillic | +--------------+--------+--------------+--------+-------------------------+ |MS 1251 |win5 |KOI8-R |koi8 | KOI8-R | +--------------+--------+--------------+--------+-------------------------+ |MS 1251 |win5 |PC Cyrillic |alt | Alternative PC Cyrillic | +--------------+--------+--------------+--------+-------------------------+ |MS 1251 |win5 |Mac Cyrillic |mac | Macintosh Cyrillic | +--------------+--------+--------------+--------+-------------------------+ CONVERSIONS
The conversions are performed according to the following tables. All values in the tables are given in octal. MS 1251 to ISO 8859-5 For the conversion of MS 1251 to ISO 8859-5, all characters not in the following table are mapped unchanged. +-----------------------------------------------------------------+ | | Conversions|Performed | | | MS 1251 | ISO 8859-5 | MS 1251 | ISO 8859-5 | |24 | 4 |310 |270 | |200 | 242 |311 |271 | |201 | 243 |312 |272 | |202 | 40 |313 |273 | |203 | 363 |314 |274 | |204-207 | 40 |315 |275 | |210 | 255 |316 |276 | |211 | 40 |317 |277 | |212 | 251 |320 |300 | |213 | 40 |321 |301 | |214 | 252 |322 |302 | |215 | 254 |323 |303 | |216 | 253 |324 |304 | |217 | 257 |325 |305 | |220 | 362 |326 |306 | |221-227 | 40 |327 |307 | |230 | 255 |330 |310 | |231 | 40 |331 |311 | |232 | 371 |332 |312 | |233 | 40 |333 |313 | |234 | 372 |334 |314 | |235 | 374 |335 |315 | |236 | 373 |336 |316 | |237 | 377 |337 |317 | |241 | 256 |340 |320 | |242 | 376 |341 |321 | |243 | 250 |342 |322 | |244-247 | 40 |343 |323 | |250 | 241 |344 |324 | |251 | 40 |345 |325 | |252 | 244 |346 |326 | |253-254 | 40 |347 |327 | |255 | 55 |350 |330 | |256 | 40 |351 |331 | |257 | 247 |352 |332 | |260-261 | 40 |353 |333 | |262 | 246 |354 |334 | |263 | 366 |355 |335 | |264-267 | 40 |356 |336 | |270 | 361 |357 |337 | |271 | 360 |360 |340 | |272 | 364 |361 |341 | |273 | 40 |362 |342 | |274 | 370 |363 |343 | |275 | 245 |364 |344 | |276 | 365 |365 |345 | |277 | 367 |366 |346 | |300 | 260 |367 |347 | |301 | 261 |370 |350 | |302 | 262 |371 |351 | |303 | 263 |372 |352 | |304 | 264 |373 |353 | |305 | 265 |374 |354 | |306 | 266 |375 |355 | |307 | 267 |376 |356 | +---------------+----------------+----------------+---------------+ MS 1251 to KOI8-R For the conversion of MS 1251 to KOI8-R , all characters not in the following table are mapped unchanged. +-----------------------------------------------------------------+ | | Conversions|Performed | | | MS 1251 | KOI8-R | MS 1251 | KOI8-R | |24 | 4 |310 |351 | |200 | 261 |311 |352 | |201 | 262 |312 |353 | |202 | 40 |313 |354 | |203 | 242 |314 |355 | |204-207 | 40 |315 |356 | |210 | 255 |316 |357 | |211 | 40 |317 |360 | |212 | 271 |320 |362 | |213 | 40 |321 |363 | |214 | 272 |322 |364 | |215 | 274 |323 |365 | |216 | 273 |324 |346 | |217 | 277 |325 |350 | |220 | 241 |326 |343 | |221-227 | 40 |327 |376 | |230 | 255 |330 |373 | |231 | 40 |331 |375 | |232 | 251 |332 |377 | |233 | 40 |333 |371 | |234 | 252 |334 |370 | |235 | 254 |335 |374 | |236 | 253 |336 |340 | |237 | 257 |337 |361 | |241 | 276 |340 |301 | |242 | 256 |341 |302 | |243 | 270 |342 |327 | |244-247 | 40 |343 |307 | |250 | 263 |344 |304 | |251 | 40 |345 |305 | |252 | 264 |346 |326 | |253-254 | 40 |347 |332 | |255 | 55 |350 |311 | |256 | 40 |351 |312 | |257 | 267 |352 |313 | |260-261 | 40 |353 |314 | |262 | 266 |354 |315 | |263 | 246 |355 |316 | |264-267 | 40 |356 |317 | |270 | 243 |357 |320 | |271 | 260 |360 |322 | |272 | 244 |361 |323 | |273 | 40 |362 |324 | |274 | 250 |363 |325 | |275 | 265 |364 |306 | |276 | 245 |365 |310 | |277 | 247 |366 |303 | |300 | 341 |367 |336 | |301 | 342 |370 |333 | |302 | 367 |371 |335 | |303 | 347 |372 |337 | |304 | 344 |373 |331 | |305 | 345 |374 |330 | |306 | 366 |375 |334 | |307 | 372 |376 |300 | +---------------+----------------+----------------+---------------+ MS 1251 to PC Cyrillic For the conversion of MS 1251 to PC Cyrillic, all characters not in the following table are mapped unchanged. +-----------------------------------------------------------------+ | | Conversions|Performed | | | MS 1251 | PC Cyrillic | MS 1251 | PC Cyrillic | |24 | 4 |332 |232 | |200-207 | 40 |333 |233 | |210 | 260 |334 |234 | |211-227 | 40 |335 |235 | |230 | 260 |336 |236 | |231-247 | 40 |337 |237 | |250 | 360 |340 |240 | |251-254 | 40 |341 |241 | |255 | 55 |342 |242 | |256-267 | 40 |343 |243 | |270 | 361 |344 |244 | |271-277 | 40 |345 |245 | |300 | 200 |346 |246 | |301 | 201 |347 |247 | |302 | 202 |350 |250 | |303 | 203 |351 |251 | |304 | 204 |352 |252 | |305 | 205 |353 |253 | |306 | 206 |354 |254 | |307 | 207 |355 |255 | |310 | 210 |356 |256 | |311 | 211 |357 |257 | |312 | 212 |360 |340 | |313 | 213 |361 |341 | |314 | 214 |362 |342 | |315 | 215 |363 |343 | |316 | 216 |364 |344 | |317 | 217 |365 |345 | |320 | 220 |366 |346 | |321 | 221 |367 |347 | |322 | 222 |370 |350 | |323 | 223 |371 |351 | |324 | 224 |372 |352 | |325 | 225 |373 |353 | |326 | 226 |374 |354 | |327 | 227 |375 |355 | |330 | 230 |376 |356 | |331 | 231 | | | +---------------+----------------+----------------+---------------+ MS 1251 to Mac Cyrillic For the conversion of MS 1251 to Mac Cyrillic, all characters not in the following table are mapped unchanged. +-----------------------------------------------------------------+ | | Conversions|Performed | | | MS 1251 | Mac Cyrillic | MS 1251 | Mac Cyrillic | |24 | 4 |260 |241 | |200 | 253 |262 |247 | |201 | 256 |263 |264 | |202 | 40 |264 |266 | |203 | 257 |266 |246 | |204 | 327 |267 |245 | |205 | 311 |270 |336 | |206 | 240 |271 |334 | |207-211 | 40 |272 |271 | |212 | 274 |273 |310 | |213 | 40 |274 |300 | |214 | 276 |275 |301 | |215 | 315 |276 |317 | |216 | 40 |277 |273 | |217 | 332 |300 |200 | |220 | 254 |301 |201 | |221 | 324 |302 |202 | |222 | 325 |303 |203 | |223 | 322 |304 |204 | |224 | 323 |305 |205 | |225 | 40 |306 |206 | |226 | 320 |307 |207 | |227 | 321 |310 |210 | |230 | 40 |311 |211 | |231 | 252 |312 |212 | |232 | 275 |313 |213 | |233 | 40 |314 |214 | |234 | 277 |315 |215 | |235 | 316 |316 |216 | |236 | 40 |317 |217 | |237 | 333 |320 |220 | |240 | 312 |321 |221 | |241 | 330 |322 |222 | |242 | 331 |323 |223 | |243 | 267 |324 |224 | |244 | 377 |325 |225 | |245 | 242 |326 |226 | |246 | 40 |327 |227 | |247 | 244 |330 |230 | |250 | 335 |331 |231 | |252 | 270 |332 |232 | |253 | 307 |333 |233 | |254 | 302 |334 |234 | |255 | 55 |335 |235 | |256 | 250 |336 |236 | |257 | 272 |337 |237 | |355 | 316 | | | +---------------+----------------+----------------+---------------+ FILES
/usr/lib/iconv/*.so conversion modules /usr/lib/iconv/*.t conversion tables /usr/lib/iconv/iconv_data list of conversions supported by conversion tables SEE ALSO
iconv(1), iconv(3C), iconv(5) SunOS 5.10 18 Apr 1997 iconv_1251(5)
All times are GMT -4. The time now is 02:32 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy