Re: pattern matching

2004-06-23 Thread Murzc
>Would something like this do the trick? > $_ = $1 if /((\s*\w+:?)+)/; True. But I need to test the line to see if it contains those '*--**'. Otherwise how do I know that the line needs to be edited. (I am reading a file with many lines. I have to detect when the line comes with th

Re: pattern matching

2004-06-23 Thread Murzc
OK. I am reading a file. This line is at the bottom of the file and the "---**" is a sign that the section is complete. I need to be able to pick up that line, and see if there is also code on the beginning of that line that I need to save. So in this case I was searching for wo

pattern matching

2004-06-23 Thread Murzc
Hi, I have a string similar to: Comment: FILING This is read in as one line (with the page feed). I was trying to whatever follows the words and I tried this. if (/(\w+:?\s*\w*:?)+(.*?\*+\s*-+\s*\*+\s*$)/) {

\b confusion

2004-06-18 Thread Murzc
According to the principle of \b why is this doing this? $word = "(HP)"; $word =~ s/[,\]\)\}]\b//; $word =~ s/\b[,\]\)\}]//; Since the parentheses is on either side of the boundary, it should take off bpth of them. Instead the result is:$word = "(HP" It only took of the end paren. When

Pattern matching \b

2004-06-14 Thread Murzc
$field = "Search, This is part of the code."; ## We need to split by spaces. The issue is that the comma comes along. local(@words) = split('\s+', $field); foreach $word (@words) { if ($word =~ /Search/i) { $word =~ s/[,\]\)\}]\b//; $word =~ s/\b[,\]\)\}]//;

Dot Net

2003-07-09 Thread Murzc
I was told that Perl is portable to the .NET (Dot NET) environment. Does anyone know of a similar type of a .NET group where you can ask all types of questions. (VB.NET, c#.NET etc. The .dot net framework.) Please let me know. Thank you. -- To unsubscribe, e-mail: [EMAIL PROTECTED] For addit

Dot Net

2003-07-09 Thread Murzc
I was told that Perl is portable to the .NET (Dot NET) environment. Does anyone know of a similar type of a .NET group where you can ask all types of questions. (VB.NET, c#.NET etc. The .dot net framework.) Please let me know. Thank you. -- To unsubscribe, e-mail: [EMAIL PROTECTED] For addit

Oracle SQL

2003-07-09 Thread Murzc
Thanks to all. I am not the SQL person. I showed some feedback, when something clicked. the person remembered that this database was set up as a CLOB type. (I don't know if I explained that well.) WE went to a different environment or part of the database where this CLOB was not there, and it wo

Oracle SQL

2003-07-09 Thread Murzc
We are having a problem. Any help would be appreciated. 1: We are running Perl on NT. 2: Perl is reading lines of code from a file, concatonating it in a variable, and writing to an Oracle database. 3: I keep on getting a message: DBD::ODBC::st excute failed: [Microsoft][ODBC driver for

OLDB - ODBC

2003-03-24 Thread Murzc
Does this belong in the DBI list? Sorry if the answer is yes. * Hi, We have a problem. We run Perl for Window NT. We use Perl to read ASCII Files, and write the information to a Database. Some of these fields are longer than 32,000 characters long. We just had one that was

FILE to subroutine

2002-05-07 Thread Murzc
Sorry This was the message that came up. for the URL: http://www.rocketaware.com/perl/perlfaq5/How_can_I_make_a_filehandle_loca.ht Message Not Found The requested URL /perl/perlfaq5/How_can_I_make_a_filehandle_loca.ht was not found on this server. Can anyone get the text or provide the answe

FILE to subroutine

2002-05-07 Thread Murzc
HI, Will someone please tell me how to send a filehandle to a subroutine, with the syntax. open(FILE, "file.fil"); $foo = subro( )<<-How do I send down FILE sub subro { my = @_; <<- How do I pick it up? thank you -- To unsubscribe, e-mail: [EMAIL PROTECTED

unix - sed

2002-04-28 Thread Murzc
No flame war needed :>. It works. Thanks ciao drieux. -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]

unix -sed

2002-04-28 Thread Murzc
I have a file with phone numbers, one after another. I want to output this file to a sed command, that will check if there is 7 digits, and if there is, then add 3 leading question marks. This is structured that I need to use sed, not PERL or vi. In vi I could say :1,$g/^...$/s/\(.*\)/???

TK list

2002-02-13 Thread Murzc
HI, I was suggested to get information for a technical TK question to: "re-ask your question on the ptk list or comp.lang.perl.tk where win32 people can help." Would anyone be able to direct me to find either ptk list, comp.lang.perl.tk, or both. Or is there a TK list? Thanks. -- To unsubsc

return @hash_table{ @extract };

2002-01-29 Thread Murzc
>> > # foreach $number (qw ) { > foreach $number ($extract) { > push (@return_array, $hash_table{$number}); > } > return @return_array; return @hash_table{ @extract }; This will return a list of values from %hash_table using the keys from @extract. Please explain why this wo

Re:What's the different between -> and => ?

2002-01-27 Thread Murzc
> The big arrow is used in place of a ',' (comma). Now, > I just read in the latest Learning Perl that this is > global (i.e..: you can replace ANY comma with it, but > I may have misunderstood, have to re-read that again), >>> Almost, the following is valid: my $couple = join " & " => qw(Husba

updated EVAL question

2002-01-14 Thread Murzc
* NOTE ** *** There was a typo in my first e-mail But my program was spelled correctly. I corrected the 's' and made it a capital. Any ideas. Thank you Tanton Gibbs for the typo tip. This is a question using eval. Below is some test code using eval. It

Eval not working!!

2002-01-14 Thread Murzc
This is a question using eval. Below is some test code using eval. It worked. A function call was loaded to a variable ($func_name) and eval calls the function and passes the variables. $func_name = "&make_shift";## load the function call and its name push(@data, eval"$func_name(4,5,6)");

Re: help with tk

2002-01-08 Thread Murzc
> > I have a TK issue. > > > > This code creates the initial TK box. > > > > > > When the user clicks the button of his choice, the TK box disappears into > the task bar. > > When the user clicks the task bar on the program's name, > > a window of a DOS screen pops up and asks the user > > "Ent

A tk question

2002-01-07 Thread Murzc
I have a TK issue. This code creates the initial TK box. >> use vars qw/$TOP/; >> $TOP = Tk::MainWindow->new; >> $TOP->title('blah blah'); >> $TOP->configure(-background => lc('PeachPuff1')); etc.(a lot more code) When the user clicks the button of his choice, the TK box disappears into

Re: $1, $2, $3

2001-12-27 Thread Murzc
HI, I have a question. I want to extract all the information to the left of the last comma. If there are 3 commas I would like everything to the left of the third comma. $derer = "Seattle, Washington, USA, NAME"; ## I only need Seattle, Washington, USA if($derer =~ /(.*?),([.*?,]*)(.*)/g) {

thanks

2001-12-12 Thread Murzc
I posted my first PERL question last night. I was surprised that someone was up and sent me a solution. It worked and I saved a lot of time. Thanks to Casey, Kevin, and Ask for putting this list together, plus all the work that they do behind the scenes. All of us who benefit from this list, can

read backwards

2001-12-11 Thread Murzc
Hi, I have an ASCII file, running in DOS. It is not a fixed file length. Its lines of data have various lengths. (some lines are empty). The program reads line by line(), and processes the lines. At a certain line I need to read the next line, check what its contents are, and then readjust the

next step

2001-12-06 Thread Murzc
This is a question for Perl programmers in the field. I would like to hear your advice in my next step. I work presently in a DOS - windows environment. I program Perl in DOS. It is pretty straight Perl scripts. Besides some DBI, and a sprinkle of CGI, it's mainly straight Perl. I learnt Perl

ppm> install not working

2001-06-05 Thread Murzc
Hi! I installed xitami on my computer. It works well. I have noticed that since the installation I cannot use the ppm install. ppm> install ppm ##  (for example) install ppm (y/N) ? ### (when I hit "y") ppm> I used to get all sorts of code downloading to my computer. Now, nothing