Most voted "mysql" questions
Mysql is a relational database management system (RDBMS) that functions as a server, and provides access to multiple users simultaneously. Your source code is available under the GNU General Public License.
Learn more…10,264 questions
Sort by count of
-
1
votes0
answers476
viewshow do I check if a text file is empty in php and if it is finished?
I have a code that executes a simple query like this select * from tabela where coluna1 = 'valor'; then I have a variable that brings a txt file $filename = "C:/Programfile/arquivo.txt"; and then I…
-
1
votes1
answer87
viewsButton that increases the limit of mysql_query
Hello guys I’m wanting that when I press in the div with the class "boot" the following line change: $albuns = mysql_query("SELECT * FROM albuns ORDER BY id DESC limit 4"); making the limit increase…
-
1
votes1
answer60
viewsProblems setting up Mysql on Windows
The Mysql Installer application is crashing in the setup part, just at the moment it creates the service, does anyone know the reason for this problem? Note: I am connected with a local user and…
-
1
votes0
answers118
viewsAccess to different department modules
I have a question about building a small project. A user has access to a department module, so far so good. My question is if the user needs to access another module of the same department. Login is…
-
1
votes1
answer2351
viewsFailed to install Mysql Server 5.x on Windows 10 (64bit)
Good night, I am trying to install Mysql Server 5.x (32 and 64bit) on Windows 10 (64bit), but in the middle of the installation the process is aborted with the following message: '...no version…
-
1
votes1
answer1866
viewsHow to disable mysql password validation with Zoneminder: ERROR 1819 (HY000)
I loaded the password validation plugin in Mysql 5.7 on Ubuntu Server 16.04 to leave the system with more protection, but it seems that this plugin forces all passwords to comply with certain rules…
-
1
votes1
answer1636
viewsHow to make a query per day, week, month period in Mysql
How do I query for period, day, week, month in Mysql? for example I would like to display data filtered by periods example display data yesterday, last week, two weeks, three weeks, a month ago and…
-
1
votes1
answer964
viewsI lost my script to recover?
After a blue screen, I lost my work in Workbench, but keep the schema. It has to recover or I will have to do the work again?
-
1
votes0
answers213
viewsEnable-Migrations error in EF5 with Mysql
I have a problem in my project, when trying to enable Migrations in the project it generates an exception as below: > System.IO.FileLoadException: Could not load file or assembly…
-
1
votes1
answer57
viewsPurchase of PHP image editing and information coming with POST
My code is not editing the information the way it is with the following error, Unknown column '$full name' in 'field list', and I am passing this value and all the others.. The Editing Form:…
-
1
votes1
answer124
viewsHow to capture code from a table generated via html?
I generated a table with data by HTML and PHP, how do I generate a string of this table with this data so I can play in my DOMPDF load_html?
-
1
votes1
answer337
viewsRandom order with Mysql paging
Hello, I need to sort randomly result of my query and display pagination using mysql. Ordering and paging are working perfectly. Always when paging is done, on account of the use of ORDER BY RAND();…
-
1
votes0
answers42
viewssend hashtags in different columns in mysql database
I would like to insert each word "hashtag" in a table column, I am using this example: <form name="formulario" method="post" enctype="multipart/form-data" action=""> <input name="hashtag`"…
-
1
votes1
answer628
viewsSave to database or generate new html page?
I’m doing a news portal. The administrator will feed the system through an administrative panel. To working with php and mysql. The question is: generate an html file for each new news? Or save…
-
1
votes2
answers83
viewsSet of WHERE , AND and OR conditions in SQL does not produce the expected result
I’m trying to get some records with a very simple syntax, but it’s not working. I’m doing something wrong and I’m not realizing it. Can someone lend a hand? I need to fetch all records from 2017…
-
1
votes2
answers160
viewsphp array converted to json does not maintain order in mysql
I have an array with the following format: $vetor = array( 1=>array( pt-BR => array( 'pergunta1' => 'pergunta 1 em texto' 'resposta1' => 'resposta 1 em texto' ) ) 3=>array( pt-BR…
-
1
votes2
answers2073
viewsError creating Mysql Relations using Wampserver
I built the entire database and now I’m trying to do the relations, when I click on the primary key (referential) and click on the foreign key, the following error appears: "Error: Relational…
-
1
votes2
answers1179
viewsMysql - Recursive query to get only parent categories
i have the following table category: id | desc_cat | parent_id 19 | Pessoais | (null) 20 | Cartao Credito | 19 21 | Academia | 19 22 | Residencia | (null) 23 | Agua | 22 24 | Luz | 22 25 | Aluguel |…
-
1
votes1
answer349
viewsReturn lower value of a SUM?
I have a SELECT with SUM and would like to understand how I do to return me the lowest sum of all value per supplier. SELECT distinct fornecedor, cliente, SUM(valor*qtd) AS TOTAL FROM orcamentos…
-
1
votes1
answer1580
viewsRecover database from . frm and . idb files
My backup got incomplete and corrupted my ibdata database, now my database does not access my tables. Keeps giving error! I don’t care about the data! But I really need the structure of the tables.…
-
1
votes0
answers565
viewsNodejs and Mysql authentication?
Does anyone know any article/tutorial/code that teaches you how to create a login system with session or cookies using Node.Js + Mysql?
-
1
votes1
answer82
viewsCapture last INSERT value
I am creating a news system where the user has the option to register the news and put the original link where the news was generated, so far so good, the problem is that I want the user to have the…
-
1
votes1
answer1551
viewsLaravel - List with list of tables (state/city=>person)
I have the following tables: contacts => id - name - state - city states => id - status - acronym cities => id - city - id_state And the following models: Php state. <?php namespace App;…
-
1
votes1
answer1192
viewsHow to select a column name in Mysql?
How to take the name of a column in Mysql even if it has no lines?
-
1
votes2
answers908
viewsINNER JOIN in the same table
SELECT Agendamento.E3TimeStamp AS Data,Agendamento.Lote, Produtos_values.name as NomeProduto, Produtos_ValueData.TemplateID AS mp_produto FROM produtos_values inner join produtos_valuedata on…
-
1
votes1
answer42
viewsGet all Rows from a query
Friends, I have a little problem: I need to take each of the Rows of a query with a loop. I saw a code in Stackoverflow, but it doesn’t work. Anyone who knows how to do it, please let me know.…
-
1
votes1
answer121
viewshow to use the SUM within an ORDER BY (mysql)
I have the following select in mysql: SELECT DISTINCT a.id, a.unidade, a.posicao, a.nome, a.peso FROM produtos a, produtos_pedidos b WHERE a.id = b.id_produto and b.id_pedido IN (13,12,11) ORDER BY…
mysqlasked 8 years, 6 months ago Hugo Borges 5,294 -
1
votes1
answer879
viewsCreate new instance in Mysql
I am trying to create a new instance of Mysql on a machine that already has it installed. I did the manual process of creating a new directory and setting up the file .ini, but when starting the…
-
1
votes1
answer7998
viewsERROR 1241 (21000): Operand should contain 1 column(s)
I have this select SELECT `works`.`grade_id` FROM `works` INNER JOIN `work_images` ON `work_images`.`work_id` = `works`.`id` INNER JOIN `work_students` ON `work_students`.`work_id` = `works`.`id`…
-
1
votes2
answers89
viewsDoubts with value of selects
I made that form with the selects doing direct search of the database and also sorting the data, but when sending the form answered value that goes into the <option> is not the value I want,…
-
1
votes1
answer674
viewsCreate user with access to Mysql Database views only
How to create a user that views only views from my Mysql database? I am using the following settings: Ubuntu Server 14.04.5 LTS Mysql: 5.5.55 Apache: 2.4.7 phpMyAdmin: 4.0.10…
mysqlasked 7 years, 4 months ago Ezequias Silva 63 -
1
votes4
answers103
viewsProblems formatting the date type returned from select
Good morning I would like you to help me with a small problem that I am trying to return from a select in php. I would like the return of my "Mes_ref" from my select to be only month and year…
-
1
votes1
answer42
viewsArray bringing different PHP results
I have my comic book, however, is bringing me a different result than what is in the bank $consulta = "select * FROM PRODUTO_pedido WHERE PEDIDO_PED_ID =12"; $resultado =…
-
1
votes2
answers54
viewsMysql - Multi Selects in a query
I need to get all columns of a table and more a custom column in the same query, I tried this way: SELECT (SELECT * FROM clans WHERE ID=1), (SELECT COUNT(*) FROM contas WHERE Clan=1) AS Membros; You…
-
1
votes1
answer233
viewsError in MSQLI Insert
I am switching from mysql_to mysqli, everything works(update and delete) more on Insert not saved.... where is the error? Insert archive: include("config/con_mysqli.php"); $sigla =…
-
1
votes2
answers2529
viewsRemove record in database without giving refresh
Buenas! I looked for some topics about the same doubt as mine - and I found, but I could not understand how to do... I have the following code snippet: $c = array(); $c = buscaUsuario($conexao);…
-
1
votes1
answer27
viewsPick up Remaining Records
It has a function in Laravel’s ORM that makes the LIMIT of Mysql. Which is the Take and the Skip. I’m going to do three Owl Sliders on the page, one under the other. And the images I’m going to put…
mysqlasked 8 years, 6 months ago Diego Souza 16,524 -
1
votes0
answers389
viewsError when connecting to Mysql database using C# application in Visual Studio
Hello, I created the registration form and at the time I will save the text box items in the database of the following error 'Host 'DESKTOP_R70LLO is not allowed to connect to this Mysql server'. By…
-
1
votes2
answers1874
viewsSeparate query by month and add the results
I have a database of requests that contain several requests for various dates, however I need to list a report by month and their respective sums in front. Example: The date field in the table is…
-
1
votes2
answers250
viewsSave data to various tables
I am making a registration system and would like a help from you to be able to save the data in several tables. My registration is composed by the following fields. Nome do Paciente Nome do Doutor…
-
1
votes0
answers46
viewsComparison of tables using the title to join with LIKE and CONCAT?
I’m creating a book exchange page, I made two tables of wishes and mine. until the part of the logged-in user wish to find other’s books I was able to do, but I would also like the other users to…
-
1
votes1
answer67
viewscount record based on variable
Hello I am trying to build a search in the Mysql record by two parameters; name and dates. For example, I need to do an execution in Php where I enter the name of who registered ( Box) and dates…
-
1
votes2
answers1168
viewsHow do I validate Cpf for my database values?
I have the code below, which accepts values in your inputs and then sends them to the database. I want that when the user clicks submit, if Cpf is invalid (EX:111.111.111-11), it does not send any…
-
1
votes0
answers249
viewsHow best to store an array in a single field in the database
Is usually used implode/explode or serialize/unserialize to store multiple information of a particular item in the database. Using PDO, which would be the best and whether there is another way to…
-
1
votes1
answer156
viewsRelationship of Tables - how to do
I’m having trouble figuring out how to relate to tables. My scenario is below: A parceiro may have several usuários, however a usuário may only be attached to one parceiro. A usuário can register…
-
1
votes1
answer182
viewsLaravel - Search if there is a relation in the many-to-many table
I need to search users according to some filter attributes. I have the table contacts: id | nome | email 1 | asd | [email protected] 2 |teste | [email protected] The table groups: id | grupo 1 | grupo1 2…
-
1
votes2
answers141
viewsHow to limit Ips that can remotely connect to mysql?
I have a centos 7 server with Mysql 5.6 installed, I can control the privileges of each user/host with GRANT.But my question is how to allow only a few Ips to connect to the bank. Currently any IP…
-
1
votes1
answer1578
viewsDelete record when a column date is reached
I have the tables: In anuncios got the spine expiracao which receives the amount of days that that notice is valid, I want each day that the database automatically decreases 1 in this column, a…
-
1
votes1
answer293
views1060 - Duplicate column name 'NULL' in a Mysql query
I am trying to execute this query, and it always gives me the following error: 1060 - Duplicate column name 'NULL' INSERT INTO ce_coins_issued (idc, idu, year, ltr, issuing, status) SELECT * FROM…
-
1
votes1
answer354
viewsError connecting to Mysql
I took an example of the internet to connect with Mysql private static final String USUARIO = "root"; private static final String SENHA = "123456"; private static final String URL =…