Questions tagged as 'stored-procedures'

1
answer

Why a Stored Procedure generates different results if executed in Workbench and Java with JDBC

I have a Stored Procedure in MySQL that is working normally when I run from the Workbench, but when I execute this same procedure in Java / JBDC I am getting erroneous values different from those obtained in the Workbench. My Stored Procedure...
asked by 07.10.2015 / 21:07
1
answer

.Parameters.Append .CreateParameter is not passing the second parameter

I have a system in ASP Classico, and I'm trying to execute a SQL Server procedure passing two parameters. I originally passed only one selected date in a datepicker and it worked, now I want to pass an int value obtained in a combo (containin...
asked by 10.09.2015 / 15:46
1
answer

How to convert DateTime type to nvarchar?

I have a table with a column of type nvarchar , and I pass the following parameter to the stored procedure : cmd.Parameters.Add("@PointDate", SqlDbType.NVarChar).Value = DateTime.Now; As expected, I'm getting the following error: A...
asked by 21.05.2015 / 16:11
1
answer

Syntax Error in MySQL Procedure

I have the following Stored Procedure. When you run it, the syntax error 1064 is not returned as in the image below. What am I missing?     
asked by 18.03.2015 / 17:11
1
answer

Execute stored procedure in oracle database in PHP

I have procedure " example1 " which receives 3 input parameters and none output, how do I execute it in PHP . That would be the case. EXEC "exemplo1"('para1','para1','para3'); $sql = 'EXECUTE "PORTAL_importaXml"'. "(?,?,?...
asked by 03.09.2018 / 21:42
2
answers

Is it possible to execute 2 queries at the same time in MySQL?

I need to create a stored procedure to update the salary of employees who earn less than 1000 and give a 10% increase. Other employees (who earn over 1000) will have a 15% reduction. I've done the following: DELIMITER $ CREATE PROCEDURE mod...
asked by 03.12.2018 / 02:09
1
answer

Procedures Conversion [closed]

Someone knows or knows an easy way to migrate stored procedures from SQL Server to Oracle.     
asked by 19.09.2018 / 14:40
1
answer

Call procedure inside another

I need to create a procedure enviar_email_servidores that calls another pr_envia_email . The procedure to be called ( pr_envia_email ) has the function of sending e-mail, and I need the message sent to this email to be the...
asked by 14.04.2016 / 19:41
1
answer

Procedures MySql

Hello, I'm new to procedures and I have a question I did not find on the internet. I need to create a procedure to include 2 tables: "User", "Supplier". The provider has a user FK, that is, in this procedure, I need to insert a user, get t...
asked by 20.10.2018 / 05:57
1
answer

Create stored procedure with MySQL

I do EAD for a bank and have very little material to help me do my activities. I have this question to solve, if anyone can help me or help me with some study material path I am very grateful. Create a stored procedure call sp_generate_q...
asked by 30.11.2017 / 14:25