Skip to main content
etiquetas editadas
Enlace
Ruslan López
  • 11.8k
  • 14
  • 44
  • 88
Arreglo de código mal puesto
Origen Enlace
masterguru
  • 16k
  • 5
  • 15
  • 28

No encuentro fallo de sintaxis

DELIMITER // CREATE OR REPLACE PROCEDURE pAddTwoProjects (userId_P1 INT , nameP1 VARCHAR, amountP1 INT, yearP1 INT, userId_P2 INT, nameP2 VARCHAR, amountP2 INT, yearP2 INT) BEGIN INSERT INTO projects (idUser, projectName, budget, projectYear) VALUES (userId_P1 , nameP1 , amountP1 , yearP1 ); INSERT INTO projects (idUser, projectName, budget, projectYear) VALUES (userId_P2 , nameP2 , amountP2 , yearP2 ); END //
DELIMITER ;

CALL pAddTwoProjects(1, “Proyecto Albatros”, 10000, 2022, 2, “Proyecto Búho”, 10000, 2023)

DELIMITER //
CREATE OR REPLACE PROCEDURE
        pAddTwoProjects (userId_P1 INT , nameP1 VARCHAR, amountP1 INT, yearP1 INT,
                            userId_P2 INT, nameP2 VARCHAR, amountP2 INT, yearP2 INT)
BEGIN
        INSERT INTO projects (idUser, projectName, budget, projectYear) VALUES (userId_P1 , nameP1 , amountP1 , yearP1 );
        INSERT INTO projects (idUser, projectName, budget, projectYear) VALUES (userId_P2 , nameP2 , amountP2 , yearP2 );
END //      
DELIMITER ;

CALL pAddTwoProjects(1, “Proyecto Albatros”, 10000, 2022,
                            2, “Proyecto Búho”, 10000, 2023)

DATOS USUARIO

Procedure

No encuentro fallo de sintaxis

DELIMITER // CREATE OR REPLACE PROCEDURE pAddTwoProjects (userId_P1 INT , nameP1 VARCHAR, amountP1 INT, yearP1 INT, userId_P2 INT, nameP2 VARCHAR, amountP2 INT, yearP2 INT) BEGIN INSERT INTO projects (idUser, projectName, budget, projectYear) VALUES (userId_P1 , nameP1 , amountP1 , yearP1 ); INSERT INTO projects (idUser, projectName, budget, projectYear) VALUES (userId_P2 , nameP2 , amountP2 , yearP2 ); END //
DELIMITER ;

CALL pAddTwoProjects(1, “Proyecto Albatros”, 10000, 2022, 2, “Proyecto Búho”, 10000, 2023)

DATOS USUARIO

Procedure

No encuentro fallo de sintaxis

DELIMITER //
CREATE OR REPLACE PROCEDURE
        pAddTwoProjects (userId_P1 INT , nameP1 VARCHAR, amountP1 INT, yearP1 INT,
                            userId_P2 INT, nameP2 VARCHAR, amountP2 INT, yearP2 INT)
BEGIN
        INSERT INTO projects (idUser, projectName, budget, projectYear) VALUES (userId_P1 , nameP1 , amountP1 , yearP1 );
        INSERT INTO projects (idUser, projectName, budget, projectYear) VALUES (userId_P2 , nameP2 , amountP2 , yearP2 );
END //      
DELIMITER ;

CALL pAddTwoProjects(1, “Proyecto Albatros”, 10000, 2022,
                            2, “Proyecto Búho”, 10000, 2023)

DATOS USUARIO

Procedure

Origen Enlace

Fallo sintaxis MySQL. Procedure, Insert, call

No encuentro fallo de sintaxis

DELIMITER // CREATE OR REPLACE PROCEDURE pAddTwoProjects (userId_P1 INT , nameP1 VARCHAR, amountP1 INT, yearP1 INT, userId_P2 INT, nameP2 VARCHAR, amountP2 INT, yearP2 INT) BEGIN INSERT INTO projects (idUser, projectName, budget, projectYear) VALUES (userId_P1 , nameP1 , amountP1 , yearP1 ); INSERT INTO projects (idUser, projectName, budget, projectYear) VALUES (userId_P2 , nameP2 , amountP2 , yearP2 ); END //
DELIMITER ;

CALL pAddTwoProjects(1, “Proyecto Albatros”, 10000, 2022, 2, “Proyecto Búho”, 10000, 2023)

DATOS USUARIO

Procedure