Sponsored Content
Top Forums Shell Programming and Scripting if statement with two conditions -e, && Post 74906 by rahul123_libra on Tuesday 14th of June 2005 10:07:56 AM
Old 06-14-2005
problem

Could u please provide us with the file that u r using

As the result depends upon wether the file contains 1 record or many
 

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

using && in if statement ..

Hi All, Can some one tell me how to get run the following: data1="hello" data2="world" if then { echo "good afternnon" } else { echo " good morning" } fi The above code gives me an error ad below : ./if.h: line 3: ' (7 Replies)
Discussion started by: jisha
7 Replies

2. Shell Programming and Scripting

multiple conditions in if using && operator

VARIABLE="project" if && ] then echo "VARIABLE is not empty" fi this is not working what is wrong in the syntax?? (2 Replies)
Discussion started by: codeman007
2 Replies

3. Shell Programming and Scripting

PHP read large string & split in multidimensional arrays & assign fieldnames & write into MYSQL

Hi, I hope the title does not scare people to look into this thread but it describes roughly what I'm trying to do. I need a solution in PHP. I'm a programming beginner, so it might be that the approach to solve this, might be easier to solve with an other approach of someone else, so if you... (0 Replies)
Discussion started by: lowmaster
0 Replies

4. Programming

IF && statement problem

Hello there, My first time on the forums, glad to be here :) I'm completely new to programming in PHP and I have a question which I hope someone could help me with. I am currently using this statement: if(($session == 2) && ($item == Dagger) && ($item2 == Dagger)){ ... (5 Replies)
Discussion started by: Hero
5 Replies

5. Shell Programming and Scripting

How to write If statement using && and operator in Unix

Hi What is the syntax for if statement using && and || operator? if && ] || here its giving me an error to this if statement any suggestion?? (2 Replies)
Discussion started by: Avi
2 Replies

6. Shell Programming and Scripting

if statement with '&&' gives error

Hi, I'm using the && operator in if statement: if ; then exp $UID/$PWD@$ORACLE_SID FILE=./DUMP/$TODAY$CONCAT_STR$USERNAME.dmp STATISTICS=NONE LOG=./LOG/$TODAY$CONCAT_STR$USERNAME.log elif ; then expdp $UID/$PWD@$ORACLE_SID DIRECTORY=./DUMP/ DUMPFILE=$TODAY$CONCAT_STR$USERNAME.dmp... (8 Replies)
Discussion started by: priya001
8 Replies

7. Shell Programming and Scripting

Using && in if statement with 3 expressions

how do you write an if statement for something like if ((expr 1 >= expr 2 && expr 3 >= expr 4) && expr 5 <= expr 6) if ((TRUE && TRUE) && TRUE) then condition... i've done it this way but it doesn't seem to work. if (] && "$ex_day" -le "$curr_day" ); then condition... (3 Replies)
Discussion started by: angilulu
3 Replies

8. Shell Programming and Scripting

GNU & BSD Makefile Directives & Conditions Compatibility

Firstly, I would like to apologize if this is not the appropriate sub-forum to post about GNU/BSD makefile scripting. Though my code is in C++, because I am focusing on the makefile I thought it would go better in shell scripting. Please correct me if I am wrong. Secondly, I am not interested in... (0 Replies)
Discussion started by: AntumDeluge
0 Replies

9. Shell Programming and Scripting

SFTP Shell Script Get & Delete && Upload & Delete

Hi All, Do you have any sample script, - auto get file from SFTP remote server and delete file in remove server after downloaded. - only download specify filename - auto upload file from local to SFTP remote server and delete local folder file after uploaded - only upload specify filename ... (3 Replies)
Discussion started by: weesiong
3 Replies

10. Shell Programming and Scripting

Bash: How to use read with conditions & loops

Hello, Below I try to control that the input is good an IP : #!/bin/bash cp /home/scripts/choice_interfaces.txt /home/scripts/interfaces.txt chmod 644 /home/scripts/interfaces.txt echo -e "Please enter the network informations into the /etc/network/interfaces file, complete them below... (9 Replies)
Discussion started by: Arnaudh78
9 Replies
Mail::SPF::Mod(3pm)					User Contributed Perl Documentation				       Mail::SPF::Mod(3pm)

NAME
Mail::SPF::Mod - SPF record modifier base class DESCRIPTION
An object of class Mail::SPF::Mod represents a modifier within an SPF record. Mail::SPF::Mod cannot be instantiated directly. Create an instance of a concrete sub-class instead. Constructors The following constructors are provided: new(%options): returns Mail::SPF::Mod Abstract. Creates a new SPF record modifier object. %options is a list of key/value pairs representing any of the following options: text A string denoting the unparsed text of the modifier. name A string denoting the name of the modifier. Required if a generic Mail::SPF::Mod object (as opposed to a specific sub-class) is being constructed. domain_spec Either a plain string or a Mail::SPF::MacroString object denoting an optional "domain-spec" parameter of the mechanism. new_from_string($text, %options): returns Mail::SPF::Mod; throws Mail::SPF::ENothingToParse, Mail::SPF::EInvalidMod Abstract. Creates a new SPF record modifier object by parsing the string and any options given. Class methods The following class methods are provided: name_pattern: returns Regexp Returns a regular expression that matches any legal modifier name. Instance methods The following instance methods are provided: text: returns string; throws Mail::SPF::ENoUnparsedText Returns the unparsed text of the modifier. Throws a Mail::SPF::ENoUnparsedText exception if the modifier was created synthetically instead of being parsed, and no text was provided. name: returns string Returns the name of the modifier. params: returns string Abstract. Returns the modifier's parameters formatted as a string. A sub-class of Mail::SPF::Mod does not have to implement this method if it supports no parameters, although this is highly unlikely. stringify: returns string Formats the modifier's name and parameters as a string and returns it. You can simply use a Mail::SPF::Mod object as a string for the same effect, see "OVERLOADING". process: throws Mail::SPF::Result, Mail::SPF::Result::Error, Mail::SPF::Exception Abstract. Processes the modifier. What that means depends on the actual implementation in sub-classes. See "MODIFIER TYPES" below. This method is abstract and must be implemented by sub-classes of Mail::SPF::Mod. MODIFIER TYPES
There are different basic types of modifiers, which are described below. All of them are provided by the Mail::SPF::Mod module. Global modifiers - Mail::SPF::GlobalMod SPFv1 (RFC 4408) only knows "global" modifiers. A global modifier may appear anywhere in an SPF record, but only once. During evaluation of the record, global modifiers are processed after the last mechanism has been evaluated and an SPF result has been determined. The following additional class method is provided by Mail::SPF::GlobalMod: precedence: returns real Abstract. Returns a real number between 0 and 1 denoting the precedence of the type of the global modifier. Global modifiers present in an SPF record are processed in the order of their precedence values, 0 meaning "first". This method is abstract and must be implemented by sub-classes of Mail::SPF::GlobalMod. The following specific instance method is provided by Mail::SPF::GlobalMod: process($server, $request, $result): throws Mail::SPF::Result Abstract. Processes the modifier. What that means depends on the actual implementation in sub-classes. Takes both a Mail::SPF::Server and a Mail::SPF::Request object. As global modifiers are generally processed after an SPF result has already been determined, takes also the current Mail::SPF::Result. If the modifier wishes to modify the SPF result, it may throw a different Mail::SPF::Result object. This method is abstract and must be implemented by sub-classes of Mail::SPF::GlobalMod. Positional modifiers - Mail::SPF::PositionalMod Sender ID (RFC 4406) introduces the concept of "positional" modifiers. According to RFC 4406, a positional modifier must follow a mechanism and applies to that, and only that, mechanism. However, because this definition is not very useful, and because no positional modifiers have been defined based on it as of yet, Mail::SPF deviates from RFC 4406 as follows: A positional modifier may appear anywhere in an SPF record, and it is stateful, i.e. it applies to all mechanisms and modifiers that follow it. Positional modifiers are generally multiple, i.e. they may appear any number of times throughout the record. During evaluation of the record, positional modifiers are processed at exactly the time when they are encountered by the evaluator. Consequently, all positional modifiers are processed before an SPF result is determined. The following specific instance method is provided by Mail::SPF::PositionalMod: process($server, $request): throws Mail::SPF::Result::Error, Mail::SPF::Exception Abstract. Processes the modifier. What that means depends on the actual implementation in sub-classes. Takes both a Mail::SPF::Server and a Mail::SPF::Request object. As global modifiers are generally processed before an SPF result has been determined, no result object is available to the modifier. The modifier can (at least at this time) not directly modify the final SPF result, however it may throw an exception to signal an error condition. This method is abstract and must be implemented by sub-classes of Mail::SPF::PositionalMod. Unknown modifiers - Mail::SPF::UnknownMod Both SPFv1 and Sender ID allow unknown modifiers to appear in SPF records in order to allow new modifiers to be introduced without breaking existing implementations. Obviously, unknown modifiers are neither global nor positional, but they may appear any number of times throughout the record and are simply ignored during evaluation of the record. Also obviously, Mail::SPF::UnknownMod does not support a "process" method. The following specific instance method is provided by Mail::SPF::UnknownMod: params: returns string Returns the modifier's unparsed value as a string. OVERLOADING
If a Mail::SPF::Mod object is used as a string, the "stringify" method is used to convert the object into a string. SEE ALSO
Mail::SPF::Mod::Redirect, Mail::SPF::Mod::Exp Mail::SPF, Mail::SPF::Record, Mail::SPF::Term <http://tools.ietf.org/html/rfc4408> For availability, support, and license information, see the README file included with Mail::SPF. AUTHORS
Julian Mehnle <julian@mehnle.net>, Shevek <cpan@anarres.org> perl v5.14.2 2012-01-30 Mail::SPF::Mod(3pm)
All times are GMT -4. The time now is 03:44 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy