- 博客(18)
- 收藏
- 关注
转载 Oracle_游标使用详解
-- 声明游标;CURSOR cursor_name IS select_statement --For 循环游标 --(1)定义游标 --(2)定义游标变量 --(3)使用for循环来使用这个游标 declare --类型定义 cursor c_job is select empno,ename,job,sal from e
2012-04-30 12:59:11 329
转载 Python_格式化字符串
将python字符串格式化方法以例子的形式表述如下: * 定义宽度 Python代码 >>> '%*s' %(5,'some') ' some' - 左对齐 Python代码 >>> '%-*s' %(5,'some') 'some ' 最小宽度为6的2位精度的浮点小数,位数不够时前补空格 Python代码 >>> '%6.2f'
2012-04-26 14:39:52 387
转载 python urllib使用
简介: urllib2是python的一个获取url(Uniform Resource Locators,统一资源定址器)的模块。它用urlopen函数的形式提供了一个非常简洁的接口。这使得用各种各样的协议获取url成为可能。它同时 也提供了一个稍微复杂的接口来处理常见的状况-如基本的认证,cookies,代理,等等。这些都是由叫做opener和handler的对象来处理的。 以下是获取u
2012-04-07 18:32:00 366
原创 Python_API_Built-in Functions_globals
API文档: globals() Return a dictionary representing the current global symbol table. This is always the dictionary of the current module (inside a function or method, this is the module where it is
2012-04-07 17:30:15 375
原创 Python_API_Built-in Functions_locals
API文档: locals() Update and return a dictionary representing the current local symbol table. Free variables are returned by locals() when it is called in function blocks, but not in class
2012-04-07 17:17:05 322
原创 Python_API_Structured Markup Processing Tools_sgmllib.SGMLParser.reset
API文档: SGMLParser.reset() Reset the instance. Loses all unprocessed data. This is called implicitly at instantiation time. 翻译文档: reset有SGMLParser的__init__调用,在reset进行初始化的工作。 例子: #! /
2012-04-07 16:47:36 602
原创 Python_API_Structured Markup Processing Tools_sgmllib.SGMLParser.feed
API文档: SGMLParser.feed(data) Feed some text to the parser. It is processed insofar as it consists of complete elements; incomplete data is buffered until more data is fed or close() is called.
2012-04-07 16:39:22 566
原创 Python_API_Structured Markup Processing Tools_sgmllib.SGMLParser
API文档: This module defines a class SGMLParser which serves as the basis for parsing text files formatted in SGML (Standard Generalized Mark-up Language). In fact, it does not provide a full SGML
2012-04-07 15:59:13 410
原创 Python_Built-in Types_list.extend
API文档: array.extend(iterable) Append items from iterable to the end of the array. If iterable is another array, it must have exactly the same type code; if not, TypeError will be raised. If iterabl
2012-04-07 15:23:57 432
原创 Python_API_String Services_re.compile
API文档: re.compile(pattern[, flags]) Compile a regular expression pattern into a regular expression object, which can be used for matching using its match() and search() methods, described below.
2012-04-05 18:11:45 283
原创 Python_API_String Services_re.sub
API文档:re.sub(pattern,repl,string[, count, flags]) Return the string obtained by replacing the leftmost non-overlapping occurrences ofpattern instring by the replacement repl. If the pattern isn’t
2012-04-05 16:56:44 328
原创 Python_API_String Services_string.upper
API文档: string.upper(s) Return a copy of s, but with lower case letters converted to upper case.翻译文档:参数: s:目标字符串描述: 返回一个s字符串的副本,但是所有的字符都被转换为大写。 例子: #! /usr/bin/env python
2012-04-05 15:43:21 347
原创 Python_API_String Services_string.lower
API文档: string.lower(s) Return a copy of s, but with upper case letters converted to lower case. 翻译文档: 参数: s:目标字符串 描述: 返回一个s字符串的副本,但是所以字符都被转换为小写。 例子: #! /
2012-04-05 15:39:45 295
原创 Python_API_String Services_string.split
API文档: string.split(s[,sep[, maxsplit]]) Return a list of the words of the string s. If the optional second argumentsep is absent or None, the words are separated by arbitrary strings of whi
2012-04-05 15:31:02 639
原创 Python_API_String Services_string.replace
API文档: string.replace(str, old, new[, maxreplace]) Return a copy of string str with all occurrences of substring old replaced by new. If the optional argument maxreplace is given, the first
2012-04-05 12:46:35 429
原创 Python_API_String Services_string.count
API文档: string.count(s, sub[, start[, end]]) Return the number of (non-overlapping) occurrences of substring sub in string s[start:end]. Defaults for start and end and interpretation of negative val
2012-04-05 12:35:25 351
原创 Python_API_String Services_string.index
API文档: string.index(s,sub[, start[,end]]) Like find() but raiseValueError when the substring is not found. 翻译文档: s:被匹配的字符串 sub:匹配的字符串 start:字符串的开始位置
2012-04-05 12:14:14 295
原创 Python_API_String Services_string.find
API文档: string.find(s,sub[,start[,end]]) Return the lowest index in s where the substringsub is found such thatsub is wholly contained ins[start:end]. Return-1 on failure. Defaults forstart and
2012-04-05 11:41:22 312
空空如也
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人