Questions tagged as 'oracle'

1
answer

Variable without value pl / sql

I tried to run this pl / sql but it did not work declare v teste%rowtype; begin v.ra; select ra into v.ra from teste where nome = 'Danilo'; dbms_output.put_line(v.ra); end; After a long time I decided to assign a value to it and then change...
asked by 06.05.2018 / 00:00
4
answers

Optimization in sql

Considering these two tables in the database: Product Table: | id | nome | |-----|-----------| | aaa | Produto A | | bbb | Produto B | | ccc | Produto C | Attributes Table: | id_produto | atributo | valor | |------------|------...
asked by 21.03.2018 / 20:40
1
answer

How to give select in XML and return a specific column from an anonymous block?

I have an anonymous PL / SQL block that returns an XML to me as the result of running a web service. How do I give a select in this XML to get only one column I want?    Anonymous block: DECLARE l_filename varchar2(255); l_BLOB BLOB; l_CLO...
asked by 07.05.2018 / 20:18
1
answer

How to enter values in Laravel

I'm trying to use the following command to insert: $sql = "INSERT INTO tabela (campo1, campo2, campo2, campo4) values(:campo1, :campo2, :campo3,'S')"; $campos = array( ':campo1' => $nome,...
asked by 06.03.2018 / 20:18
1
answer

ORACLE SQL - Sort by sum

I need to make a report and I can not sort it as a wish, I want to select customer debit between 60 and 120 days and sort by total. The code looks like this: SELECT SUM(cod_fat_cli) "Total", nom_cad_cli "Nome", end_cad_cli "Endereço" FR...
asked by 23.02.2018 / 16:57
1
answer

Start and end of a month / year passed in parameter (Oracle)

I need to return the total monthly data according to the parameter of MONTH and YEAR reported. I did as follows: WHERE a.dt_mesano_referencia between to_date('01/'|| :NR_MES ||'/'|| :NR_ANO ||' 00:00:00', 'dd/mm/yyyy hh24:mi:ss') and last_...
asked by 14.06.2018 / 15:08
1
answer

Consistent sum of a column in SQL

I wanted to calculate the data of a bad table as follows I have a price column    100 140 300 200 I wanted to generate a second column that would make a consecutive sum of the previous table    100 240 540 740 I was able t...
asked by 11.02.2018 / 05:49
1
answer

Error connecting oracle

I'm trying to perform insert operation on oracle by Laravel (5.6), but it's giving error: The method I make the insert is this: public function salvar( Request $request ){ $agenda = new Agenda(); $agenda->dt_agenda = $req...
asked by 14.02.2018 / 15:36
1
answer

Sql executes in Oracle SQL Developer, but does not run in the C #

vsql = @"INSERT INTO ALUNOS_ (UF, IDADE, TELEFONE, NOME_PAI, ENDERECO, EMAIL, NOME, CIDADE, NOME_MAE) values ('sp', 0,'','','','','','','');"; This SQL when executed in oracle does the insertion but in the...
asked by 31.01.2018 / 14:20
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