Forum: Shell Scripting Jan 27th, 2009 |
| Replies: 7 Views: 2,164 function report
{
clear
echo "Name, Position, Department, Salary"
echo "========================================"
awk 'BEGIN{FS=","; RS="\n"} {printf "%s, %s, %s, %s\n", $1, $2, $3, $4}'... |
Forum: Shell Scripting Jan 26th, 2009 |
| Replies: 7 Views: 2,164 sorry bout that....my net got dc-ed halfway thru posting and i copied my whole post, didnt realise that code tags wont appear when copied...
anyway i tried taking off the $ sign but it still gives... |
Forum: Shell Scripting Jan 26th, 2009 |
| Replies: 7 Views: 2,164 #5report
function report
{
clear
echo "Name, Position, Department, Salary"
echo "========================================"
awk 'BEGIN{FS=","; RS="\n"} {printf "%s, %s, %s, %s\n", $1, $2, $3,... |
Forum: Shell Scripting Jan 18th, 2009 |
| Replies: 5 Views: 752 ok so I tried this on my data file which contains records:
Name, Dept, Job, Pay
John, Finance, Accountant, $2000
read -p "Enter name of Employee to Remove?: " remEmp
tr -d "grep -n -i $remEmp... |
Forum: Shell Scripting Jan 18th, 2009 |
| Replies: 5 Views: 752 thanks that helped alot
by the way, if i want to say delete a line of record, can i use the
tr -d?? Because I have been searching the Bash commands and havent found and delete command for shell... |
Forum: Shell Scripting Jan 18th, 2009 |
| Replies: 2 Views: 738 ok what i need to do is to make a script function which allows me to change the records in a file. I read some other posts about using sed but i still could not get it to work. The function runs But... |
Forum: Shell Scripting Jan 16th, 2009 |
| Replies: 5 Views: 752 I am doing a shell script to be able to read some records from a file, then ask the user to input a name. The script should then be able to search the records and only print out the requested record.... |