随笔分类 -  sybase

sybase
摘要:可以使用 select into 命令,根据在 select 语句的选择列表中指定的列以及在 where 子句中指定的行来创建新表 例如 select * into app_tr_type_bak from app_tr_type; 阅读全文
posted @ 2017-04-25 19:16 夏天的西瓜君 阅读(2485) 评论(0) 推荐(0)
摘要:触发器可自动操作。只要数据发生修改(无论是数据录入人员进行数据录入还是应用程序进行的操作),触发器就会工作。触发器专门用于一种或多种数据修改操作(update、insert 和 delete),并对每个 SQL 语句执行一次. 以下创建一个history_record_bak表的触发器 create 阅读全文
posted @ 2017-04-25 19:14 夏天的西瓜君 阅读(1889) 评论(0) 推荐(0)
摘要:脚本方式删除表 if exists (select 1 from sysobjects where id = object_id('users') and type = 'U') drop table usersgo 建表 create table users( id integer not nul 阅读全文
posted @ 2017-04-15 14:17 夏天的西瓜君 阅读(2347) 评论(0) 推荐(0)
摘要:create procedure P_mng_prize @ResultCode char(1) out, @ResultMsg char(50) out, @action_id varchar(30), @operator_id char(6), @prize_id char(4) , @stor 阅读全文
posted @ 2017-04-03 21:11 夏天的西瓜君 阅读(946) 评论(0) 推荐(0)
摘要:sybase 脚本删除存储过程 if exists (select 1 from sysobjects where id = object_id('P_add_user') and type = 'P') drop procedure P_add_usergo 阅读全文
posted @ 2017-04-03 21:06 夏天的西瓜君 阅读(983) 评论(0) 推荐(0)
摘要:在linux系统已经安装sybase 12.5之后,可以在命令行 执行 isql -Usa -P密码 -i 脚本文件(如下) 以下是脚本内容:(创建为yxmdb的库和user001,密码是123456的数据库用户) declare @vdevno int select @vdevno=1+max(l 阅读全文
posted @ 2017-04-03 21:04 夏天的西瓜君 阅读(570) 评论(0) 推荐(0)
摘要:命令行输入 isql -Usa -P123456 将sa口令设置为NULL(当前口令为"123456"): sp_password '123456',NULL,sa 阅读全文
posted @ 2016-11-22 14:44 夏天的西瓜君