From owner-freebsd-current@FreeBSD.ORG Fri May 14 06:36:11 2004 Return-Path: Delivered-To: freebsd-current@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 8906916A4CE for ; Fri, 14 May 2004 06:36:11 -0700 (PDT) Received: from mail.evip.pl (mail.evip.com.pl [212.244.157.179]) by mx1.FreeBSD.org (Postfix) with ESMTP id 8BE6143D39 for ; Fri, 14 May 2004 06:36:08 -0700 (PDT) (envelope-from w@evip.pl) Received: from drwebc by mail.evip.pl with drweb-scanned (Exim 4.22) id 1BOcr6-000Jui-Qx for current@freebsd.org; Fri, 14 May 2004 15:36:04 +0200 Received: from w by mail.evip.pl with local (Exim 4.22) id 1BOcr6-000JuY-Mz for current@freebsd.org; Fri, 14 May 2004 15:36:04 +0200 Date: Fri, 14 May 2004 15:36:04 +0200 From: Wiktor Niesiobedzki To: current@freebsd.org Message-ID: <20040514133604.GA74576@mail.evip.pl> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.4i Subject: awk question (printing to the file) X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 14 May 2004 13:36:11 -0000 Hi, The GNU awk, that is present in FreeBSD-4 branch accepts following syntax: $ echo foo,bar | awk -F ',' '{print "Foobar: " $1 > $2}' $ echo foo,bar | awk -F ',' '{print "Foobar: " $1 > $2 ".foo"}' While the awk resent in FreeBSD-Current branch accets only the first line, while by second comand bails out with: awk: syntax error at source line 1 context is {print "Foobar: " $1 > $2 >>> ".foo" <<< awk: illegal statement at source line 1 Is this intended behaviour? Cheers, Wiktor Niesiobedzki