On Mon, 2002-03-04 at 14:07, Antony Stace wrote: > > > > RRexportflag=yes > > XXexportflag=no > > > > for i in `cat companies` > > do > > > > if [ $iexportflag = "yes" ] ; then > > > > ...do some exporting ... > > > > fi > > done > > > The problem I have is that the $iexportflag becomes RRexportflag and Not the > > value (yes) which is what I want. > > you might want to try using "==" (equality check) instead of "="(assignment) >
I don't think this is the problem the poster is having. >From what I understand, he wants to use an anonymous variable and I don't think you can do that with shell. You might have to look at doing this another way (case statement?) Greeno -- Tony Green <[EMAIL PROTECTED]> Tel : +61-(0)2-9500-9996 Mobile : +61-(0)4-2521-9996 GnuPG Key : 1024D/B5657C8B Key fingerprint = 9ED8 59CC C161 B857 462E 51E6 7DFB 465B B565 7C8B -- SLUG - Sydney Linux User Group Mailing List - http://slug.org.au/ More Info: http://lists.slug.org.au/listinfo/slug
