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
-
3
votes1
answer46
viewsDoubt about Select
Hello, I am doing a user/password verification in java and I need to perform a query in which check in the database there is a login and a password related to the typed in jTextFields. But I’m not…
-
3
votes1
answer1183
viewsMysql database connection issues
I am trying to create a system for college, but I have an error when trying to connect with Mysql, I am using PHP and Xampp. Error: Fatal error: Call to Undefined Function mysqli_conect() in C:…
-
3
votes1
answer124
viewsIs it possible to change a word from one string to another in the database via php?
I have been working on a method that will fetch all dates containing "2014" and replace that value with "2016" without changing the rest of the date. I’ve been able to return all columns containing…
-
3
votes1
answer474
viewsSending birthday emails based on Mysql query
I have to create a function (task) on the server of my site that sends a birthday email, containing an HTML code, to birthday emails. Detail: these birthdays are registered in a Mysql table that…
-
3
votes1
answer605
viewsWhat is the difference between long Lling and normal ajax?
I’m trying to understand more about long Polling to "manipulate" a site in real time, I’ve seen some videos and I’m thinking so far: Let’s say I have an old date that’s in sql and I do an echo on…
-
3
votes1
answer1219
viewsUpdate on Laravel 5 a field receiving the value of another field from the same table
I have a configuration table in my database that has the following fields: ["id", "texto", "textoOriginal"]. Initially the field values texto are equal to the field textoOriginal, but the user can…
-
3
votes2
answers2411
viewsUncompressed data with Internet JOIN using PDO
Hello I’m having problems when I’m returning a select made with some tables Inner Join as shown below: So I set up a Join Internet with my needs in my method: public function tableUsuarioUM() {…
-
3
votes1
answer1420
viewsIs it possible to synchronize a mysql server with a local Firebird database?
I’m new to web applications, and I have a Mysql DBMS-based website. What is the best way to synchronize the web bank with a local bank (the bank being on a fixed ip)? The local bank is Firebird.…
-
3
votes2
answers3255
viewsI need to return the null values of this Inner Join
I have this select mysql: SELECT credor.nome, banco.descricao FROM credor INNER JOIN banco ON (credor.banco = banco.codigo) He returns me all the creditors and their respective bank, but if the…
-
3
votes1
answer332
viewsFind the least-appearing numbers in the records
Personal greetings. I have a sort of table like this: reg num0 num1 num2 num3 num4 num4 1 4 2 5 8 10 15 2 3 7 8 15 20 21 3 14 10 6 21 17 1 4 1 4 8 10 16 7 5 9 3 2 1 8 15 I need to find out what the…
-
3
votes1
answer1780
viewsError in SQL query in PHP
I’m having difficulties with an SQL query in PHP, when I make a query I get the following error: Warning: mysqli_fetch_assoc() expects Parameter 1 to be mysqli_result, Boolean Given in C: xampp…
-
3
votes1
answer674
viewsHow to set default size of a PHP image
I wonder if there is any way to define the height, and the default width in php, I saw some forms, but I used an external class, I wonder if there is any way to use the GD library... $dest =…
-
3
votes2
answers792
viewsLimit number of Group By occurrences
I have to search in a table data of an advertiser, I need to group by the advertiser according to the most viewed, separated by the date. I wanted to limit the group by, has as? Example table: id…
-
3
votes1
answer657
viewsRun ECHO without interpreting HTML
I have a value in mysql database that contains some html commands like: <b>Olá</b> <br> Other... I need that when I show the value using <?php echo $row_rs['original']; ?>…
-
3
votes1
answer702
viewsTable/Field for product price in Magento
In which table/field are stored the prices of products registered in Magento 1.9? I saw on some sites the table catalog_product_entity_decimal, but I didn’t see the field price or any other value in…
-
3
votes2
answers369
viewsField allowing only an exact amount of data
How to put a field in mysql that only allows 4 characters. No more and no less? I’m doing like this: alter table cartoes add os_4_ultimos_digitos int (4); < But it takes a Constraint and I can’t…
mysqlasked 9 years ago André Nascimento 1,258 -
3
votes1
answer539
viewsChanging a field’s value in a select
Query: select id_cliente,nm_cliente,tp_sexo from tb_clientes; In my bank sex is registered as int I wish that when I make a select display Male or Female in place of 1 or 2, how do I do this?…
-
3
votes1
answer77
viewsUpdate with Join MYSQL
I have a table with customer data, with the 'broker name' and 'codbroker' fields. I need to update the codbroker from the data of my user table, where I have 'name' and 'codusuario'. So that it’s…
mysqlasked 9 years ago goldenleticia 543 -
3
votes0
answers113
viewslocalhost/phpmyadmin / error 1146
I have a problem accessing phpmyadmin. Follow the error ->…
-
3
votes2
answers2111
viewsHow do I connect a database to a JAVA application
I have an app Java and a database MySQL connected in this application on my machine. The application will be distributed to other machines on the same network, but I can’t connect the banco de dados…
-
3
votes2
answers46
viewsSelect of dates
I need to make a select that brings me occurrences that the initial date of a leave is less than 3 years from the date of an employee’s admission Follow below excerpt from my code. SELECT * FROM…
-
3
votes1
answer3161
viewsSynchronize Local Database from Remote Server on IONIC
Personal how to update a database in a mobile application every time the remote database is updated. For example I have an application in Ionic, and to get faster I use the database of contacts…
-
3
votes2
answers295
viewsSave bank value to same user
I have a page with a field for entries that are recorded in the database and when recording I assign a user ID randomly in this register. Thus: $name = $_POST['name']; $phone1 = $_POST['phone1'];…
-
3
votes1
answer201
viewsHow to group subtraction of equal fields in Mysql?
I need to make an appointment to return the current balance of the employee. Being that in my modeling I separate the debts and credits of the employee by the type fields 1 for credits and 2 for…
-
3
votes1
answer162
viewsAjax Address Search with PHP
I have a form with the client list. When selecting the customer, I want you to automatically fill in the address, number, neighborhood and city fields. I have Ajax, but I don’t know how to elaborate…
-
3
votes1
answer739
viewsHow to show the number of Mysql repetitions?
I have a bank in which are registered names and surname, I can group the results as follows: SELECT DISTINCT * FROM usuarios GROUP BY sobrenome So if you have 80 records repeated of the surname…
-
3
votes1
answer444
viewsFind objects in mysql
Good afternoon, I am using Workbeanch 6.3 and I need to search in the Mysql database if a particular Column exists and what its Table, I also need to know if a particular Column is used in a…
-
3
votes3
answers447
viewsDivide a date into two parts
I’m making a calendar using Mysql, html, JS and PHP. This calendar serves to book the ballroom here in the building. There may be two reservations on the same day, morning and afternoon that would…
-
3
votes2
answers224
viewsIs there a paid localhost server?
I searched the internet and found nothing related. I want to set up a localhost server, to test my applications. I have tested Xampp, Wampserver Easyphp and others... Is there a system that gets…
-
3
votes1
answer4727
viewsSelect the 3 highest values
I have a table that has the following data: id_indication, id_user,lg_client A user can indicate multiple clients (lg_client = 1), would like a select that searches for the 3 users that indicated…
-
3
votes1
answer419
viewsHow to select Count(*) with Python and mysql.Nector
The library I’m using is that one. That is the code: cur.execute("""SELECT COUNT(*) as total FROM tabela as t WHERE ... """, (v1, v2)) for (total) in cur: if total > 0: print('Existe') The…
-
3
votes2
answers1331
viewsCheck separator type in a CSV file
I rode a script for import of CSV with PHP but I’m having difficulty with checking the type of formatting CSV. I need to check if he’s separated by ,or ; or \t or : or |, but I’m not getting it.…
-
3
votes3
answers1372
viewsHow to not allow repeated INSERT by giving Reload on the page?
How can I not allow INSERT repeated if someone re-loads the page? Example: $libera = $_POST['libera']; if ($libera == "sim"){ $sql = mysql_query ("INSERT INTO…
-
3
votes1
answer394
viewsHow to always update by adding+1 to mysql
Hello, How do I update a mysql column by always inserting +1 with each new update? And how to take -1 from the same column ? I tried that: "UPDATE tb_comment SET good=+1 WHERE id=:idComment" Only…
mysqlasked 8 years, 10 months ago William Alvares 584 -
3
votes2
answers56
viewsRemove messages from one caller without affecting the other
I am implementing a messaging system and need to make a way to remove messages from one caller without affecting the other. So-and-so and Sicrano exchange messages: At a certain point, Fulano…
-
3
votes1
answer336
viewsMount SQL to generate a dataset and popular a Treeview
I have a database here and I want to mount an SQL to generate a dataset in Delphi and then popular a Treeview. The figure below shows part of the seat, but that is the general structure of it:…
-
3
votes2
answers513
viewsDatabase search with value of <select>
How to perform a search in the database, through a parameter informed by the tag select? Follow the code below: <select class="form-control" id="inputUnidade">…
-
3
votes2
answers50
viewsgenerate query dynamically with Union
$sql = 'SELECT COUNT(*) FROM '; $cola = ' UNION '; // Deixar os espaços em branco "em volta". $colaWhere = ' WHERE '; $first = true; $wheres = ""; foreach($arrayNomeBDs as $nomeBD){ $where = '…
-
3
votes1
answer1027
viewsCode First Migrations Mysql - Specify the '-Verbose' flag to view the SQL statements being Applied to the target database
I am creating a web application in C# and because of the hosting server, the database is in Mysql. Then I installed Mysql.Data.Entity, EF6, enabled Migrations, added the Migrations class, but when…
-
3
votes2
answers128
viewsCreate a register where the user increments a new checkbox to save a new information in Mysql
I need to create a client register, where certain part of the registration the user has several checkbox that would use to store if the client has such documents, for example: [] RG [X] CPF []…
-
3
votes2
answers7460
viewsHow to list table-specific data with PDO?
How to list data specific of a table, but using PDO? I’m starting to study and use PDO, however to some things that I am not able to find and that is well explained of how to read the data with a…
-
3
votes1
answer121
viewsExport to database
I load 3 Strings from a CMS. String Data da Noticia String Titulo da Noticia String Texto da Noticia Within a loop, create the query to insert with these 3 strings. I’m just having some problems.…
-
3
votes1
answer132
viewsServer cache
I have a system that holds more than 2000 clients and it keeps increasing, and every time they do a search, they call mysql with more than 20,000 items (and this number also continues to increase),…
-
3
votes2
answers10563
viewsFormat/mask CPF in Mysql or PDO
I have a field "Cpf" in my table. This field can be of type INT or VARCHAR, in case you need to change to solve my problem. In it there are only numerical values, without the dots and without hyphen…
-
3
votes1
answer2299
viewsHow to clear Mysql’s cache of queries?
How do I clear the cache of darlings, stored by Mysql? What is the command?
-
3
votes1
answer44
viewsShow delete link only if there are no child categories
I have a database with the following columns: |id|id_pai|nome_categoria| +--+------+--------------+ |01| 0 | Eletronicos | |--+------+--------------+ |02| 01 | Notebook | |--+------+--------------+…
-
3
votes2
answers3170
viewsIs it possible to store an Arraylist in a Java database?
In the case of Banco de Dados using Java, it is possible to store an object ArrayList in a Banco de Dados MySql? If yes, how can I store this type of data? And how can I recover it from the Data…
-
3
votes3
answers2223
viewsHow to group for weeks using sql?
I have the following problem . I have several requests , and I want to group them for weeks. I’ve seen several examples ,almost none helped me, I wonder if there is a function that when you put it…
-
3
votes2
answers160
viewsHow to avoid Multiple Inserts in the database
Ola would like to know how I can use php to avoid adding the same item to a database on a save page that adds the names of the subcategories if you update your browser. Since I cannot use in the…
-
3
votes2
answers1756
viewsReplication between Mysql and Sqlite (E vice versa)
I am developing a system that integrates a Mysql database with an Android application (through a webservice). I can already make connection, pass data, change them in the database through the App…