这是联机帮助:To run a procedure as an RPC 1、Construct an SQL statement that uses the ODBC CALL escape sequence. The statement uses parameter ers for each input, input/output, and output parameter, and for the procedure return value (if any): 
{? = CALL procname (?,?)} 2、Call SQLBindParameter for each input, input/output, and output parameter, and for the procedure return value (if any). 3、Execute the statement with SQLExecDirect.似乎没有如 Transact-SQL EXECUTE 返回记录集的办法
请高手指教!  

解决方案 »

  1.   

    请教:DentistryDoctor(牙医的目标是没有蛀牙)
    怎样使用?我只用过 SQLBindParameter 返回数据
    我希望同时有记录集返回,如普通的Transact-SQL EXECUTE 方法
    查阅了不少资料,未有结果
      

  2.   

    虽然不懂vc,但是ODBC 毫无疑问可以返回记录集
      

  3.   

    我说的是ODBC CALL
    是否在SQLBindParameter返回某些特殊数据的同时,还能返回记录集
    或者说,不使用SQLBindParameter,而是使用SQLBindCol
    如果能够这样的话,对于许多查询将非常方便
    因为,有的查询是需要先从数据库中取得环境变量的,按照变量确定记录集获取的行为我知道ODBC可以获得记录集,而且有好几种方式 :)
      

  4.   

    没用过ODBC CALL
    但是如果那个procedure 本身就返回记录集的话,是不是应该能够获得的呢这个SQLBindCol应该就是你说的,和返回的记录集绑定的
      

  5.   

    回handsomerun(毛毛) ( ) 
    你所说的就是我希望的,但是没有方法实现的因为我既希望ODBC CALL 通过SQLBindParameter返回一些数据(先)
    同时还希望利用这些先返回的数据,以SQLBindCol的方式操作记录集这样处理的好处是指需要一次连接
    否则是需要两次连接的
      

  6.   

    google了一把,好像是可以的挖http://www.czvc.com/view.asp?id=204http://zhidao.baidu.com/question/1588639.html