随着Sybase被完全整合到SAP下,Sybase原来的支持网站被SAP Support Portal取代。
只有购买了SAP服务的用户才能使用账号登录SAP Support Portal进行介质下载、补丁升级、报Incident等。
目前,原Sybase所有产品(包括:Adaptive Server Enterprise、Sybase IQ、Replication Server、PowerDesigner等)的官方手册仍然可以从http://infocenter.sybase.com/help/index.jsp进行浏览或下载。暂不清楚该网站http://infocenter.sybase.com/help/index.jsp何时会被完全迁移到SAP Support上!
Sybase官方手册英文版有html和pdf两种格式,而中文版手册只有pdf一种格式。为了国内Sybase用户更方便、快捷地搜索Sybase常见产品的官方手册内容,特将中文版Sybase官方手册转为html格式!
Sybase产品官方手册中文版的html格式所有内容的版权归SAP公司所有!本博客站长是Sybase数据库的铁杆粉丝!
如有Sybase数据库技术问题需要咨询,请联系我!
以下官方手册为ASE 15.7 ESD#2中文版:
- 新增功能公告 适用于 Windows、Linux 和 UNIX 的 Open Server 15.7 和 SDK 15.7
- 新增功能摘要
- 新增功能指南
- ASE 15.7 发行公告
- 配置指南(windows)
- 安装指南(windows)
- 参考手册:构件块
- 参考手册:命令
- 参考手册:过程
- 参考手册:表
- Transact-SQL® 用户指南
- 系统管理指南,卷 1
- 系统管理指南,卷 2
- 性能和调优系列:基础知识
- 性能和调优系列:锁定和并发控制
- 性能和调优系列:监控表
- 性能和调优系列:物理数据库调优
- 性能和调优系列:查询处理和抽象计划
- 性能和调优系列:使用 sp_sysmon 监控 Adaptive Server
- 性能和调优系列:利用统计分析改进性能
- 程序员参考 jConnect for JDBC 7.0.7
- Adaptive Server Enterprise 中的 Java
- 组件集成服务用户指南
- Ribo 用户指南
- 内存数据库用户指南
- Sybase Control Center for Adaptive Server® Enterprise
- 安全性管理指南
- 实用程序指南
ESD #3 中用于 Python 的 Adaptive Server Enterprise 扩展模块
用于 Python 的 Adaptive Server Enterprise 扩展模块已经得到增强,其支 持带输入和输出参数、计算行和本地化错误消息的存储过程。
使用 Python 访问存储过程
用于 Python 的 Adaptive Server Enterprise 扩展模块增加了向存储过程传 递输入和输出参数的支持。使用游标对象的 callproc() 方法调用存储过 程。如果执行存储过程时出现错误,则 callproc() 会抛出异常,且您可使 用 proc_status 属性检索状态值。该支持是对 Python DBAPI 规范的扩展。
以下是包含多行结果的 Python 应用程序示例:
import sybpydb
#Create a connection.
conn = sybpydb.connect(user='sa')
# Create a cursor object. cur = conn.cursor()
# Call the stored procedure try:
cur.callproc('myproc') continue = True while(continue == True):
row = cur.fetchall() continue = cur.nextset()
except sybpydb.Error:
print("Status=%d" % cur.proc_status)
为了指定输出参数,扩展模块提供了 OutParam 构造方法。该支持是对 Python DBAPI 规范的扩展。callproc() 方法返回向该方法传递的所有参数 的列表。如果存在输出参数但存储过程未生成结果集,在 callproc() 完成 后,列表则包含修改的输出值。但是,如果存在结果集,在使用 fetch*() 方法检索存储过程的所有结果集并调用 nextset() 检查是否存在任何其它 结果集之前,列表不含修改的输出值。即使预计只有一个结果集,也必 须调用 nextset() 方法。
以下是带有输出参数的示例 Python 应用程序:
import sybpydb
#Create a connection.
conn = sybpydb.connect(user='sa')
# Create a cursor object. cur = conn.cursor() cur.execute("""
create procedure myproc
@int1 int,
@int2 int output as
begin
select @int2 = @int1 * @int1
end """)
int_in = 300
int_out = sybpydb.OutParam(int())
vals = cur.callproc('pyproc', (int_in, int_out)) print ("Status = %d" % cur.proc_status)
print ("int = %d" % vals[1]) cur.connection.commit()
# Remove the stored procedure cur.execute("drop procedure myproc") cur.close()
conn.close()
示例程序 callproc.py 中提供了不同输出参数类型的更多示例。
使用 Python 的计算行
用于 Python 的 Adaptive Server Enterprise 扩展模块添加了对计算行的支 持。示例程序 compute.py 中提供了计算行的处理示例。
本地化错误消息
现在,用于 Python 的 Adaptive Server Enterprise 扩展模块支持本地化错 误消息。
之前就已经研发成功了能够从Sybase SQL Anywhere的DB文件中恢复数据的工具:ReadASADB。
此工具支持ASA v5.0,v6.0,v7.0,v8.0,v9.0,v10.0,v11.0,v12.0等版本。
恢复Sybase SQL Anywhere的工具在国内应该算首创。
ReadASADB功能
能够从损坏的SQL Anywhere数据文件(.db)和UltraLite数据文件(.udb)上提取数据的非常规恢复工具
- 适用于所有的SQL Anywhere版本 包括:5.x,6.x,7.x,8.x,9.x,10.x,11.x,12.x
- 适用于所有的UltraLite版本
- 能够恢复出来表结构和数据
- 能够恢复自定义数据类型
- 能够恢复存储过程等对象的语法
- 能够导出到目标数据库
- 能够导出到SQL文件并生成导入脚本
- 支持多种字符集 包括:cp850、cp936、gb18030、utf8等
- 能够恢复未加密或者简单加密类型的数据
- 简单易用
- 限制:不支持AES加密的数据文件
SQL Anywhere数据库非常规恢复工具ReadASADB使用介绍
ReadASADB适用场景
各种误操作:
- 误截断表(truncate table)
- 误删除表(drop table)
- 错误的where条件误删数据
- 误删除db或log文件
- 误删除表中的字段
本工具的应用场景:
1.因为物理磁盘故障、操作系统、系统软件方面或者掉电等等原因导致的Sybase SQL Anywhere数据库无法打开的情况;
2.误操作,包括truncate table,drop table,不正确的where条件导致的误删除等;
Sybase SQL Anywhere无法打开时,比较常见的错误是:Assertion failed。
如:
1、Internal database error *** ERROR *** Assertion failed:201819 (8.0.1.2600) Checkpoint log: invalid bitmap page -- transaction rolled back
2、Internal database error *** ERROR *** Assertion failed:201819 (8.0.1.2600) Page number on page does not match page requested -- transaction rolled back
3、Internal database error *** ERROR *** Assertion failed:200502 (9.0.2.2451) Checksum failure on page 23 -- transaction rolled back
4、File is shorter than expected
5、Internal database error *** ERROR *** Assertion failed: 201116 Invalid free list index page found while processing checkpoint log -- transaction rolled back
6、*** ERROR *** Assertion failed: 51901 Page for requested record not a table page or record not present on page等等。
+-------------------------------------华丽的分割线-------------------------------------------------------------------------