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
  1. Home
  2. Database & SysAdmin
  3. Database
  4. variation in the output generated

variation in the output generated

Scheduled Pinned Locked Moved Database
helpsharepoint
2 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.
  • Y Offline
    Y Offline
    yuvachandra
    wrote on last edited by
    #1

    Hi all Actually am struglling with a problem ...here i got storedprocedure named Usp_Rpt_Proc1 which accepts two arguments in datetime fomat ...when am executing it from queryanaliser it's working fine am executing it like exec dbo.Usp_Rpt_Proc1 '1/1/2001','1/1/2008' it's returning some results as output but the problem is i want to modify that perticular procedure for that i copied and pasted the functionality (same code from SP) and inplace of CREATE PROCEDURE dbo.Usp_Rpt_Proc1 (@StartDate DateTime,@EndDate DateTime) AS am declare 2 datetime variables..and passing values for them ...and finaly am executing it.this time it's not returning any output...not showing errors aswelll just showing the column names with out content.... Plz let me now the reson behind it.....(In the second case am taking the exact code ...that's for sure).........Plz help me out With regards Yuva

    R 1 Reply Last reply
    0
    • Y yuvachandra

      Hi all Actually am struglling with a problem ...here i got storedprocedure named Usp_Rpt_Proc1 which accepts two arguments in datetime fomat ...when am executing it from queryanaliser it's working fine am executing it like exec dbo.Usp_Rpt_Proc1 '1/1/2001','1/1/2008' it's returning some results as output but the problem is i want to modify that perticular procedure for that i copied and pasted the functionality (same code from SP) and inplace of CREATE PROCEDURE dbo.Usp_Rpt_Proc1 (@StartDate DateTime,@EndDate DateTime) AS am declare 2 datetime variables..and passing values for them ...and finaly am executing it.this time it's not returning any output...not showing errors aswelll just showing the column names with out content.... Plz let me now the reson behind it.....(In the second case am taking the exact code ...that's for sure).........Plz help me out With regards Yuva

      R Offline
      R Offline
      Rami Said Abd Alhalim
      wrote on last edited by
      #2

      if you need return output parameter from stored procedure you must to set word out beside parameter for example declare @Time1 datetime declare @time2 datetime set @Time1 = '1/1/2001'--if this output parameter set out beside it set @Time2 = '1/1/2001' ============================================== exec dbo.Usp_Rpt_Proc1 @time1 out ,@Time2 out but this solve must used if the two output parameter CREATE PROCEDURE dbo.Usp_Rpt_Proc1 (@StartDate DateTime output,@EndDate DateTime output) =============================================== exec dbo.Usp_Rpt_Proc1 @time1 ,@Time2 out but this solve must used if the one output parameter CREATE PROCEDURE dbo.Usp_Rpt_Proc1 (@StartDate DateTime ,@EndDate DateTime output) ==================================================== exec dbo.Usp_Rpt_Proc1 @time1 ,@Time2 ,@output out but this solve must used if the one output parameter CREATE PROCEDURE dbo.Usp_Rpt_Proc1 (@StartDate DateTime ,@EndDate DateTime ,@output datatype output) if you need any thing reply with regards Rami Abd Alhalim

      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