請問一下  我用SQL自代的Profiler追蹤資料庫 結果裡面顯示的一些exec語句後面跟的函數名  這些是不是資料庫中的存儲過程名?  要怎樣才能查看到這些存儲過程。  例以下這段:
declare @P1 int
set @P1=180150010
declare @P2 int
set @P2=2
declare @P3 int
set @P3=1
declare @P4 int
set @P4=-1
exec sp_cursoropen @P1 output, N'select * from ieel00h where el_no=''XYZ-12''', @P2 output, @P3 output, @P4 output
select @P1, @P2, @P3, @P4

解决方案 »

  1.   

    sp_cursoropen 是存储过程的名字,加@的都是参数。
    你可以在企业管理器里,找到资料库所在的数据库实例,点击左边“存储过程”后,在右边列表中就是所有该数据库实例的存储过程了.
      

  2.   

    那再問一下  以上這個例子中  這段代碼在這有什麼意思:
     N'select * from ieel00h where el_no=''XYZ-12''',
      

  3.   

    在表ieel00h中查询所有 el_no列等于XYZ-12的数据
      

  4.   

    你这是Server Side Cursor, 是由ADO产生的.在你的跟踪中应该还有类似下面的语句:exec sp_cursorfetch 180150010, 16, 1, 1
    go
    exec sp_cursorfetch 180150010, 16, 2, 1
    go
    exec sp_cursorfetch 180150010, 16, 3, 1
    go
    exec sp_cursorfetch 180150010, 16, 4, 1
    go
    .....你给的是建立Server Side Cursor的过程, 我给的是每次取一列数据....