Sponsored Content
Full Discussion: Perl file handling error
Top Forums Shell Programming and Scripting Perl file handling error Post 302652021 by Beginer123 on Wednesday 6th of June 2012 12:19:26 PM
Old 06-06-2012
yes the TEMP open and data also write to the file.
I am getting the desired result as I required, but my problem is
while running the script the mention error message display in the screen.
 

10 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

file handling problem in perl......

Hi, I am opening a file......then i am wrting some data into it......and i am reopening the file again but ......i get a error cannot open file....... $::file= "\adder\testfile.txt" open(TEST1,$::file); some write operation close(TEST1) open(TEST1,$::file) 'I GET A ERROR CAN OPEN... (2 Replies)
Discussion started by: vivekshankar
2 Replies

2. Shell Programming and Scripting

Perl revers File handling

Hi Experts, I have a big text file, so I want read it at eof to upper bound !. after I use a fseek to go SEEK_END, is it possible to step up upperbound? Best Regards. Note that I'm used perl script. (2 Replies)
Discussion started by: Zaxon
2 Replies

3. Shell Programming and Scripting

file handling in perl without using system command

Hi , Is there any way to achieve following using perl program (i.e without using system command). 1.system ("echo 'test' > /usr/spool/ship.csv"); 2.system ("cat /usr/ajay_test* >> /usr/spool/RAM/work/patil.csv"); 3.system("> /usr/spool/ajay.txt"); e.g for system("rm -f... (1 Reply)
Discussion started by: ajaypatil_am
1 Replies

4. Shell Programming and Scripting

Perl and Sockets - Error handling

Hello all, I have created a Perl script that tries to open connections to various systems on different ports in order to see if the machines are reachable, the ports are open, etc. There appears to be a difference between Solaris (10) and Linux (RH/Oracle and Ubuntu) in the status or error it... (4 Replies)
Discussion started by: Hollinch
4 Replies

5. Infrastructure Monitoring

Perl Error Handling Problem

I can get this working, but if something is down I get an error and the script does not move on. I can not get the "else" function working. What might I be doing wrong? use SNMP::Simple my %ios = (); $list="list.list"; open(DAT, $list) || die("Can't Open List"); @raw_data=<DAT>;... (4 Replies)
Discussion started by: mrlayance
4 Replies

6. Programming

Perl help for file handling

$# some text $$ some text $@ some text $$. some text Mg1 some text Mg2 some text . . . Mg10 some text The above 10 lines are to be extracted except the lines starting from $#,$$.,... (4 Replies)
Discussion started by: baig.abdul
4 Replies

7. Shell Programming and Scripting

PERL error handling

I have a PERL command line embedded in a UNIX script. The script doesn't handle errors coming out of this command. I'm processing large files and occassionally I run out of disk space and end up with half a file. perl -p -e 's/\n/\r\n/g' < TR_TMP_$4 > $4 How do I handle errors coming out... (1 Reply)
Discussion started by: OTChancy
1 Replies

8. UNIX for Dummies Questions & Answers

Error Handling using ISQL for oracle connection in Perl

Hi Am making connection to oracle using ISQL as shown in the code. This code is just a minor part of a big code. I want to capture the error if the password/login is wrong or if connection is not made. I need to capture the error code also. Also, If such an error occurs, i need to exit out... (4 Replies)
Discussion started by: irudayaraj
4 Replies

9. Shell Programming and Scripting

Error handling for file

Hi Guys, I got a csv with pipe delimted file and i want to check second column of the file has any alpha character becuase I am expecting only number in that, and if any alpha characters then it should throw an error Thanks in advance (1 Reply)
Discussion started by: Rizzu155
1 Replies

10. Shell Programming and Scripting

Perl : How is file handling working here??

Hi, I have a perl script which is just reading from the file but what I would like to understand is how the counter is moving without using the loop in the script. Below are the details: $ more /tmp/abc.txt This is 0 This is 1 This is 2 This is 3 This is 4 This is 5 This is 6 This... (2 Replies)
Discussion started by: siddharthjindal
2 Replies
TAPECALC(1)						      General Commands Manual						       TAPECALC(1)

NAME
tapecalc - full-screen editing calculator USAGE
tapecalc [options] [file-specifications] SYNOPSIS
Tapecalc is a fixed-point calculator that operates as a full-screen editor. DESCRIPTION
Tapecalc performs fixed-point computation. It is designed for use as a checkbook or expense-account balancing tool. Tapecalc maintains a running result for each operation. You may scroll to any position in the expression list and modify the list. Enter data by typing numbers (with optional decimal point), separated by operators. An output transcript may be saved and reloaded for further editing. Scripts are loaded from left to right (with the "output" processed first). OPTIONS
Command line options of tapecalc are: -h Prints the list of options. -i interval Sets compounding interval for interest computation. -o script Specify file in which to save output transcript. -p num Sets precision (number of digits after the decimal place). OPERATIONS
Computations: The operators are all single-character: + begins an addition - begins a subtraction ~ negates the result * begins a multiplication / begins a division % begins an interest computation (uses interval): rate=number. $ begins a sales-tax computation: rate=number. ( opening parenthesis. This may enclose a unary '-', more parentheses, or data (implicit unary '+'). ) closing parenthesis, expects another operator, not data. = flushes out the current number, forces re-computation of the running result. A space flushes out the current number-input, and (by default) sets the next operator to be the same as the current one. You may repeat the last arithmetic operation of any type: a repeats the last '+' (default 0). s repeats the last '-' (default 0). n repeats the last '~'. m repeats the last '*' (default 1). d repeats the last '/' (default 1). i repeats the last '%' (default 4). t repeats the last '$' (default 4). You may toggle the prefix operator of any number by typing a single character: A toggles the operator to '+'. S toggles the operator to '-'. N toggles the operator to '~'. M toggles the operator to '*'. D toggles the operator to '/'. I toggles the operator to '%'. T toggles the operator to '$'. Editing: As you enter data, you may edit it. A backspace deletes the last digit of the current number (if it is visible). Use the arrow keys or vi-style 'h' and 'l' to move left and right within the line. Other editing commands include u undoes the last x/X command (restricted to restoring the current data only). x deletes the current data. If the data is null, deletes the following line. X deletes the current data. If the data is null, deletes the preceding line and moves up. o opens a new line after the current line. O opens a new line before the current line. # edit the associated comment. An "open" permits you to insert a new operator and data into the expression list. You may type an operator character (e.g., '+'), and continue with the new data, or an operator-repeat (e.g., 'A'). In either case, you may edit the new data, just as you would the old data. A 'u' (or other toggle, such as 'o', 'O', or 'q') typed after an open will undo the open (and close it). Scrolling/cursor movement: H move to the top line on the screen. M move to the middle line on the screen. L move to the last line on the screen CTL/F scroll forward one screen. CTL/B scroll backward one screen. j move forward one line. k move backward one line. z<CR> move the current line to the top of the screen. z. move the current line to the middle of the screen. z- move the current line to the bottom of the screen. Like vi, tapecalc allows you to jump to a particular line with a ":" command :$ jumps to the last entry :1 jumps to the first entry. Scripts: Transcript files are formatted to permit line-oriented entries: <operator><value><tab><ignored><tab># comment The transcripts saved by tapecalc contain the running result in the "ignored" part. To exit without saving a transcript, type 'Q'. A nor- mal exit, by typing 'q', saves the list of operators, data (and running result) in the specified file. You can read and write scripts without leaving tapecalc. reads a script at the current entry :e file clears the current script and reads a script from the file. :f shows the current script name. :r file :w file writes a script to the specified file. ENVIRONMENT
Tapecalc runs in a portable UNIX(R) environment. FILES
Tapecalc is a single binary module, with a help file tapecalc.hlp installed in the same directory. FUTURE WORK
It would be nice to be able to change the precision within the program. In particular, the interest and sales tax computations would be more useful if their precision was independent of the running total. AUTHOR
Thomas Dickey SEE ALSO
wc (1), vi (1) TAPECALC(1)
All times are GMT -4. The time now is 10:27 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy