Most voted "oracle" questions
Oracle Server is a relational DBMS (Danco Data Management System), created by Oracle Corporation. Do not use this tag for other Oracle owned Sgdbs servers (for example Mysql, Timesten and Berkeley DB).
Learn more…1,134 questions
Sort by count of
-
0
votes0
answers52
viewsCreate Trigger in oracle
I have three tables: Usuario, Lembrete and Lembrete_Usuario on the Oracle. I am trying to create a Rigger that when I insert in the User table and Reminder, take the ids, User and Reminder, and put…
-
0
votes0
answers172
viewsAdd column to SQL considering some conditions to be valid
I’m trying to gather two pieces of information and I’m not getting it. I set up this SQL to bring me only the products that were purchased that had a discount through a contract. However this…
-
0
votes0
answers42
viewsDoubt oracle query 11g
Good afternoon, would like to create "Cycles" (Cycle field, increasing sequential numbering), where the beginning of the cycle will always be in the "Cod = 10 (Cod field)" and the End of cycle the…
-
0
votes2
answers798
viewsSum with Internet Oracle
Staff need a help, I need to create a report that shows the total quantity of each product in stock, but I can not make appear the name of the products, only the product code and the sum of the…
-
0
votes1
answer90
viewsConvert a sql to_date to a java date
My problem is the following, I have to take rows of SQL Insert and check whether the formats in the TO_DATE function in these Inserts are valid with a java method. For a 'DD/MM/YYYY' format,…
-
0
votes2
answers235
viewsEnsure query result random sorting
I have the query below, which I use to check IP’s valid collectors in the network for distribution of items for separation: Select distinct IP, USUARIO, trunc(DATA) from PCN_ROMANEIO_ACESSO PRA…
-
0
votes1
answer29
viewsSQL query with WITH to group
what should change in my consultation WITH Consulta AS (SELECT DT_RFRN_MVMN, TX_DATA_VNDA, CD_BNDR, CD_CRDE, CD_PCSR CD_EMSR, CD_TIPO_PLTF_PGMN, CD_TIPO_TRNS_BNDR_RECB, CD_TIPO_APRS_TRNS_RECB,…
oracleasked 7 years ago Bruno Minghini 1 -
0
votes1
answer550
viewsUpdate oracle with separate information
I’m trying to do an oracle update with completely different information and I don’t know how to do it. I want all other campuses to be the same as campus 1, where this id_campus is a Foreign key…
-
0
votes0
answers48
viewsQuery Performance - HELP
I’m making a query, but I am learning now. There is a way to improve the performance of this query? select a.COD_EMPRESA, b.Dat_pagamento from SAS_EMPRESA a full outer join SAS_ITEM_PAGO b on…
-
0
votes1
answer1140
viewsTrigger to upgrade stock
I’m trying to create a trigger to update my stock of products, when the status of my purchase is closed (CF = Closed Purchase). However, it is sending me an error, and I could not identify what is…
-
0
votes1
answer350
viewsInvalid SQL (INNER JOIN) indenter error
Select a list of employees who have changed positions or departments (job_history), the list must contain the employee’s registration and name, the name of the department and position that worked,…
-
0
votes1
answer53
viewsUsing "select" in sql (oracle), failed to search
I have to settle the following question: 1.Consult EL NOMBRE (DESCRIPCION) DE LOS PRODUCTOS ADQUIRIDOS POR LOS CLIENTES HOOPS Y GOOD SPORT EN EL ANNO 1990. the command used for the search was:…
-
0
votes0
answers734
viewsSQL username and password
During the installation of SQL Developer 17.3.1 on Ubuntu 16.04, it did not ask user and password. In this case I cannot log in, is there any default user or some way to configure a user?
-
0
votes0
answers20
viewsDjango Rest Framework retrieves Empty values Instead of null when using Oracle DB
I’m using Django Rest Framework, so when i Insert a field with null value [POST Model], it retrieves it with an Empty value [Get Object Detail]. Why does it happen?
-
0
votes1
answer1418
viewsName table resulting from SELECT
I need to make a SELECT of the table resulting from another SELECT, but I need to refer it to ON of INNER JOIN. How do I do this in Oracle (PL/SQL)? I tried it this way but it didn’t work: SELECT *…
-
0
votes1
answer274
viewsWhy does MOD(11.2,2) give 1,2 and not 0?
I need to take the rest of a division in ORACLE and I am using MOD that works very well with integers but when using decimal numbers it is a problem. Ex : MOD(11,2) = 1 ok MOD(11.2,2) = 1.2 Wrong is…
-
0
votes2
answers107
viewsSQL result in columns
I have an appointment Oracle SQL that returns the records per row, and I wanted to turn that into column. I did a search and find that the Pivot does this, but I don’t know how to use it, someone…
-
0
votes3
answers1241
viewsStatement Where comparing Date(type date) variable with current date
Hello. I am using Oracle SQL and need a query that returns values where the date is equal to the current date. Oracle has some word reserved for current date in the system? My code: insert into…
-
0
votes0
answers58
viewsRegister in table if query returns result (Oracle)
I’m developing a call panel. I have a query that results in the client call (name/password/Guiche), this query shows the result for 10 seconds, after that it is empty until the next call. I need…
-
0
votes1
answer192
viewsHow to properly configure & character in SQL Developer 17.3
Hello friends I am trying to make a sql query in SQL Developer as follows: SELECT * FROM CLIENTE WHERE NOME_CLIENTE IN ('SALES & CIA AGUIAR', 'SAO JOAO') The tool is understanding the character…
-
0
votes0
answers81
viewsChange Mysql query to work on SQL Server and Oracle
Would anyone know how this query in Mysql would look in SQL Server and Oracle? SELECT COUNT(*) AS TOTAL, SUM(EVENTO = 7 AND RESULTADO = 0) AS QTD_RX_OK, SUM(EVENTO = 7 AND RESULTADO <> 0) AS…
-
0
votes1
answer77
viewsInsert error in Oracle database with Java
When I make a set of insertions in the bank, it says that only the information of the course were inserted, but gang nay. Console STATUS DE CURSO: true STATUS DE CURSO: false Joptionpane Touradao…
-
0
votes0
answers697
viewsError: ORA-01461: can bind a LONG value only for Insert into a LONG column
I’m getting this error on Oracle. Error: ORA-01461: can bind a LONG value only for Insert into a LONG column When executing the code below that the error is presented, I would like to know how to…
-
0
votes1
answer569
viewsHow to create a JOB in ORACLE for backup?
Good afternoon, you guys! I am still novice in the subject when it comes to sql, I would like to know how to create a JOB (or other operation that does the same) that performs a data extraction from…
-
0
votes1
answer275
viewsHow to compare two fields of identical values to different sizes?
I have a database in which have fields with the same name but with different size I need to pick the field with the larger VARCHAR. How can I do that ?…
-
0
votes1
answer528
viewsCalculation in SELECT oracle
Good morning. I need to calculate between values that are stored in my BD, these values are marked with the + sign and - in their respective tables. I wonder if there is any way to make through a…
-
0
votes1
answer1960
viewsHow to call another Procedure or Function within the same Packge in oracle?
I have rods procedures and functions within the same package. How can I reference some within my PL-SQL code? PACKAGE: CAIXA1 PROCEDURE: CLOSE BOX, SUM TOTAL FUNCTION: TOTALGRADES How can I…
-
0
votes1
answer616
viewsIn pl-sql can I assign the SUM value to a variable?
In the system has a variable vsoma which shall receive the total sum of the column Values. How can I assign the sum value SELECT sum(valor) from PRODUTOS2?…
-
0
votes1
answer44
viewsWhy can’t I create a tablespace?
I’m trying to create a tablespace on oracle 11g but I can’t get it to point out the error that is in this image: I wanted to understand why I can’t create!…
-
0
votes1
answer53
viewsSearch using model
I would like to use my model to do research on Laravel. I wish that, if possible, one could explain to me: I have my model class minhaModel extends Model { protected $table = "minha_model"; public…
-
0
votes1
answer48
viewsChange automatic database field after a given time
Well I have a field in my table that is called status, I need to have my bank update this field automatically if the visitor does not leave the company after 18:00. Does anyone know how I start? I’m…
-
0
votes1
answer268
viewsHow to display two tables in Sqldeveloper at the same time?
I am unable to filter two tables at the same time in SQL Developer at the same time. When I insert two tables into the same filter sqldeveloper shows nothing!…
-
0
votes1
answer362
viewsFind text in sequence in a string
I have this String in oracle: 'Order linked with Sale : 4575987/10' and I would like to return only the order number in this case the 4575987/10. Until now the maximum I could is passing a fixed…
-
0
votes1
answer424
viewsORACLE/PLSQL auto increment
Nome Idade ID João 5 Lucas 5 João 2 Lucas 1 I would like to use a cursor to sort by names and by age and the ID field to be populated according to the sequence, for example: Nome Idade ID João 2 1…
-
0
votes1
answer253
viewsInner Join without duplicating lines, bring the first value found
I have the following table with the fields below SELECT NR_ANO_MES, nr_contract, type_product, NM_PRODUTO, sum(QT) the QT FROM INN.FT_VENDA The product type field has 3 classifications (Video, data,…
-
0
votes2
answers120
viewsRemove repetitions in select Oracle sequence
I have a question to mount a query on Oracle, I have the following so far... SELECT M5.NIVEL_ESTRUTURA , M5.GRUPO_ESTRUTURA , M5.SUBGRU_ESTRUTURA , M5.ITEM_ESTRUTURA , M5.SEQ_OPERACAO ,…
-
0
votes3
answers127
viewsSelect dates less than a given year
How can I create select to show only employees of a company who have been admitted to it before a certain year ? The type anoAdmissao is date ie: dd-mm-AA…
-
0
votes3
answers381
viewsHow to select the year in PLSQL?
I have a chart of company employees. Must show who completed a year of work at the company. The data type for the field Information: DATE (dd/mm/YY)…
-
0
votes1
answer298
viewsHow Popular Image in Gridview?
I’m doing an app on Asp.NET, with Entity Framework and using the database Oracle and here’s the thing I’m uploading the image by a button and saving in the database with the type BLOB until then all…
-
0
votes3
answers392
viewsHow do I find the first Tuesday of a month?! (SQL)
I’m performing the following exercise: The tables are as follows: : I already have the following code: SELECT NOME FROM CLIENTES C,VENDAS V, LIVROS L WHERE V.CODIGO_CLIENTE=C.CODIGO_CLIENTE AND…
-
0
votes2
answers114
viewsIf it doesn’t fit in the div, show: more x results
I need to solve the following problem: I have a div that displays a list of names that are loaded according to a query condition. This list of names varies a lot, sometimes appears 5, sometimes…
-
0
votes1
answer1658
viewsRemove the last value found inside a string
I need to take an average of payment conditions in the database and I came across the situation where the condition column is a string and it can receive parcel values separated by bar. I need to…
-
0
votes0
answers145
viewsUpdate on Cascade Oracle with composite primary key
create or replace TRIGGER cascade_update AFTER UPDATE OF project_name ON PROJECT FOR EACH ROW BEGIN UPDATE VEHICLE SET project_name = :new.project_name WHERE project_name = :old.project_name; UPDATE…
-
0
votes0
answers276
viewsStored Procedure input parameters with more than one value
I need to do a stored project in the oracle where I have 5 input parameters and 1 output parameter which will be a cursor(recordset). The problem is that each input parameter can receive more than…
-
0
votes1
answer111
viewsError in persistence.xml when connecting oracle database
I have this file to perform oracle database persistence. However do not connect! <?xml version="1.0" encoding="UTF-8"?> <persistence xmlns="http://java.sun.com/xml/ns/persistence"…
-
0
votes2
answers9821
viewsSelect to display the column name of a table?
Tables col1| col2| col3| ...| coln 1 | 2 | 3 | ...| n Display the name : col1 col2 col3 ... coln…
-
0
votes1
answer952
viewsFind Relationship between Oracle Tables
I wonder if it is possible to find the tables and fields involved in an oracle relationship, a query that would return a table like: Table_name, Column Name, Table_references Funcio,id_Cargo,Cargos…
-
0
votes1
answer138
viewsError After Running Error: No output displayed
Code CREATE OR REPLACE PROCEDURE buscaturma(cod NUMBER) AS nomeT varchar2(20); BEGIN IF (cod=0)then dbms_output.put_line('ZERO'); ELSE SELECT DS_TURMA into nomeT FROM TURMA WHERE CD_TURMA = cod;…
-
0
votes1
answer252
viewsSQL returning error when selecting non-existent field
It has a system that several companies use, but changes in bank tables are not informed. You could create a select that does not return an error by not finding a field recently removed from a table?…
-
0
votes1
answer214
viewsHow to run PROCEDURE and FUNCTION at the same time?
I have this plsql code and I must run at the same time: /*Testar se o codigo é valido*/ CREATE OR REPLACE FUNCTION TESTE1(cod number) RETURN BOOLEAN IS begin if(cod>0)then return true; end if;…