Questions tagged as 'procedure'

1
answer

Error creating procedure in oracle

When declaring the name of a procedure in sqldevelope I get this message Erro: ORA-00972: identifier is too long Naming example: PRC_IMVW_TISS_VERIFICA_ELEGIBILIDADE CREATE OR REPLACE PROCEDURE PRC_IMVW_TISS_VERIFICA_ELEGIBILIDADE AS...
asked by 19.01.2018 / 20:24
1
answer

Error executing oracle procedure

I have this procedure: CREATE OR REPLACE PROCEDURE buscaturma(cod in INTEGER) AS nomeT varchar2(20); BEGIN dbms_output.put_line('inicio'); IF (cod=0)then dbms_output.put_line('ZERO'); ELSE SELECT DS_TURMA into nomeT...
asked by 23.01.2018 / 14:30
1
answer

Call Procedure with Oracle return in Codeigniter

I'm developing a system and in a part of the code, I need to call a procedure and it returns a value. How can I do this? For the time being I did it and it did not work: $sql = "CALL P_VERIFICA_VALORES(" . $this->_databas...
asked by 19.09.2017 / 22:28
1
answer

Oracle End of file when executing procedure

I'm having the following error message when executing this procedure *Encontrado simbolo "end of file" quando era esperado:* DECLARE -- LOCAL VARIABLES HERE I INTEGER; BEGIN FOR NCM IN (SELECT * FROM NCM_NCM) LOOP UPDATE ADMPRODU...
asked by 04.04.2017 / 18:53
1
answer

Should I use prepare in Procedures

Below I have a code snippet adapted to exemplify this question: <?php $params = [ ':codUser' => $_SESSION['data-user']['codigo'], ':codCarrinho' => $codCarrinho, ':codPremio' => $codPremio, ':quantidade' =&g...
asked by 10.02.2017 / 18:27
1
answer

STORED PROCEDURE

I have 2 procedures and I wanted to call the procedure sp_is_temporada in the procedure sp_calcula_curso , and the value that the procedure sp_is_temporada return will be used in procecure sp_calcula_curso , and the arg...
asked by 10.09.2015 / 15:38
3
answers

Filters records via datetime and fetch them between a start date and end date

I have the balance table, which always when executing a procedure, is generated a new record in the same, being able to have several record the same day ... However, when I make an appointment, I want to bring only the last record of each da...
asked by 19.06.2015 / 19:57
2
answers

Pass table field as parameter in a procedure

I made this procedure to bring records of a table between dates, but I need to pass the date field of the table to the command between function, follow the code: DELIMITER // CREATE PROCEDURE pro_get_gastos(nome_tabela VARCHAR(20), data_ini DA...
asked by 18.06.2015 / 18:07
1
answer

error converting an Oracle procedure to a PostgreSql function in the pl / pgsql language

I have adapted the code, but the following error appears:    ERROR: relation "fields" does not exist CONTEXT: compilation of PL / pgSQL function "p_grava_log" CREATE OR REPLACE FUNCTION F_GRAVA_LOG ( TIPO character varying, C_TABELA...
asked by 07.01.2015 / 17:26
3
answers

How to find values in pascal

I'm setting up a program here in Pascal, where I have a record with 3 positions, each with name, age and weight. I also have a procedure called Query, which will allow me to search for a registered name, and return their age and weight. My probl...
asked by 30.04.2014 / 00:49