Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
CODE PROJECT For Those Who Code
  • Home
  • Articles
  • FAQ
Community
  1. Home
  2. General Programming
  3. Visual Basic
  4. Test.sql cannot find my test

Test.sql cannot find my test

Scheduled Pinned Locked Moved Visual Basic
databasecsharpvisual-studiohelpcareer
3 Posts 2 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • R Offline
    R Offline
    reykentj
    wrote on last edited by
    #1

    Env: SQL2005 Sp2 Visual Studio 2005 Could not find stored procedure 'sbSetupDeptProfitnLoss'. Test.sql has statement exec sbSetupDeptProfitnLoss 1, 10,'6/1/2006' A vb module in this project has Partial Public Class StoredProcedures Public Shared Sub sbSetupDeptProfitnLoss(ByVal BranchCode As Long, _ ByVal DepartmentCode As Long, _ ByVal RequestDate As Date) Dim DepartmentName As String Dim result As Object Dim stDocName As String Dim StartofMonth As Date Dim EndOfMonth As Date Dim StrStartofMonth As String Dim fnBuildBudgetQuery On Error GoTo Err_sbSetupDeptProfitnLoss sbGetDepartmentName(DepartmentCode, DepartmentName) StrStartofMonth = DatePart("m", RequestDate) & "/" & "01/" & DatePart("yyyy", RequestDate) StartofMonth = StrStartofMonth EndOfMonth = EOMonth(StartofMonth, 1) sbBuild_L1QueryDeptSalesDetail(BranchCode, DepartmentCode, StartofMonth, EndOfMonth) sbBuild_L1QueryDeptCostOfGoodsDetail(BranchCode, DepartmentCode, StartofMonth, EndOfMonth) sbBuild_L1QueryDeptExpensesDetail(BranchCode, DepartmentCode, StartofMonth, EndOfMonth) sbBuildDeptSummaryProfitnLossTable(DepartmentCode, RequestDate) stDocName = "rptDeptProfitnLoss" 'DoCmd.OpenReport(stDocName, acPreview) Exit_sbSetupDeptProfitnLoss: Exit Sub Err_sbSetupDeptProfitnLoss: fnHandleError("sbSetupDeptProfitnLoss") Resume Exit_sbSetupDeptProfitnLoss Resume End Sub End Class rkj

    D 1 Reply Last reply
    0
    • R reykentj

      Env: SQL2005 Sp2 Visual Studio 2005 Could not find stored procedure 'sbSetupDeptProfitnLoss'. Test.sql has statement exec sbSetupDeptProfitnLoss 1, 10,'6/1/2006' A vb module in this project has Partial Public Class StoredProcedures Public Shared Sub sbSetupDeptProfitnLoss(ByVal BranchCode As Long, _ ByVal DepartmentCode As Long, _ ByVal RequestDate As Date) Dim DepartmentName As String Dim result As Object Dim stDocName As String Dim StartofMonth As Date Dim EndOfMonth As Date Dim StrStartofMonth As String Dim fnBuildBudgetQuery On Error GoTo Err_sbSetupDeptProfitnLoss sbGetDepartmentName(DepartmentCode, DepartmentName) StrStartofMonth = DatePart("m", RequestDate) & "/" & "01/" & DatePart("yyyy", RequestDate) StartofMonth = StrStartofMonth EndOfMonth = EOMonth(StartofMonth, 1) sbBuild_L1QueryDeptSalesDetail(BranchCode, DepartmentCode, StartofMonth, EndOfMonth) sbBuild_L1QueryDeptCostOfGoodsDetail(BranchCode, DepartmentCode, StartofMonth, EndOfMonth) sbBuild_L1QueryDeptExpensesDetail(BranchCode, DepartmentCode, StartofMonth, EndOfMonth) sbBuildDeptSummaryProfitnLossTable(DepartmentCode, RequestDate) stDocName = "rptDeptProfitnLoss" 'DoCmd.OpenReport(stDocName, acPreview) Exit_sbSetupDeptProfitnLoss: Exit Sub Err_sbSetupDeptProfitnLoss: fnHandleError("sbSetupDeptProfitnLoss") Resume Exit_sbSetupDeptProfitnLoss Resume End Sub End Class rkj

      D Offline
      D Offline
      Dave Kreskowiak
      wrote on last edited by
      #2

      Did you attribute this class and the sub appropriatly for use as a stored procedure? It doesn't look like it. Documentation on SqlProcedure attribute[^]

      Dave Kreskowiak Microsoft MVP Visual Developer - Visual Basic
           2006, 2007

      R 1 Reply Last reply
      0
      • D Dave Kreskowiak

        Did you attribute this class and the sub appropriatly for use as a stored procedure? It doesn't look like it. Documentation on SqlProcedure attribute[^]

        Dave Kreskowiak Microsoft MVP Visual Developer - Visual Basic
             2006, 2007

        R Offline
        R Offline
        reykentj
        wrote on last edited by
        #3

        Thank You Very Much. That Solved the problem:) rkj

        1 Reply Last reply
        0
        Reply
        • Reply as topic
        Log in to reply
        • Oldest to Newest
        • Newest to Oldest
        • Most Votes


        • Login

        • Don't have an account? Register

        • Login or register to search.
        • First post
          Last post
        0
        • Categories
        • Recent
        • Tags
        • Popular
        • World
        • Users
        • Groups