On Thursday 17 January 2008 09:16:17 [EMAIL PROTECTED] wrote:
> Hi All,
>
>
>
> I am executing following command in Perl script
>
>
>
> $vw=system("mk_view $view_name ETC");
>
> if ($vw)
>
>  { print "view created successfully\n";
>
>  }
>
>
>
> When I run this command, I am getting message "view created
> successfully". But in reality command is not executing at all
>
>
>
> Please help
>
>
>
> Regards
>
> Irfan.

For most commands on most UNIX-like systems, a non-zero return value indicates 
failure and not success. Try using 'unless' instead of 'if'.

-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
http://learn.perl.org/


Reply via email to