Sponsored Content
Full Discussion: test and if condition
Top Forums Shell Programming and Scripting test and if condition Post 302123810 by ciroredz on Wednesday 27th of June 2007 09:15:01 AM
Old 06-27-2007
Sorry m8........my mistake....it works!!!!!!!!!!!!!!!!
thnx a lot.
1 more question
Id like to show next to the Group the name of the group which the file belngs.
How do i do that?
 

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

need help with test condition in shell script

I'm new to scripting and I need help with a bourn shell script. What i'm trying to do is a test condition where "if the time is within 2 hours, it's true" and so on. The time is in the following format DATE=`/bin/date +"%Y%m%d%H%S"` for example, 20060907152000. So, what the script first... (9 Replies)
Discussion started by: pieman8080
9 Replies

2. Shell Programming and Scripting

Condition test ( [[ ]] ) doubt

Hi , I have a doubt on condition test ( ] ). Pls refer blow program. #!/bin/ksh TEMP= if ;then echo $TEMP else print 'invalid option' fi Above script's TEMP variable has no value so it gives "invalid option" as output. But I got an error before priting the string . Result : ... (2 Replies)
Discussion started by: thambi
2 Replies

3. UNIX for Dummies Questions & Answers

Condition test

Hi there, When I try to do a condition on test: $ str1=abcd $ test $str1 $ echo $? 0 Is there anyway to display the answer to be 'TRUE' or 'YES'? rather than 0? If so, how can I do it without using awk or sed. (2 Replies)
Discussion started by: felixwhoals
2 Replies

4. Shell Programming and Scripting

Test condition

Hello, what is the better and correct way to perform a comparison: I have been using the following with no problems: if ] then .... fi I have seen this also used : if then .... fi When I try : if then .... fi I get an error like .... the test condition expects a... (4 Replies)
Discussion started by: gio001
4 Replies

5. Shell Programming and Scripting

test condition

Hi there, I tried to search for this almost everywhere, but didnt get any proper information on it. What is the difference between ] Some of the code works when I have only single condition i.e. ] && $dothis1 || $dothis2 But if i try to include another testcondition to the... (1 Reply)
Discussion started by: tostay2003
1 Replies

6. Shell Programming and Scripting

How to check weather a string is like test* or test* ot *test* in if condition

How to check weather a string is like test* or test* ot *test* in if condition (5 Replies)
Discussion started by: johnjerome
5 Replies

7. UNIX for Advanced & Expert Users

Condition to test if a host can be pinged

I have a much larger script that takes an input file of hosts and determines if we support them and checks to ensure the FQDN coincides with our DNS. For instance, the hostname may return a different FQDN when passed to the "host" command, so I keep the value of the output of the "host" command... (4 Replies)
Discussion started by: MaindotC
4 Replies

8. UNIX for Advanced & Expert Users

Lower case test condition

I want to locate directories that are upper, lower or have both upper and lower cases. What I have is: find /tmp/$var2 -type d' " ); && echo "host case is incorrect" || echo "host case is correct" This actually is part of a larger script and it does work but the problem is that it... (3 Replies)
Discussion started by: newbie2010
3 Replies

9. UNIX for Dummies Questions & Answers

Simple negated test condition

Without grep, I'd like to make a test condition so that any a word that does not have the successive letters car in it will be echoed. for example, bluecar will contain "car" so it will show up as a no var=bluecar $ echo $var|if ]; then echo "yes";fi yes this variable contains "car" so I... (5 Replies)
Discussion started by: newbie2010
5 Replies

10. UNIX for Beginners Questions & Answers

Test a condition for n times and take action

i have to test a condition for n times and if its value is greater than one each time for continuous 5 iterations it will take action My Approach run the same command 5 times in for loop and divert the output to a file and then read the values from file and use if else if and take action ... (1 Reply)
Discussion started by: abhaydas
1 Replies
Group(3pm)						  LogReport's Lire Documentation						Group(3pm)

NAME
Lire::Report::Group - Object that include subgroups and other entries. SYNOPSIS
foreach my $e ( $group->entries() ) { # Process entries' data. } DESCRIPTION
The Lire::Report::Group object contains entries grouped together in a subreport. CONSTRUCTOR
You create new Lire::Report::Group object by calling the create_group() method on one Lire::Report::Entry object. OBJECT METHODS
parent_entry() Returns the entry in which this goup is contained. This will be undef for the Subreport since it's not contained in any entry. group_info() Returns the Lire::Report::GroupInfo which contains the information describing the entries of this group. subreport() Returns the Lire::Report::Subreport object in which this entry is row_idx() Returns the row index in the table body where this group's summary should be displayed. If undef, this group isn't displayed. show( [$show] ) Returns the number of entries that should be displayed in the formatted report. There may be more entries than that in the group. When this parameter is zero or undefined, all available entries should be displayed. If the $show is parameter is set, the group's show parameter will be set to this new value. nrecords( [$n] ) Returns the number of DLF records that were included in this group. missing_cases( [$n] ) Returns the number of DLF records that contained missing cases which prevent them from being unclude in the subreport. summary_values() Returns the summary values of this group. This is an array of hash reference like the ones returnes by the values() method described in Lire::Report::Entry(3pm). get_summary_value( $name ) Returns the summary value of the operator $name. This is an hash reference like is returned by the values() method described in Lire::Report::Entry(3pm). Returns undef if the summary value wasn't computed for operator $name. set_summary_value( $name, %value ) Sets the value of the operator $name computed over all the DLF records of the group. Consult the add_value() method in Lire::Report::Entry(3pm) for information on the parameters. entries() Returns the entries in the group. create_entry() Adds a data entry to this group. This will create a new Lire::Report::Entry object which can then be filled with data. find_entry( $name, $dlf ) SEE ALSO
Lire::ReportParser::ReportBuilder(3pm) Lire::Report(3pm) Lire::Report::Subreport(3pm) Lire::Report::Entry(3pm) Lire::Report::ChartConfig(3pm) Lire::Report::Section(3pm) VERSION
$Id: Group.pm,v 1.33 2006/07/23 13:16:31 vanbaal Exp $ COPYRIGHT
Copyright (C) 2002 Stichting LogReport Foundation LogReport@LogReport.org This file is part of Lire. Lire is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program (see COPYING); if not, check with http://www.gnu.org/copyleft/gpl.html. AUTHOR
Francis J. Lacoste <flacoste@logreport.org> Lire 2.1.1 2006-07-23 Group(3pm)
All times are GMT -4. The time now is 03:58 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy