![]() |
Hello and Welcome from United States to the UNIX and Linux Forums! Thank You for Visiting and Joining Our Global Community.
|
|
google unix.com
|
|||||||
| Forums | Register | Forum Rules | Links | Albums | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
| UNIX for Dummies Questions & Answers If you're not sure where to post a UNIX or Linux question, post it here. All UNIX and Linux newbies welcome !! |
More UNIX and Linux Forum Topics You Might Find Helpful
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| pstat_getdisk() call doesn’t work properly in HPUX 11.31 (11i V3) | sandiworld | HP-UX | 2 | 10-25-2007 10:39 AM |
| unmount doesn't work | DISTURBED | UNIX for Dummies Questions & Answers | 2 | 07-04-2002 06:14 PM |
| grep doesn't work within shell script? | barisgultekin | Shell Programming and Scripting | 4 | 05-24-2002 02:01 PM |
| Repquota doesn't work as Cronjob?!? | b416 | UNIX for Dummies Questions & Answers | 1 | 04-14-2002 08:44 PM |
| why doesn't this work????? | token | High Level Programming | 1 | 09-20-2001 10:08 AM |
|
|
LinkBack | Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
||||
|
my case statement doesn't work..
CO UNixware 7.1.1
Hi friends, I have chopped my case statementt out of my .profile and put it in another script called setsid. The case statement works when run from my .profile but not from my setsid file. All that the script does is set an environmental variable based on user input. The variable is ORACLE_SID. Here is my script. Code:
#! /bin/sh echo echo "What do you want to set your ORACLE_SID to ? 1: wmsdata 2: wmstest 3: wmsctl" echo read RESPONSE DUMMY case "$RESPONSE" in 1) ORACLE_SID=wmsdata export ORACLE_SID alias pfile='cd $ORACLE_HOME/admin/wmsdata/pfile/' alias bdump='cd $ORACLE_HOME/admin/wmsdata/bdump/' alias udump='cd $ORACLE_HOME/admin/wmsdata/udump/' ;; 2) ORACLE_SID=wmstest export ORACLE_SID alias pfile='cd $ORACLE_HOME/admin/wmstest/pfile/' alias bdump='cd $ORACLE_HOME/admin/wmstest/bdump/' alias udump='cd $ORACLE_HOME/admin/wmstest/udump/' ;; 3) ORACLE_SID=wmsctl export ORACLE_SID alias pfile='cd $ORACLE_HOME/admin/wmsctl/pfile/' alias bdump='cd $ORACLE_HOME/admin/wmsctl/bdump/' alias udump='cd $ORACLE_HOME/admin/wmsctl/udump/' ;; *) ORACLE_SID=wmsdata export ORACLE_SID alias pfile='cd $ORACLE_HOME/admin/wmsdata/pfile/' alias bdump='cd $ORACLE_HOME/admin/wmsdata/bdump/' alias udump='cd $ORACLE_HOME/admin/wmsdata/udump/' ;; esac when I set -vx I notice that th list of commands associated with the reponse do run, yet the variable does not change. Please help. Thanks in advance Suresh added code tags for readability --oombera Last edited by oombera; 02-19-2004 at 03:29 PM.. |
| Bookmarks |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|