用一个ADOStoredProc 控件ADOStoredProc1访问数据库其ProcedureName 属性为存贮过程Proc_wcp.
存贮过程Proc_wcp如下:
create Procedure [Proc_wcp]
@bizong varchar
as
select col1 from table1 where col2 like '+@bizong'+'%'客户端程序代码如下:Procedure Tfrm_wcp.SpeedButton1Click(Sender:TObject);
begin
with ADOStoredProc1 do begin
Parameters[1].value:=combobox1.text
execproc;
end;不知何故,客户端选择的参数(combobox1.text)无法传递到存贮过程Proc_wcp的变量@bizong中。
存贮过程Proc_wcp如下:
create Procedure [Proc_wcp]
@bizong varchar
as
select col1 from table1 where col2 like '+@bizong'+'%'客户端程序代码如下:Procedure Tfrm_wcp.SpeedButton1Click(Sender:TObject);
begin
with ADOStoredProc1 do begin
Parameters[1].value:=combobox1.text
execproc;
end;不知何故,客户端选择的参数(combobox1.text)无法传递到存贮过程Proc_wcp的变量@bizong中。
解决方案 »
- fastreport控件加立象打印机问题,错位。
- 请求帮助,delphi IdHTTP POS
- 动态生成的TTabSheet 退出要报错
- CXGRID怎么实现删除选定的多行啊!望高手点醒!
- 我照书写的这段程序错在哪里
- 在dbgrid里的options属性里,有一个dgediting,我怎么在程序中动态地给他改变值?
- 我在delphi7中把提示messagedlg汉化之后,怎么不起作用??
- 如何在一个工程中导入COM+组件?
- delphi里面怎么实现foxpro的宏代换功能?
- Delphi中怎么加入OCX控件?
- ListView在vsReport模式下改变列标题的颜色。
- 如何取得一个运行时的托盘程序中的图标?该程序是外部程序.
.Parameters.refresh();
Parameters[1].value:=combobox1.text
execproc;