Forum Replies Created

Viewing 15 posts - 46 through 60 (of 62 total)

  • RE: how to Update One table from Multiple Tables?

    Ok Sir, I'll reply you back soon with the code snippet.

    ----------------------------------------
    Daipayan
    A Beginner to the World of DBMS!
    ----------------------------------------
  • RE: how to Update One table from Multiple Tables?

    Thank You for your reply.

    Can't I use function or stored procedure??

    What can be the code snippet for trigger?

    ----------------------------------------
    Daipayan
    A Beginner to the World of DBMS!
    ----------------------------------------
  • RE: How to handle CASE related query??

    Sir,

    I just bought this books and I did not kept the book in one corner, am studying it regularly:

    # Beginning Transact - SQL with SQL Server 2000 and 2005...

    ----------------------------------------
    Daipayan
    A Beginner to the World of DBMS!
    ----------------------------------------
  • RE: How to handle CASE related query??

    I tried but failed, I read http://www.java2s.com, http://www.w3schools.com, but not getting the clue,am very new to this MS SQL, please help me...:crying:

    ----------------------------------------
    Daipayan
    A Beginner to the World of DBMS!
    ----------------------------------------
  • RE: How to handle CASE related query??

    Sir,

    Am trying!

    I am taking reference of my code:

    when sum(gradeno) = 0 and sum(case when remark = 'ABS' then 1 else 0 end)>0 then '0'

    and trying to fit in your code:

    .

    .

    case...

    ----------------------------------------
    Daipayan
    A Beginner to the World of DBMS!
    ----------------------------------------
  • RE: How to handle CASE related query??

    Am getting the Answer perfectly, but with the old problem i.e.

    -----------------------------------------------------------------------------------------------

    Student Course Credit IsAbsent GradeNo Grade Points...

    ----------------------------------------
    Daipayan
    A Beginner to the World of DBMS!
    ----------------------------------------
  • RE: How to handle CASE related query??

    Yes Sir, am using MS SQL Server 2000 and am StucK.

    Am getting the Answer perfectly, but with the old problem i.e.

    -----------------------------------------------------------------------------------------------

    StudentCourseCreditIsAbsentGradeNoGradePointsQuality

    -----------------------------------------------------------------------------------------------

    AndyASM013030F00

    AndyOB013035D13

    AndyOB01310ABS00

    BobASM013050D+26

    BobOB013041D13

    SteveASM013046D+26

    -----------------------------------------------------------------------------------------------

    See this Andy part, appearing twice, where it should appear...

    ----------------------------------------
    Daipayan
    A Beginner to the World of DBMS!
    ----------------------------------------
  • RE: How to handle CASE related query??

    Thanks for your effort.

    Yes Sir, the triple A should be C, D+ and D, that was my typing mistake, sorry!

    Am getting error while running this part of T-SQL:

    with

    OverallStudentGrade as (

    ...

    ----------------------------------------
    Daipayan
    A Beginner to the World of DBMS!
    ----------------------------------------
  • RE: How to handle CASE related query??

    Image Link: https://www.sqlservercentral.com/Forums/Uploads/image-unavailable.png

    This is my whole database schema, I have those stored procedures which you mentioned and thanks for your guidance.

    Sir in my last T-SQL, I want another extra stuff,...

    ----------------------------------------
    Daipayan
    A Beginner to the World of DBMS!
    ----------------------------------------
  • RE: How to handle CASE related query??

    Sir, one more favour!

    I want this whenever I update data in MyTable, then through this T-SQL, the Student, course,credit,grades,grade,points,quality will automatically updates in one table!

    Is this possible or not through...

    ----------------------------------------
    Daipayan
    A Beginner to the World of DBMS!
    ----------------------------------------
  • RE: How to handle CASE related query??

    select Student, course, credit, sum(gradeno) as Grades

    , case

    when sum(gradeno)...

    ----------------------------------------
    Daipayan
    A Beginner to the World of DBMS!
    ----------------------------------------
  • RE: How to handle CASE related query??

    Student course credit Grades Grade Points Quality

    ----------...

    ----------------------------------------
    Daipayan
    A Beginner to the World of DBMS!
    ----------------------------------------
  • RE: How to handle CASE related query??

    Sir,

    I had read your signature block and in my last post, I had posted the create table statements, and sample data for each table in my last post.

    I had used...

    ----------------------------------------
    Daipayan
    A Beginner to the World of DBMS!
    ----------------------------------------
  • RE: How to handle CASE related query??

    Sir,

    I reading the earlier replies from Steve Jones and Bitbucket, but I also want the 'ABS' part also, is there any other solution to this part.

    I modified Steve Jones query...

    ----------------------------------------
    Daipayan
    A Beginner to the World of DBMS!
    ----------------------------------------
  • RE: How to handle CASE related query??

    Sir/Madam,

    Am declaring another column in student_marks table named as remark

    Now, if in remark, it's given ABS/DN/WFC and sum of marks is 0, then in grade column, it will shown as...

    ----------------------------------------
    Daipayan
    A Beginner to the World of DBMS!
    ----------------------------------------

Viewing 15 posts - 46 through 60 (of 62 total)