pb uo_datastore

forward
global type uo_datastore from datastore
end type
end forward
 
global type uo_datastore from datastore
end type
global uo_datastore uo_datastore
 
type variables
string is_sqlerrtext
end variables
 
forward prototypes
public function long of_retrieve (transaction trans_1, string as_sql, ref string as_errors)
public function integer of_create (string as_sql, ref string as_err)
public function long of_retrieve (string as_sql)
end prototypes
 
public function long of_retrieve (transaction trans_1, string as_sql, ref string as_errors);create(trans_1.syntaxfromsql(as_sql,"style(type=grid)",as_errors))
settransobject(trans_1)
retrieve()
if len(as_errors)>0 then return -1
return rowcount()
end function
 
public function integer of_create (string as_sql, ref string as_err);create(sqlca.syntaxfromsql(as_sql,"style(type=grid)",as_err))
settransobject(sqlca)
if len(as_err)>0 then
	return -1
end if 
return 1
end function
 
public function long of_retrieve (string as_sql);string ls_err
create(sqlca.syntaxfromsql(as_sql,"style(type=grid)",ls_err))
settransobject(sqlca)
retrieve()
if len(ls_err)>0 then 
	messagebox('提示',"ds语法错误"+as_sql+'~r~n'+ls_err)
	return -1
end if 
return rowcount()
end function
 
on uo_datastore.create
call super::create
TriggerEvent( this, "constructor" )
end on
 
on uo_datastore.destroy
TriggerEvent( this, "destructor" )
call super::destroy
end on
 
event dberror;is_sqlerrtext=sqlerrtext
end event
 

 

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值