473,320 Members | 2,112 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,320 software developers and data experts.

Perl: unable to use "select" with filehandle

2
i wanted to open a file using perl and the output of print cmd to be added in that file. can i do it using perl ?

what if i use following the following ".pl " file.
Expand|Select|Wrap|Line Numbers
  1. open CONFIG, ">HELLO.txt";
  2. select CONFIG;
  3. print "suceeded";
when i execute the above file, i get compilation error.
Can anybody tell me wht is the error in this script.
Nov 17 '07 #1
1 1459
KevinADC
4,059 Expert 2GB
i wanted to open a file using perl and the output of print cmd to be added in that file. can i do it using perl ?

what if i use following the following ".pl " file.
Expand|Select|Wrap|Line Numbers
  1. open CONFIG, ">HELLO.txt";
  2. select CONFIG;
  3. print "suceeded";
when i execute the above file, i get compilation error.
Can anybody tell me wht is the error in this script.
is that all of the code? There is no error in the code above. Do you need to include the shebang line?
Nov 17 '07 #2

Sign in to post your reply or Sign up for a free account.

Similar topics

23
by: ian justice | last post by:
Before i post actual code, as i need a speedyish reply. Can i first ask if anyone knows off the top of their head, if there is a likely obvious cause to the following problem. For the moment i've...
0
by: Michael | last post by:
I have a problem forcing files to download. If I select Save the document is saved with no problems. If I select "Open" the document is empty or I get a "File not found" error from the application...
3
by: Bucky | last post by:
I know this issue is discussed frequently, but all the threads end with, "There is no way around this... this is how IE is designed." Well, I found a site that has completely solved this problem....
10
by: serge | last post by:
Using "SELECT * " is a bad practice even when using a VIEW instead of a table? I have some stored procedures that are identical with the difference of one statement in the WHERE clause. If I...
2
by: google | last post by:
Hello everyone, I am having an issue using the "Multi Select" option in a list box in MS Access 2003. I am making a form that users can fill out to add an issue to the database. Each issue can...
3
by: divya | last post by:
Hi, I have a table tblbwday with 2 fields Name and Birthday.I have written this script for displaying evryday names of the people on that day. <% set objConn...
5
by: Lennart | last post by:
I really like the construction: select * from new table (update ....) X but I noticed that it cant be used as: insert into T select * from new table (update ....) X because of:
2
by: junkblog747 | last post by:
What will the expression "/.." in the attribute select="/.." return? I just inherited a huge stylesheet to maintain which has a lot of parameters such as <xsl:param name="myParam"...
1
by: subbarao.puvvada | last post by:
Hi All, I am working on a Windows application, Which browser control on main form itself develped in .NET 1.1. Recently we have migrated it to .NET 2.0. It's combination of Web pages and .NET...
0
by: DolphinDB | last post by:
The formulas of 101 quantitative trading alphas used by WorldQuant were presented in the paper 101 Formulaic Alphas. However, some formulas are complex, leading to challenges in calculation. Take...
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
0
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
0
by: Shællîpôpï 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....
0
by: af34tf | last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.