[HPADM] Problem in awk script

From: Lal, Neeraj (Neeraj.Lal_at_pfizer.com)
Date: 12/16/03

  • Next message: Denny Koovakattu: "[HPADM] MD5 version which supports largefiles"
    To: "'hpux-admin@dutchworks.nl'" <hpux-admin@dutchworks.nl>
    Date: Tue, 16 Dec 2003 11:12:05 -0500
    
    

    Hi Admins

    I have script

    SRC_DIR_NAME='e:/kshell_test/data/outfiles/notif'
    RUN_DIR='e:/kshell_test/ftp_ksh_script'
    cd $SRC_DIR_NAME
    ls PAPER*.TXT > $RUN_DIR/printfile_name
    awk <$RUN_DIR/printfile_name >
    e:/kshell_test/ftp_ksh_script/printfile_name.bat \
    '
    {
    print "copy e:\kshell_test\data\outfiles\notif\" $0 " \\abc\efg_pop
    <\\abc\efg_pop> ";

    }
    '

    When I run this scripti get following error what is mistake I am doing

    awk: file "[command line]": line 2: Syntax error Context is:
    >>> "copy e:\kshell_test\data\outfiles\notif\" $0 " \

    Thanks

    Neeraj Lal
    Pfizer Inc.
    Consultant CHC-IS
    973-385-2734

    --
                 ---> Please post QUESTIONS and SUMMARIES only!! <---
            To subscribe/unsubscribe to this list, contact majordomo@dutchworks.nl
           Name: hpux-admin@dutchworks.nl     Owner: owner-hpux-admin@dutchworks.nl
     
     Archives:  ftp.dutchworks.nl:/pub/digests/hpux-admin       (FTP, browse only)
                http://www.dutchworks.nl/htbin/hpsysadmin   (Web, browse & search)
    

  • Next message: Denny Koovakattu: "[HPADM] MD5 version which supports largefiles"

    Relevant Pages

    • Re: How to rewrite with awk?
      ... > I'm unfamiliar with tools such as sed & awk. ... Extract the string that matches a RE. ... This script will not only expand all the lines that say "include ... file) and not resetting ARGV(the tmp file), it then lets awk do any ...
      (comp.unix.shell)
    • Re: for loop (?)
      ... you should use awk variables in awk scripts instead ... >>of shell variables to avoid problems when those shell variables include ... I doubt if I've ever written a shell script that's robust ... > extra effort to make the script robust against weird inputs. ...
      (comp.unix.shell)
    • Re: How to remove all .DS_Store files using Terminal?
      ... Great tip, I will add that to my limited Unix arsenal, thanks. ... When I first saw this script, ... into an awk script. ... The conditional expression can be a search string as in /abc/ or a ...
      (comp.sys.mac.system)
    • Re: for loop (?)
      ... you should use awk variables in awk scripts instead ... > of shell variables to avoid problems when those shell variables include ... can handle NUL characters correctly in its input. ... pass these characters to the script in the first place. ...
      (comp.unix.shell)
    • Re: [PATCH] Linux 2.6: shebang handling in fs/binfmt_script.c
      ... script files and their interpreters (shells, awk, perl, python, guile, ... that that shell or interpreter would be poorly ... And, to be truthful, the usual way that I code awk scripts is not as ...
      (Linux-Kernel)