The UNIX and Linux Forums  

Go Back   The UNIX and Linux Forums > Top Forums > Shell Programming and Scripting
Google UNIX.COM


Shell Programming and Scripting Post questions about KSH, CSH, SH, BASH, PERL, PHP, SED, AWK and OTHER shell scripts here.

More UNIX and Linux Forum Topics You Might Find Helpful
Thread Thread Starter Forum Replies Last Post
Split BIG report using nawk raychu65 UNIX for Dummies Questions & Answers 1 01-24-2008 03:42 AM
Split a Big Report. raychu65 Shell Programming and Scripting 16 01-23-2008 01:16 AM
Split a file with no pattern -- Split, Csplit, Awk madhunk UNIX for Dummies Questions & Answers 10 12-17-2007 09:57 AM
sar report to xml converter gogogo Shell Programming and Scripting 0 07-24-2007 11:48 AM
Report to PDF Croney69 UNIX for Dummies Questions & Answers 5 06-09-2005 10:37 AM

Reply
 
Submit Tools LinkBack Thread Tools Search this Thread Display Modes
  #1  
Old 03-20-2006
Registered User
 

Join Date: Jan 2006
Posts: 72
need help to split report

I wrote one script to generate total number of Test cases failures of system as per the host and version .

I want to split number of test cases failures, as per the product .

The logs contain output .

I want to generate output like this


Version Host DB OPC Proxeco Total
7 Eagle 20 10 5 35
7.1 Animator 35 40 2 77
8 Eagle 20 5 4 29


I am posting my scripts and test log also . Please help me to divide it into further part.



_-------------------------------------------------------------------------
#!/bin/sh

#sh gdata.sh /users/testsuite/db/SiCat/

DATE=`date '+20%y-%m-%d'`

for i in /users/testsuite/db/SiCat/$DATE/* ; do

## It generates the total sum of failuers as per the host and productwise .

find $i -name daily -prune -o -name run.log -print -exec grep -c ! {} \;;done > /users/testsuite/db/SiCat/SiCathist/$DATE.log


cat /users/testsuite/db/SiCat/SiCathist/$DATE.log | paste - - | tr "/" " " | cut -d" " -f7,8,9 | sed -e 's/run.log/ /g'> /users/testsuite/db/SiCat/SiCathist/$DATE.log
Reply With Quote
Forum Sponsor
  #2  
Old 03-20-2006
Registered User
 

Join Date: Jan 2006
Posts: 72
waiting for reply pls help me
Reply With Quote
  #3  
Old 03-20-2006
Registered User
 

Join Date: Jan 2006
Posts: 72
currently it is generating output

7 Animator 50
8 eagle 30
8 Animator 15


but i want to split total number of failuers as per the DB , Proxeco and other

i can hardcord this names in shell scripting .

pls help me
Reply With Quote
  #4  
Old 03-20-2006
Just Ice's Avatar
Lights on, brain off.
 

Join Date: Mar 2005
Location: in front of my computer
Posts: 629
Just a reminder from the forum rules ...

(4) Do not 'bump up' questions if they are not answered promptly. No duplicate or cross-posting and do not report a post where your goal is to get an answer more quickly.

===================================

anyways, post your complete script in between code tags --- the "#" button near the top of the edit box --- to make it look prettier and easier to debug ... also post a sample of your input file data ... people will be able to help you quicker if you help them out ...

... and while you're waiting for a response, read the current threads in the "Unix for Dummies" forum as well as do a search on splitting data in this forum --- it seems to me that a question similar to yours is posted in these forums at least once a week ... good luck!
Reply With Quote
Google The UNIX and Linux Forums
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes




All times are GMT -7. The time now is 10:01 PM.


Powered by: vBulletin, Copyright ©2000 - 2006, Jelsoft Enterprises Limited.
The UNIX and Linux Forums Content Copyright ©1993-2008. All Rights Reserved.Ad Management by RedTyger Visit The Complex Event Processing Blog

Content Relevant URLs by vBSEO 3.2.0