View the output from Trigger

Discussion in 'Database' started by Dilini, Sep 22, 2015.

  1. Dilini

    Dilini New Member

    Joined:
    Sep 18, 2015
    Messages:
    2
    Likes Received:
    0
    Trophy Points:
    0
    I created Trigger there is no errors but I can't see the answer I use this code given below but it is not working

    SELECT @Count_No FROM Books WHERE 'No_of_Publisher_year ';
    Empty set, 1 warning (0.00 sec)
    :embarasse
    Code:
    DELIMITER $$
    CREATE TRIGGER No_of_Publisher_year 
    Before Insert ON Books 
    FOR EACH ROW 
    Begin 
     SET @Count_NO=(SELECT Count(@Count_NO) AS 'No_of_publisher_in_year_2007' FROM Books WHERE Copyright=2007);
     
     END $$
    DELIMITER ;
    
    
     

Share This Page

  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice