In Perl, the DBI module is an interface for MySQL database-related operations, and the DBI module needs to be installed in the environment first. The approximate steps for Perl to handle database operations are as follows:#声明使用DBI模块Use
Compiling DBDPerl is often used in projects, but Perl needs to rely on the DBI,DBD driver when connecting to the database, but it relies on the Lib library of the database when installing DBD drivers by default.For example, Perl is connected to
Implemented features:Fetch warn and its description and NUM numberFeatures not implemented:How to prioritize these warn to facilitate later report analysis usingIdea:1. Find a way to permanently save and read warn Level/advice data at the fastest
The 12th chapter: Regular ExpressionsA regular expression is a sub-program. is the text matching subroutine. Yi Wu.Be sure to use the/X flag. Yi Lu.be sure to mark with/M. One restaurant Qi.use \a and \z as the string boundary anchor point (anchor).
the conversion between Perl Chinese/Unicode/utf8/gb2312 encoding is a headache. I have summarized the following conversion methods for your reference.
# Author: jiangyujie Use utf8; Use encode; Use URI: escape; $/= "/N"; # utf8 encoding
Perl is a very powerful text processing language. When I was writing a Perl script, I basically solved it with notepad ++ and print.CodeEditing and debugging problems. Notepad ++ is actually a very good choice for the editor. It is very nice to
1. The use strict command means that all variables must be declared using my, and bare words must be enclosed in quotation marks.
2. Check the installed module: perldoc perllocal
Manual module installation:
Code highlighting produced by Actipro
Code
Code highlighting produced by Actipro CodeHighlighter (freeware)http://www.CodeHighlighter.com/--> In a PerlProgramYou can embed a document to describe the features and usage of the program. Pod (plain old documentation) is the
I,Regular ExpressionSpecialVariable:1. $ N: contains the nth substring of the last pattern match.2. $ &: String matched in the previous successful mode3. $ ': Content Before the successful substring4. $ ': content after the child string that was
Basically, a simple variable is a data unit, which can be a number or string.I. Integer1. IntegerThe most common simple variables in Perl are not described here because they are basically the same as other languages.Example:$ X = 12345;If (1217 + 116
1. When chomp does not have a parameter, use the default parameter to operate on $.
2. array @ array .. can be referenced by $ array [number. $ # Array... indicates the number of indexes in the array.
3. $! Contains error information;
4. By default,
Perl does not have various variable types like C/C ++. The variable type in Perl is determined by context, whether it is a string or an integer variable. For example, my $ para = @ _ # indicates the scalar context. $ para obtains the number of
1. Perl
Practical Extraction and report language: Practical excerpt and Report Language
2. Multi-line comment
(1) = requires top level writing
= Description
Statement;
= Cut
(2) The description at the end must be written in the top level.
Print
1. the hash key is unique and the value can be repeated!
2. Access the hash Element
$ Hashname {"$ key"}; # hash is braces, array is square brackets, and key is string
$ Family_name {"Fred"} = "firstd"; # assign a value to the hash Element
3. the
1) is the URL Legal:/^ (http: \/| https :\/\/)? ((? : [A-Za-z0-9] +-[A-Za-z0-9] + | [A-Za-z0-9] +) \.) + ([A-Za-z0-9] + )[\/\? \:]?. * $/
2) When to escape: 1. For example, if you want to use "in" ", then \"; 2. Some special characters
3) database
System: Windows
Language: Perl
Tool: notepad ++/CMD
Currently, Perl is used to analyze the page. Then, the group downloads the files and renames them.
First, the rarfile is connected to the second-level file. The rarfile name is a number, and the
For the original English version, see http://www.masonbook.com /.
Introduction
Mason is a powerful template engine that can embed Perl into text. It provides many features to help you use reusable components to create dynamic web sites. In addition,
This article focuses on the concepts of Perl variables in Perl syntax. Perl variables include scalar variables, array variables, and link array variables. perl variables are sensitive to minor write, such as: An, AN, and an are three different
At the beginning, I plan to use perldoc to view the Apache2: Request module. The following error occurs during running:
Copy codeThe Code is as follows: Error in tempfile () using/tmp/XXXXXXXXXX: parent directory (./) is
Not writable
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.
A Free Trial That Lets You Build Big!
Start building with 50+ products and up to 12 months usage for Elastic Compute Service