Questions tagged as 'sql'

2
answers

Condition called null data, from a subselect - transact sql

I need to see purchases that do not have a nombre_etapa associated with it. I leave the code: SELECT re.[compras] AS compras, ( SELECT e.[nombre] as nombre_etapa_e FROM [Control_Documental].[dbo].[Registro_Etapa_Documento] AS e ) as...
asked by 28.09.2017 / 03:55
0
answers

Slow CharIndex + very long string

Modify the question The question was, I have an SQL that takes more than 60s to return an answer. Something unthinkable for a search engine! I have found the reason: CharIndex Why is it slow? I have about 300 results to show (...
asked by 22.09.2017 / 09:42
1
answer

SQL Available Matters for a Career

Good evening friends, I have days killing me with an SQL that I do not know how to do, I tell you I am developing a system for the management of universities, and I am trapping in the list of available subjects. I have these tables: CREATE TAB...
asked by 24.09.2017 / 23:38
2
answers

Laravel 5: Foreign key constraint is incorrectly formed

I'm trying to create the following two tables with Laravel: Schema::create('orders', function (Blueprint $table) { $table->bigIncrements('id'); $table->primary('id'); $table->bigInteger('numPedido')->unsigned();...
asked by 21.09.2017 / 12:20
1
answer

Receive postgres table in java

I have the following function in postgresql: CREATE OR REPLACE FUNCTION public.sp_sel_categoria(IN _codigo integer) RETURNS TABLE(acat_cod smallint, acat_nombre character varying, acat_descrip character varying) AS $BODY$ BEGIN IF _codigo =-1...
asked by 19.09.2017 / 18:43
1
answer

How to do an update with where to a temporary table of type varibale?

This is my query I insert the entries, and I want to perform an update using the where     
asked by 21.09.2017 / 17:51
1
answer

Status: Failure: Failure to test: I / O error: The Network Adapter could not establish the connection

I just installed Oracle Database 12c Release 2 (12.2.0.1.0) on my pc with windows 10. The problem is that I can not create a connection from the Oracle SQL Developer and the message appears in red (see image). When testing the connectiv...
asked by 16.09.2017 / 06:19
0
answers

Take data for search

Good afternoon, I need your wisdom, I need to create a search for values (patent, year, type) of a vehicle, but also need to search for user data. How can this situation be done? Thank you in advance TABLE 'clientes' ( 'id_cliente' int(1...
asked by 13.09.2017 / 19:17
0
answers

Validate values from application .net mvc5 & bootsrap to sql?

I'm new to this. I am doing a login in .net mvc5 with bootstrap, I already made my connection with sql, I just want to know how to take the values that insert in "name" and "password" in sql when pressing the "login" button. <form role=...
asked by 27.09.2017 / 16:35
1
answer

How to remove percentage in sql server

this is my query porcentaje = isnull(( select sum(x.valor)*100/(select sum(ccc.Valor) from CuentasPorCobrar ccc) from CuentaCorriente x where x.Detalle like 'Pago%'...
asked by 28.09.2017 / 16:21