Questions tagged [procedures]

262 questions
0
votes
1 answer

SSRS - multiple stored procedures to be called based on a parameter

I have this specific issue in Microsoft SSRS 2008: I have to execute a stored procedure, which will return data with the same columns, but in different formats: EXEC Main_SP @View = ..... IF @View = Yearly, BEGIN EXEC SP_Yearly_Data END IF…
user3812887
  • 439
  • 12
  • 33
0
votes
2 answers

Oracle Procedures -Select/Insert Into - Need Multiple Results to Return -

I've seen questions similar to this but I can't seem to get this to properly work. I'm working on a procedure where it's pretty much acts as a simple select statement. Closures is the name of the main table. I'm using TOAD & APEX if that information…
user3204414
  • 13
  • 1
  • 3
0
votes
2 answers

Is this possible in mysql?

I would like to get the no of rows based on their ids. So i create a sample procedure in MySQL.This is not working for me. Please help me to get this. DELIMITER // CREATE PROCEDURE deleteObjectTypes(IN p_type VARCHAR(255)) BEGIN SELECT * FROM…
user3085540
  • 275
  • 3
  • 12
  • 27
0
votes
0 answers

MS SQL Server - System Rollback

We have a looped procedure which does a high volume data processing of transcating, loading and merging two tables using split and merge. During the data processing the system is rolling back the processed data even though there are no explicit…
0
votes
2 answers

SQL Server Transaction procedure

I am creating a transaction procedure. I am having a syntax error at the first if statement it says 'expecting variable' everything else is working fine not sure why it is having trouble.\here is the code Create Proc DP_Test4Transaction …
user3380392
  • 59
  • 2
  • 8
0
votes
1 answer

Selecting MySQL session variables multiple times

Having a weird problem selecting session variables which are changed by a stored procedure. call calculate("input1", "input2",@price); select @price; /*price is 2.00*/ call calculate("anotherinput","anotherinput2",@price); select @price;…
0
votes
1 answer

MySql Index and constraints

I need to drop all indexes and constraints and do some processing, after thar I have to apply same indexes and constraints again using MYSql.Please help. Please suggest if there is some way to store the information/metadata of index created.
0
votes
2 answers

Function : PLS-00306: wrong number or types of arguments in call to 'WORK_DAYS'

I am trying to create a package that includes both a function and procedure, with the function being called in the procedure. I feel like my code below should work but I keep getting the error PLS-00306: wrong number or types of arguments in call to…
user1643333
  • 127
  • 3
  • 7
  • 15
0
votes
1 answer

sqldeveloper procedure from select

Hi I have select like this SELECT ADDRESSES.PHONENUMBER1, ADDRESSES.PHONENUMBER2, FIRMS.NAME, ADDRESSES.COUNTRY, ADDRESSES.EMAIL, ADDRESSES.RECIPIENT FROM ADDRESSES INNER JOIN FIRMS ON FIRMS.RESIDENCEADDRESS_ID = ADDRESSES.ID WHERE…
pulpivo
  • 1
  • 2
0
votes
3 answers

changing variables inside procedures

I have created a variable inside the Start() procedure but it doesn't seem remember the variable outside of the procedure. Is there a way of getting python to remember the variable outside of the Start() procedure? My code is as follows: def…
Alderp
  • 23
  • 2
0
votes
1 answer

Use MySQL Procedure along with a Function

I have a fully working user defined function called CalculateDistance which will calculate the distance between the provided postcode and the one within the function. I want to know if there is some way to use this function to create some extra…
0
votes
1 answer

SQLPLUS returns only 1 and 0 numbers using dbms_output.put_line

http://shrani.si/f/S/52/2l8ZPmn7/stack.jpg I have problem in a M:1 relation. I have entity named "zaposleni" (M) and entity named "zapori" (1). The problem appears when I want to execute my procedure. Error says that my parent key wasn't found,…
0
votes
1 answer

How to insert into multiple tables from one table through procedures?

There are 4 tables Table1(Column11, Column12, Column13) Table2(Column21, Column22) Table3(Column31, Column32,column33) Table4(Column21, Column22) And the following Mapping Table: Table5(Sourcetable,Source column ,Destination table ,Destination…
0
votes
1 answer

Getting ORA-00904:invalid identifier error while executing a procedure

CREATE OR REPLACE FUNCTION CONCAT_BLOB(A in BLOB,B in BLOB) RETURN BLOB IS C BLOB; BEGIN DBMS_LOB.APPEND (C,A); DBMS_LOB.APPEND (C,B); RETURN C; END; CREATE OR REPLACE PROCEDURE update_NEW_REC_tmp is tempBlob BLOB :=utl_raw.cast_to_raw('^'); …
0
votes
1 answer

Getting part of query defined by a parameterized function

Hello all :) I'm try to do something like this in Oracle 10g: SELECT CAR_ID, CAR_DATE, get_some_other_info(CAR_TYPE) FROM CARS Where get_some_other_info(CAR_ID) would return several columns: | CAR_ID | CAR_DATE | CAR_COLOR | CAR_CO2 | 001 …
BenoitParis
  • 3,166
  • 4
  • 29
  • 56