Questions tagged as 'mysql'

1
answer

How to browse and compare two arrays in PHP

I have two arrays that return a MySQL query. I need to compare these two results so that, each time they are different, they print something on the screen. The problem is that the query that comes back from the database is an array with several...
asked by 21.11.2014 / 02:16
2
answers

Determine article rank based on views of all articles

The idea is to determine the reputation of a given article based on views of all existing articles. An article can have a reputation of 1 to 5 stars, and it is constantly changing based on the views registered for all articles. The goal is...
asked by 02.12.2014 / 19:54
1
answer

Error making multiple insert

I have a form that generates multiple fields for adding data, and then sends all data using for , thus making multiple insert in MYSQL. However, I have a problem. Let's say I generate 30 forms, of this total is only sending 20, a...
asked by 26.07.2015 / 19:07
1
answer

Export table to file using PHP

I would like to know if it is possible for me to export a table from the mysql database in PHP so that I can save the script to create this table in a variable. Same as PHPmyadmin, export the table to an sql file.     
asked by 25.09.2015 / 02:48
1
answer

How to sort and filter queries between two tables?

I have two tables, one of posts and one of friends. In my script there is a feed area where I would like to display the latest posts from the logged-in user's friends. But instead of bringing the last posts in order, the result sorts the...
asked by 13.02.2015 / 05:56
2
answers

Use LIMIT together with LEFT JOIN in more than one table

I have a anuncios table, in which I want to list the anuncios of the user together with the imagens , I'm trying with the query below, but if I have 5 imagens registered in anuncio , in the table it will d...
asked by 20.02.2015 / 04:02
1
answer

Read the PHP data in Javascript

I'm a beginner programmer both in PHP and Javascript and I'm having a question about a project I'm developing. I have a server connected to a PHP file and I'm requesting the following fields $FLD="idfca, solfca"; I created a function ins...
asked by 20.02.2015 / 14:43
1
answer

Group by equality

I need to group the result when there are equal records, regardless of order, whenever the same colors are chosen - group colors and users together. I need to produce an output like the one below: 0 => array( 'cores' => 'azul, verde' , '...
asked by 13.02.2015 / 00:38
1
answer

Password - Binary Modular Crypt Format

I find myself at this point reducing the size of a database and several techniques are used. However I have a question about the decision to make at one point and I would like someone to help me. In the model in question and in the user table...
asked by 16.09.2014 / 15:41
1
answer

Get variable on another page

After searching the data in mysql with php and displaying them on the page, I would like to know how to get the same results from this page where it is displayed and display them on another page. <?php //Cria a variavel telefone enviada...
asked by 05.03.2015 / 04:25