From owner-freebsd-questions@FreeBSD.ORG Thu Feb 26 07:52:50 2004 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id D4D4116A4CE for ; Thu, 26 Feb 2004 07:52:50 -0800 (PST) Received: from kcp05h-gw.pragonet.cz (eth0.kcp05h-gw.pragonet.cz [212.67.74.174]) by mx1.FreeBSD.org (Postfix) with ESMTP id 0AE9D43D1D for ; Thu, 26 Feb 2004 07:52:50 -0800 (PST) (envelope-from Zdenek.Roubicek@pragonet.cz) Received: by kcp05h-gw.pragonet.cz (Postfix, from userid 1002) id C66F993B7D; Thu, 26 Feb 2004 16:52:48 +0100 (CET) Received: from pgnmail1.pgnaplikace.cz (isanat.pragonet.cz [212.67.66.42]) by kcp05h-gw.pragonet.cz (Postfix) with ESMTP id 5E7E993B7F; Thu, 26 Feb 2004 16:52:17 +0100 (CET) content-class: urn:content-classes:message MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-2" Content-Transfer-Encoding: quoted-printable X-MimeOLE: Produced By Microsoft Exchange V6.0.6249.0 Date: Thu, 26 Feb 2004 16:52:17 +0100 Message-ID: <9256D57F598E6C41B288AA7DB94F29C901C2D6A4@pgnmail1.pgnaplikace.cz> X-MS-Has-Attach: X-MS-TNEF-Correlator: Thread-Topic: Problem with sed and awk Thread-Index: AcP8dSY004itkmWCS6GjzHTXDlFdAgABvQng From: =?iso-8859-2?Q?Roub=ED=E8ek_Zden=ECk_=28T-Systems_PragoNet=29?= To: "Warren Block" X-Spam-Status: No, hits=-103.8 required=5.0 tests=QUOTED_EMAIL_TEXT,QUOTE_TWICE_1,USER_IN_WHITELIST version=2.50 X-Spam-Level: X-Spam-Checker-Version: SpamAssassin 2.50 (1.173-2003-02-20-exp) cc: questions@freebsd.org Subject: RE: Problem with sed and awk - SOLVED X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 26 Feb 2004 15:52:51 -0000 Sorry for not very clearly formulated question. I wrote those commands = by hand and obviously with lot of errors. >=20 > > >awk -F ' FS=3D";" {print $1}' > > 1;1 > > 2 >=20 > Don't use the -F option if you are setting the field separator inside > the code. >=20 This was a mistake.=20 The problem is solved by=20 awk 'BEGIN{FS=3D";"}{print $1}' testfile=20 as suggested by Dough Poland.=20 Thx for the replies. r. Zdenek Roubicek Department of Network Management T-Systems PragoNet, a.s. Na Pankr=E1ci 1685/19,140 21 Prague 4 Phone : +420 2 3609 9615 =09 Fax : +420 2 3609 9999 E-Mail: zdenek.roubicek@pragonet.cz =20