Posts by Rafael Brito • 405 points
20 posts
-
0
votes1
answer20
viewsQ: NOT IN/EXISTS in more than one table in the same query
I have a table of employees and I need to extract from it a query of employees who are not registered in any of the positions (architect, landscaper and manager). The column COD of employee is the…
-
0
votes0
answers46
viewsQ: SELECT in a time period in a datetime column
I have the following column id datareg 1 2020-07-24 08:00:00 2 2020-07-24 08:30:00 3 2020-07-24 08:45:00 4 2020-07-24 09:00:00 5 2020-07-24 13:00:00 I need a query that returns the AMOUNT of records…
-
2
votes1
answer99
viewsA: Download web file for PHP function
Using Virgilio’s tip and using curl I was able to adapt my code that met all my needs, maybe serve to those who seek the same: <?php $url = "http://www.example.com/file.zip"; // URL of what you…
-
1
votes1
answer99
viewsQ: Download web file for PHP function
I am using PHP’s Ziparchive class to unzip files from my directory, but my file is updated weekly at the same web address. I tried to do it this way: <?php $zip = new ZipArchive; if…
-
2
votes2
answers47
viewsQ: Problem with SQL relational logic
Considering this scheme CREATE TABLE bra_ocorrencias ( estado varchar2(2), genero varchar2(1), ano number, nome varchar2(30), num_ocorrencia number ); I need to make a query that returns me the most…
-
2
votes4
answers19922
viewsQ: Limit the number of SQL query lines
I have the following Query SELECT estado, num_ocorrencia FROM bra_ocorrencias WHERE nome like 'João' ORDER BY num_ocorrencia DESC It returns me all the states with the most relevant occurrences…
-
0
votes1
answer288
viewsQ: How to make a change to "Cascade" using oracle
How can I change my table ID BANDAS_E_ARTISTAS and ensure that other foreign tables also change via PL/SQL? TABLE BANDAS_E_ARTISTAS ID NOME_ARTISTICO 01 RAÇA NEGRA 02 OS MENUDOS 03 KELLY KEY 04 LUIZ…
-
0
votes1
answer53
viewsQ: slideToggle(); for row in tables
$(document).ready(function(){ $("#flip").click(function(){ $("#panel").slideToggle("slow"); }); }); <div id="flip"><table><td>Maria</td></table></div> <div…
-
0
votes1
answer309
viewsQ: Sub-Tables in Bootstrap
I’m creating a conventional table, which when clicked on in the group name it shows a sub-table containing the same columns and refactoring the results: NORMAL STATE: GRUPOS QUANTIDADE | GA | | 1000…
-
0
votes1
answer37
viewsQ: Character Explosion in Oracle
I have the client base, and the client base: COD CLIENTE 128 JOAO 129 MARIA 130 DULCE NOTA 234.123.334.128.50 235.124.338.128.49 Note that the client code is inserted in the note number, which in…
-
4
votes1
answer11299
viewsQ: Cluster and Sum in Oracle
I have a customer record ID NOME GRUPO 2033 JOAO FORNECEDORES 2044 MARIA MANUTENCAO 2055 JOSE FORNECEDORES And I have a record of purchases made by each customer ID_CLIENTE VALOR_COMPRA 2033 4.000…
-
0
votes3
answers5873
viewsQ: Remove repeated lines in all aspects on Oracle
In a column REGISTER I have two lines repeated in all aspects: NOME ID EMAIL SEXO JOAO 1234 [email protected] M JOAO 1234 [email protected] M How to compare these two rows, check if all columns are…
-
1
votes1
answer45
viewsQ: Conversion of a Date to Character sub-query in Oracle
i have a sub-query returning dates this way: SELECT DISTINCT DT_EMISSAO_NF FROM DANFE ORDER BY DT_EMISSAO_NF DESC And, starting from this query, I need all dates returned to be converted to…
-
1
votes2
answers282
viewsQ: Regular Expressions in Oracle
'Select from CITIES tables only records with composite names separated by a single space' TABLE CIDADES ID CIDADE 01 SAO PAULO 02 RIO DE JANEIRO 03 SAO CARLOS 04 TAUBATÉ 05 SÃO JOSÉ DO RIO PRETO The…
-
0
votes1
answer202
viewsQ: ORACLE RANK() function
Could someone explain me what is wrong with my syntax/use of the RANK function? Problem situation: "Rank songs by band so that songs of higher duration occupy the first places. Present band name and…
-
4
votes4
answers6919
viewsQ: SELECT of month/year in DATES
I need select to return all the rows that were inserted in July 2010, as shown in the example, regardless of the day. How to return this query? SELECT * FROM FRCAST WHERE DATA_ID =…
-
2
votes3
answers213
viewsQ: Function explodes() into a vector
I get a variable that way: $VAR = "joao.silva/jose.ferreira/maria.jose/carlos.eduardo/"; and I need to store it this way: $VET = array('joao.silva', 'jose.ferreira', 'maria.jose', 'carlos.eduardo');…
phpasked Rafael Brito 405 -
0
votes0
answers36
viewsQ: SQL DATE EXECUTION - ODBC
I am doubtful in the date format that ODBC performs. I tried every way and nothing. This Query performs normal if I insert only the code, but when I want to enter dates it does not execute. I…
-
3
votes3
answers52
viewsQ: Character manipulation in PHP
Example, we receive a login this way joao.silvestre And I want to take the string with the following rule: The first letter of the name + the 7 letters that comes after the point that separates the…
phpasked Rafael Brito 405 -
3
votes1
answer189
viewsQ: ODBC PHP / Oracle - UPDATE, INSERT, DELETE
I’m in a project using PHP and Oracle. the connection is OK, with this code I can run all the selects I need normally, what I can’t run are INSERTS, UPDATES and DELETE. Would anyone know why?…