Questions tagged as 'phpmyadmin'

4
answers

Count number of records in a MySql table with PHP?

People, I have a database with a table called "users", and I would like to know how I can, through PHP, count how many records there are in this table, and then give an echo to show this amount on the page. Please help me !!     
asked by 02.06.2018 / 17:22
1
answer

Trigger with sum between dates

Good Night, I need help that I can not get, I have two tables in my db. 1 - Portfolio table composed of: CREATE TABLE 'carteira' ( 'id' int(11) NOT NULL, 'datat' datetime DEFAULT NULL, 'vl_cliente' decimal(10,2) DEFAULT NULL )...
asked by 12.05.2018 / 01:01
1
answer

Mysql return JSON

I'm trying to make this example but it's giving the error: # 1582 - Incorrect parameter count in the call to native function 'JSON_OBJECT' SELECT JSON_OBJECT('City', Name, 'Dist', District, 'Pop', Population) FROM City; sql example returni...
asked by 21.02.2018 / 13:01
1
answer

Problem syntax MySql generating by PhpMyAdmin

I have a problem when MyAdmin generates a table creation script. The Script: CREATE TABLE 'crud_ABC'.'cliente_ABC' ( 'id' INT(10) NOT NULL AUTO_INCREMENT , 'nome' VARCHAR(300) NOT NULL , 'valor' DOUBLE(20) NOT NULL , 'descricao' TINYTEXT...
asked by 03.04.2018 / 00:27
2
answers

PHP / MySQL - Move from localhost to an online hosting

I created a website with PHP and a MySQL database using XAMPP. Now I would like to have the site online on a host, do I have to change the connection to the database where it says localhost? What procedures do I have to do?     
asked by 26.11.2017 / 14:16
1
answer

Mysql error - phpmyadmin: Access denied!

I have this problem with phpmyadmin, it was working normally, but when I typed: "mysql" in the linux shell it did not open mysql, just when it was typed: mysql -h 127.0.0.1 -P-3306 -u root. / p> Then I saw some articles and modified or deleted...
asked by 14.09.2017 / 04:08
1
answer

How to update a different table with a data from another table in PDO

Personal I have a payroll table, and I have an indemnification code for each transaction, when receiving the data of the update, I want to get the data and insert in update in another table of the bank being that 1 of the fields does not have in...
asked by 26.06.2017 / 20:46
2
answers

Translate mysql_query to PDO "UPDATE * SET ... WHERE ..."

Hello, I recently started translating my sites to PDO for obvious reasons. However this is giving me a bit of a headache. $sql = mysql_connect("localhost", "user", "pass") or die(mysql_error()); mysql_select_db("banco") or die(mysql_error());...
asked by 14.06.2017 / 15:21
1
answer

Data being multiplied in the table

I have a recipe book and in this register has a button that clones the fields "quantity of ingredients" and "combo box of ingredients". If I add only a quantity and ingredient, the registration is saved correctly. But the same does not happen wi...
asked by 18.06.2017 / 04:34
1
answer

404 not found - phpmyadmin / Ubuntu

I'm using Ubuntu and I installed LAMP properly. I open PHP applications in localhost quietly, but when I try to access localhost/phpmyadmin it shows me a erro 404 Not Found . I have seen several tutorials that use a...
asked by 09.05.2017 / 02:23