SQL procedure returning too many rows
问题 I've created a procedure that takes pid as parameter and returns monthly sale stats of that pid , it uses two tables, products and purchases where pid in purchases is foreign key referencing pid in products. The procedure builds without errors and executes well for only single row returns and otherwise give too_many_rows exception My procedure is as follows: set serveroutput on create or replace procedure try( p_pid in purchases.pid%type) is p_pname products.pname%type; p_date varchar2(10); p