Results 1 to 2 of 2
  1. #1
    Join Date
    Sep 2003
    Chiang Mai Thailand

    Post Unanswered: something wrong in shell

    I try to make backup script.
    That generate dump file are named by schema-date.dmp

    my script as followed

    MF=MS-$(date +%d%m%y).dmp

    exp system/passwd owner=xman file='/'$MF

    I test first by type to command line.
    everthing ok .
    But when I run it from script
    it show me

    syntax error at line 1: `MF=MS-$' unexpected

    how can I fix this
    I use solaris9 on sun-fire280

    Can you help me ?
    kindly regards
    thana p.
    Chaing mai Thailand
    Kindly regards,
    Thana p.
    Chiangmai Thailand

  2. #2
    Join Date
    Dec 2003
    Try putting single quotes aroun the date command like so:

    MF=MS-`date +%d%m%y`.dmp

    Above should work for a ksh script

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts