Código:
DECLARE
3 v_NumberSeats rooms.number_seats%TYPE;
4 v_Comment VARCHAR2(35);
5 BEGIN
6 SELECT number_seats
7 INTO v_Numberseats
8 FROM rooms
9 WHERE id = 1;
10 IF v_NumberSeats < 10 THEN
11 v_Comment :='Small';
12 ELSIF v_NumberSeats < 20 THEN
13 v_Comment :='Bigger';
14 ELSE v_Comment :='lots';
15 END IF;
16 END;
17 /
Código:
SQL> CREATE PROCEDURE ejer1 AS
2 DECLARE
3 v_NumberSeats rooms.number_seats%TYPE;
4 v_Comment VARCHAR2(35);
5 BEGIN
6 SELECT number_seats
7 INTO v_Numberseats
8 FROM rooms
9 WHERE id = 1;
10 IF v_NumberSeats < 10 THEN
11 v_Comment :='Small';
12 ELSIF v_NumberSeats < 20 THEN
13 v_Comment :='Bigger';
14 ELSE v_Comment :='lots';
15 END IF;
16 END;
17 /
¿Cual puede ser el problema?
Estoy bastante perdido en este tema, agradezco la ayuda