![]() |
|
|
|
|
|||||||
| Forums | Portal | Register | Rules & FAQ | Contribute | Members List | Arcade | Search | Today's Posts | Mark Forums Read |
| Shell Programming and Scripting Post questions about KSH, CSH, SH, BASH, PERL, PHP, SED, AWK and OTHER shell scripts here. |
|
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Script required to get a required info from file. Pls. help me. | ntgobinath | Shell Programming and Scripting | 2 | 05-31-2008 05:34 AM |
| 7028-6C4 with an attached 7311-D20 | prichard | AIX | 3 | 05-05-2008 07:44 PM |
| sed script required | jaganadh | Shell Programming and Scripting | 2 | 07-05-2007 11:54 PM |
| help required in unix command/script | thaduka | UNIX for Advanced & Expert Users | 1 | 10-17-2005 11:27 PM |
| UNIX PATH info required PLEASE HELP (I'm new to unix) | akitachi | UNIX for Dummies Questions & Answers | 1 | 05-10-2002 11:37 AM |
|
|
LinkBack | Thread Tools | Display Modes |
|
|||
|
Help Required: To run the attached UNIX script
Hi,
This Script contains update statements and running without error. But the update result is not getting reflected in the database. i.e may be Script fails to connect to the database. it would be of great help if you could figure out the problem. Thanks, Shruti Script follows here: /////////////////////// #!/usr/bin/ksh echo "************************************************** ************************************************** ********"; echo Making a customer hold or Block echo "************************************************** ************************************************** *******"; echo "Enter the product name, customer name and the functionality [HOLD(HD)/ BLOCK (BK)]:" read prod_name; read cust_name; read block_hold; echo $block_hold; if [[ block_hold = "BK" ]]; then echo "Block"; `sqlplus -s itm_odb/itm_odb<<EOF update CUST_PROD_TBL set BLOCKED_STATUS = 'Y' where prod_id = (select prod_id from products_tbl where product_name ='$prod_name') and cust_id = (select cust_id from CUSTOMER_tbl where CUST_name ='$cust_name'); exit; EOF ` echo "Block update successfull"; fi if [[ block_hold = "HD" ]]; then echo "Hold"; `sqlplus -s itm_odb/itm_odb<<EOF UPDATE customer_view SET site_id = 'XXX' WHERE site_id = '$cust_name'; exit; EOF ` echo "HOLD update successfull"; fi exit; |
| Forum Sponsor | ||
|
|