Questions tagged as 'oracle'

1
answer

How to guarantee transactional atomicity in more than one concurrent Thread in a Java SE environment using the Spring framework?

A Java SE solution, using the Spring framework, is being developed to parallelize the execution of a Stored Procedure in Oracle 9i, which takes as parameter one or more rows from a giant file to be processed. This will be done through a Threa...
asked by 17.04.2014 / 18:14
2
answers

Function equivalent to "DISTINCT ON" in Oracle DB?

In Postgres, you can have distinct apply to just 1 field of the select using DISTINC ON , how can I reproduce this function in an Oracle database? Here is an example query: SELECT DISTINCT ON (CITY) CITY, STATE, ZIPCODE, ROW_ID FROM d...
asked by 23.12.2014 / 20:19
2
answers

How Parallel hint works

One of the first things I see a galley suggesting to increase the performance of a query in Oracle is the use of hint Parallel . What are the benefits / risks that the use of this hint can bring, can I have problems with compe...
asked by 11.07.2017 / 15:46
1
answer

How to create a JOB in Oracle?

I have the following command to perform the analysis of Oracle indexes: EXEC DBMS_STATS.GATHER_SCHEMA_STATS('USUARIO', estimate_percent=> 25); I would like to know how to schedule this command so that it runs once every week. Edited:...
asked by 11.12.2013 / 21:20
1
answer

How to list every day between two dates for more than one record (Oracle)

I applied an orientation of another topic and it worked cool when you only have one record in the table with the range, but I had problems when the same record has more than one date range. Using the query below: select trunc(to_date(X.DT_E...
asked by 17.05.2018 / 12:09
1
answer

Generate header when exporting data to excel

I did an export routine for excel , using StreamWriter , but it gives me a problem. I can not get the name of the columns that come in the select. For me to do the header, I had to put it in the hand. This would not be the problem, t...
asked by 12.01.2016 / 11:21
4
answers

Subtract two TIMESTAMP and receive the value in minutes in Oracle

How to subtrair two fields TIMESTAMP and receive the value in minutos in oracle ? DATAFIM - DATAINICIO = 2880 minutos (ou dois dias)     
asked by 29.04.2014 / 15:10
1
answer

When to use a unique constraints vs unique indices in Oracle?

Is there some kind of good practice and / or recommendation when creating unique indexes vs. constraints in Oracle? When should I use one and when should I use the other? Is there a situation where I should use both? ALTER TABLE t ADD...
asked by 17.12.2013 / 11:44
7
answers

How to use multiple SQL statements (in the delete case in ORACLE) on a single line in C #?

I made a command because of foreign keys, just to plug hole, but it is not working because of an invalid character error, I believe it is ";" . I know I'm doing this the wrong way, so I accept suggestions for a more appropriate code. At...
asked by 05.02.2014 / 14:11
1
answer

Is it possible to use timestamp without having to convert to String in Oracle?

I have a query that one of your filters is a date, is it possible to filter in Oracle with something like this? SELECT * FROM tabela WHERE campoData = '2014-02-10 15:56:00.000' Or do we always have to convert to String as below? SELECT *...
asked by 10.02.2014 / 18:57