Questions tagged as 'mysql'

2
answers

Update div every X seconds

I need a function to recharge one every X seconds because the value of the BBDD can change. I have the following, but I do not update the value. What fails me? div: <div id="results">valor a cargar</div> The script: functio...
asked by 30.03.2018 / 21:30
1
answer

Value in particular within an array

I have a dilemma when printing a variable, you see, this is my query in SQL: SELECT MONTH(fecha_del_deposito) AS mes, SUM(importe) as monto FROM pago_cliente And it throws the following: Which happens to query in php: 'cantidadPa...
asked by 27.03.2018 / 20:04
3
answers

Get records sorted by date and limited to 1

I'm trying to do an SQL query that I do not know if it can be done, but my purpose is to obtain the records depending on the id's, sorting them by latest date and limiting them to 1 to initially only show a record and then in another view show a...
asked by 14.07.2017 / 07:37
1
answer

Problem with UNION ALL

I have a problem with a SQL statement that I do not use too much, in fact this is the first time I use it for practical purposes. I have two tables, one of questions and one of answers. The structures are these: questions: idpregunta / i...
asked by 16.11.2017 / 18:33
2
answers

Delete mysql log with php

What a good day! I'm working on a project and I see the need to delete files from a list, line by line, the detail is that for this to be effective, the record must also be removed from the database. Any suggestions on how to make that match wit...
asked by 16.08.2017 / 19:45
1
answer

Problem with select in datetime field

The definition of the intento table is: create table INTENTO ( ID_INTENTO int not null auto_increment, ID_U int, ESTADO varchar(50) not null, FECHA datetime not null,...
asked by 02.02.2017 / 08:12
1
answer

Change Date Format - PHP

How could I change the format of a date that I receive by POST : 24/01/2017 (dd / mm / yyyy) to this format 2017/01/24 (yyyy / mm / dd)? $fecha1= $_POST['fecha1']; The detail is that when I insert it in MySQL I change the for...
asked by 24.01.2017 / 20:46
2
answers

What reasons can there be for a MySQL server to crash? [closed]

I am working on a project for a company in my country about 5 months ago. In that time, there have been problems with the Mysql Database Engine services. Sometimes the DB is hidden or does not allow access to it. I would like to know your opinio...
asked by 31.03.2017 / 14:06
1
answer

Go through a JSON array and display certain PHP data

A JSON is answering the following: [ { emple_cedula: "7913", emple_nombre: "PEPITO", emple_apellido: "PEREZ", resultado: "60" }, { emple_cedula: "7913", emple_nombre: "PEPITO", emple_apellido: "PEREZ", resultado: "50" }, {...
asked by 20.04.2017 / 18:03
2
answers

only shows me the first record of my query

Hello friends I have a problem with my query, it turns out that I am making a query with related tables my table: inscription_projects I relate it to my table: inscription_students by means of the id of the inscription_projects table and that id...
asked by 08.12.2016 / 19:23