TECHNOLOGIES
FORUMS
JOBS
BOOKS
EVENTS
INTERVIEWS
Live
MORE
LEARN
Training
CAREER
MEMBERS
VIDEOS
NEWS
BLOGS
Sign Up
Login
No unread comment.
View All Comments
No unread message.
View All Messages
No unread notification.
View All Notifications
Answers
Post
An Article
A Blog
A News
A Video
An EBook
An Interview Question
Ask Question
Forums
Monthly Leaders
Forum guidelines
shiji josh
NA
2
619
solve incorect syntax near )
May 23 2019 4:51 AM
exec('INSERT INTO #ExamMarkEntryTotal SELECT SYD.StudentID,EM.ExamID,-1,2,ECSD.SubjectID,0 AS SubjectDivisionId,ESGM.SubjectGroupID,ESGM.EntryTypeId,
ECSD.PriorityNo,ROUND(CASE WHEN ME.Mark<0 THEN 0 ELSE ME.Mark END,1),ECSMD.MaximumMark,ECSMD.MinimumMark,ME.Remark,ECSD.ClasswiseSubjectId,ECGD.ExamGroupID,ME.Mark,ECSMD.Weightage
FROM StudentAcademicYearWisedetails SYD INNER JOIN ClassSectionDetails CSD ON CSD.ClassID=SYD.ClassId AND
CSD.SectionID=SYD.SectionID AND SYD.AcademicYearID=CSD.AcademicYearID INNER JOIN ExamClasswiseSubjectDetails ECSD ON CSD.ClassDetailID=ECSD.ClassDetailID
INNER JOIN ExamClasswiseSubjectMarkDetails ECSMD ON ECSD.ClasswiseSubjectID=ECSMD.ClasswiseSubjectId
LEFT JOIN ExamOptionalSubjectDetails OSD ON OSD.ClassDetailID=ECSD.ClassDetailID AND OSD.SubjectID=ECSD.SubjectId
LEFT JOIN ExamStudentOptionalSubjectDetails SOSD ON SOSD.StudentID=SYD.StudentID AND SOSD.SubjectID=ECSD.SubjectId
LEFT JOIN ExamMarkEntry ME ON ME.StudentId=SYD.StudentID AND ME.ClasswiseSubjectId=ECSD.ClasswiseSubjectID
LEFT JOIN ExamMarkAbbreviationMaster MA ON MA.ExamMarkAbbreviationID=ME.Mark
INNER JOIN ExamMaster EM ON EM.ExamID=ECSD.ExamID INNER JOIN
ExamClassGroupDetails ECGD ON ECGD.ClassDetailID=CSD.ClassDetailID INNER JOIN
ExamGroupExamDetails EGED ON ECSD.ExamID=EGED.ExamID AND EGED.ExamGroupID=ECGD.ExamGroupID INNER JOIN
ExamSubjectMaster ESM ON ESM.SubjectID=ECSD.SubjectID INNER JOIN ExamSubjectGroupMaster ESGM ON
ESGM.SubjectGroupID=ESM.SubjectGroupID
WHERE ESM.SSubjectID NOT IN ('+@AttSubjectID+') AND ESM.SubjectTypeID=1 AND (OSD.SubjectID is null OR SOSD.SubjectID is not null) AND SYD.AcademicYearID='+@AcademicYearID+' AND ESGM.EntryTypeId=1 AND CSD.ClassID='+@ClassID+' AND CSD.SectionID='+@SectionID+' AND
EM.ExamID IN ('+@Exams+') '+@strQry+'')
Reply
Answers (
3
)
how to get last 8 month from 2019 and first 3 month from fin
Insert into select from two tables values an instert in anot