Questions tagged as 'sql'

1
answer

Why my procedure is not being accepted, I am using mysql6.3

create procedure cadastrar_nadador (out nome_v varchar(80),out sexo_v varchar(1),out nascimento_v date,out patrocinio_v varchar(80)) begin insert into nadador(nome,sexo,nascimento,patrocinio) values (nome_v,sexo_v,nascimento_v...
asked by 18.11.2017 / 21:53
1
answer

Query all sql tables

Good evening I'm starting in the career of developer and I'm creating an application that le an xml file. I'm having trouble passing a command in sql database that returns all tables and their attributes (column and values). Thank you    ...
asked by 07.11.2017 / 22:54
1
answer

Query on sql server with different value depending on some variables

Good afternoon I have the following query: select distinct(T.Grupo) 'Grupo', MAX(G.Descricao) 'Grupo', sum(E.QtdCat*S.FactConvEst) 'M2 cativos' from EncLin as E INNER JOIN Stock as s on s.CodProd=e.CodProd inner join terceiros as t on t.tercei...
asked by 07.11.2017 / 18:23
0
answers

Indentation and line break in data from sql to html

In summary, I created a table with type text in sql so that the user could save some content. But by pulling it back into the HTML formatting is lost. To heal this I thought about using the < pre > tag, but the < pre > it fills up...
asked by 08.11.2017 / 18:35
2
answers

Save Image to Database with C #

Hello I've seen the example Upload image for picturebox and write to the database but I did not understand that part: FileStream Stream = new FileStream(imgLocation, FileMode.Open, FileAccess.Read); What would this imgLocation be? I...
asked by 28.11.2017 / 17:58
1
answer

Select Group with PHP

I'm trying to feed a select group with bank data, but it's not working. Can anyone see the error? <div class="form-group"> <select class="" name="agencia" tabindex="-1" style="height: 30px;" required="">...
asked by 31.10.2017 / 13:26
2
answers

PDO - Which is better: columnCount or rowCount? [closed]

I'm new to PDO (I was forced to choose between mysqli and pdo after migrating php from version 5.2 to 7.0) and I made a system where the user searches: $b2 = $_POST['b2']; $busca = $PDO->query("SELECT * FROM noticias WHERE titulo LIKE '%$b2...
asked by 20.11.2017 / 01:11
1
answer

Joining arrays where they have a certain field equal

How do I join multiple arrays in an array when they have the same fields? Ihavethisfollowingarraybeingreturned,Iwouldliketogroupthemintoasinglearraywheretheyhavethesamevalueforthequery_id,forexample:inthefirst3arraythathasthequery_id=1,theyg...
asked by 19.11.2017 / 14:03
1
answer

Delete a record from the database when the deadline expires

How can I automatically delete a record from the MYSQL database when it reaches a deadline? remembering I'm using a date_termino attribute of type Date     
asked by 20.11.2017 / 19:00
1
answer

Help - Logical Formulation - SQL, PHP, HTML [duplicate]

I have a table in the bank with a team register, where each line corresponds to an employee and his respective team. For example, employee_id, employee 1, Mario 1, Sérgio 2, John 2, Joseph I want to bring the data on the scre...
asked by 06.11.2017 / 19:51