Click here to Skip to main content
15,885,914 members
Home / Discussions / Database
   

Database

 
GeneralRe: Need help with a tricky MS SQL Query Pin
jschell28-Nov-12 8:43
jschell28-Nov-12 8:43 
AnswerRe: Need help with a tricky MS SQL Query Pin
Deepak Kr128-Nov-12 1:03
Deepak Kr128-Nov-12 1:03 
QuestionBest Approach For Designing Database Pin
AmbiguousName27-Nov-12 3:59
AmbiguousName27-Nov-12 3:59 
AnswerRe: Best Approach For Designing Database Pin
jschell27-Nov-12 13:13
jschell27-Nov-12 13:13 
AnswerRe: Best Approach For Designing Database Pin
Mycroft Holmes27-Nov-12 13:14
professionalMycroft Holmes27-Nov-12 13:14 
AnswerRe: Best Approach For Designing Database Pin
Eddy Vluggen27-Nov-12 13:23
professionalEddy Vluggen27-Nov-12 13:23 
AnswerRe: Best Approach For Designing Database Pin
Krishna Kumar Soni3-Dec-12 1:04
Krishna Kumar Soni3-Dec-12 1:04 
QuestionEXEC sp_helptext Pin
jojoba201126-Nov-12 22:43
jojoba201126-Nov-12 22:43 
my stored procedure is :

SQL
USE [CRM-CMSAlmas]
GO
/****** Object:  StoredProcedure [dbo].[tblVacationDaily_GetAllDetailsSenderReciverbyRecordIdANDJobIdAndStepId]    Script Date: 11/27/2012 13:07:29 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO

ALTER PROCEDURE [dbo].[tblVacationDaily_GetAllDetailsSenderReciverbyRecordIdANDJobIdAndStepId] 
(@RecordId INT,@JobId INT,@StepId int)
AS
BEGIN

SELECT     WF.Cartable.JobId, Forms.tblVacationDaily.Id,  Forms.tblVacationDaily.IsWorkFlow, Forms.tblVacationDaily.CreateUserID, 
                      Forms.tblVacationDaily.CreateDate, Forms.tblVacationDaily.StepId, Forms.tblVacationDaily.RecordId, Forms.tblVacationDaily.OrderId, Forms.tblVacationDaily.PersonId, 
                      WF.Cartable.ForwardedUserId, WF.Cartable.RecieveUserId, WF.Cartable.IsDeleted, p1.FullName AS RecieveUserName, p2.FullName AS ForwardedUserName, 
                      WF.Cartable.IsBack
FROM         WF.Cartable INNER JOIN
                      WF.JobFormConjuction ON WF.JobFormConjuction.JobId = WF.Cartable.JobId INNER JOIN
                      Forms.tblVacationDaily ON Forms.tblVacationDaily.RecordId = WF.JobFormConjuction.RecordId AND Forms.tblVacationDaily.StepId = WF.Cartable.StepID - 1 INNER JOIN
                      Persons.People AS p1 ON p1.Id = WF.Cartable.RecieveUserId INNER JOIN
                      Persons.People AS p2 ON p2.Id = WF.Cartable.ForwardedUserId
WHERE     (Forms.tblVacationDaily.RecordId = @RecordId) AND (WF.Cartable.JobId = @JobId) AND (Forms.tblVacationDaily.StepId<=@StepId)
END


but when i use <pre lang="SQL">EXEC sp_helptext [dbo.tblVacationDaily_GetAllDetailsSenderReciverbyRecordIdANDJobIdAndStepId]</pre><br />
<br />
the result is :[Note: I have change Create ----> Alert


SQL
Alter PROCEDURE [dbo].[tblVacationDaily_GetAllDetailsforSenderAndReciversbyRecordIdANDJobId] 
(@RecordId INT,@JobId INT,@StepId int)
AS
BEGIN

SELECT     WF.Cartable.JobId, Forms.tblVacationDaily.Id,  Forms.tblVacationDaily.IsWorkFlow, Forms.tblVacationDaily.CreateUserID, 
                      Forms.tblVacationDaily.CreateDate, Forms.tblVacationDaily.StepId, Forms.tblVacationDaily.RecordId, Forms.tblVacationDaily.OrderId, Forms.tblVacationDaily.PersonId, 
                      WF.Cartable.ForwardedUserId, WF.Cartable.RecieveUserId, WF.Cartable.IsDeleted, p1.FullName AS RecieveUserName, p2.FullName AS ForwardedUserName, 
                      WF.Cartable.IsBack
FROM         WF.Cartable INNER JOIN
                      WF.JobFormConjuction ON WF.JobFormConjuction.JobId = WF.Cartable.JobId INNER JOIN
                      Forms.tblVacationDaily ON Forms.tblVacationDaily.RecordId = WF.JobFormConjuction.RecordId AND Forms.tblVacationDaily.StepId = WF.Cartable.StepID - 1 INNER JOIN
                      Persons.People AS p1 ON p1.Id = WF.Cartable.RecieveUserId INNER JOIN
                      Persons.People AS p2 ON p2.Id = WF.Cartable.ForwardedUserId
WHERE     (Forms.tblVacationDaily.RecordId = @RecordId) AND (WF.Cartable.JobId = @JobId) AND (Forms.tblVacationDaily.StepId<=@StepId)
END
 Go


C#
Now the BUG/ERROR :
The content is same but the names are diffrent :
[dbo].[tblVacationDaily_GetAllDetailsforSenderAndReciversbyRecordIdANDJobId] 

but the sp is :

[dbo].[tblVacationDaily_GetAllDetailsSenderReciverbyRecordIdANDJobIdAndStepId]

why the names are different ?

AnswerRe: EXEC sp_helptext Pin
Mycroft Holmes26-Nov-12 23:30
professionalMycroft Holmes26-Nov-12 23:30 
QuestionRe: EXEC sp_helptext Pin
jojoba201126-Nov-12 23:38
jojoba201126-Nov-12 23:38 
AnswerRe: EXEC sp_helptext Pin
Corporal Agarn27-Nov-12 0:59
professionalCorporal Agarn27-Nov-12 0:59 
QuestionRe: EXEC sp_helptext Pin
jojoba201127-Nov-12 3:09
jojoba201127-Nov-12 3:09 
AnswerRe: EXEC sp_helptext Pin
Eddy Vluggen27-Nov-12 13:33
professionalEddy Vluggen27-Nov-12 13:33 
QuestionRECORD VALIDATION IN ACCESS Pin
teto26-Nov-12 5:19
teto26-Nov-12 5:19 
SuggestionRe: RECORD VALIDATION IN ACCESS Pin
André Kraak26-Nov-12 5:56
André Kraak26-Nov-12 5:56 
AnswerRe: RECORD VALIDATION IN ACCESS Pin
Corporal Agarn26-Nov-12 6:05
professionalCorporal Agarn26-Nov-12 6:05 
Questionhow to compare an operation in where expression In sql Pin
GREG_DORIANcod26-Nov-12 4:29
professionalGREG_DORIANcod26-Nov-12 4:29 
AnswerRe: how to compare an operation in where expression In sql Pin
s_magus26-Nov-12 5:20
s_magus26-Nov-12 5:20 
AnswerRe: how to compare an operation in where expression In sql Pin
Mycroft Holmes26-Nov-12 11:56
professionalMycroft Holmes26-Nov-12 11:56 
Questiongrant permission on table in another database Pin
Danzy8326-Nov-12 3:55
Danzy8326-Nov-12 3:55 
QuestionRe: grant permission on table in another database Pin
Chris Meech26-Nov-12 8:25
Chris Meech26-Nov-12 8:25 
QuestionHow to mearge local database with server database Pin
Jitendra Parida - Jeetu23-Nov-12 22:00
Jitendra Parida - Jeetu23-Nov-12 22:00 
AnswerRe: How to mearge local database with server database Pin
Mycroft Holmes23-Nov-12 22:17
professionalMycroft Holmes23-Nov-12 22:17 
AnswerRe: How to mearge local database with server database Pin
Corporal Agarn25-Nov-12 2:48
professionalCorporal Agarn25-Nov-12 2:48 
GeneralRe: How to mearge local database with server database Pin
Jitendra Parida - Jeetu25-Nov-12 18:13
Jitendra Parida - Jeetu25-Nov-12 18:13 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.