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
votes2
answers512
viewsCheck empty fields with foreach
I have a form system where the fields are generated by the base date through select. The same is done with foreach, how can I search the base date for the required fields and see if they have been…
-
1
votes1
answer5981
viewsHow to Update mysqli Database Table with UPDATE?
I am creating a data listing system, and created a data change page, with 6 fields, name, experience, email, phone, city and biography. only that my function does not update the fields. The data…
-
1
votes1
answer67
viewsHELP - I can’t identify error - PHP and SQL
Hello, I am trying to bring in a table the grouping of all stages and item evaluation per year along with the average scores and weights. I can only bring the last step and item p table, IE, is not…
-
1
votes2
answers215
viewsError in php if, login authentication system
Hello, then, I’m trying to make a simple login system with php and mysql, but it’s giving error in my if. I’ve moved... too much and nothing, when it seems right it does not authenticate you put any…
-
1
votes1
answer26
viewstable is not created in mysql
create database mbsys default character set utf8 default collate utf8_german2_ci; ''this generates normal'' create table PESSOA ( ID_PESSOA int (10) not null, NOME varchar (40) not null, CPF int…
-
1
votes1
answer169
viewsHow to insert values into a select when inserting them into the bank
I need to enter data into the database, I’m taking data from an old database, I had some attributes that have a certain value, I created these attributes on the site so I can receive the data…
-
1
votes1
answer515
viewsSelect com when e case
I have the following select query: select F.nu_ine INE, to_char(D.dt_ficha, 'YYYYMM') as CMP, I.co_cbo_2002 CBO, CASE WHEN (B.tp_atend = 1 or B.tp_atend = 2 or B.tp_atend = 5) and I.co_cbo_2002 !=…
-
1
votes1
answer114
viewsError trying to insert data into Mysql database
I’m trying to input a promotion into the database Mysql through a Web Service REST in Java, but when trying to insert me returns the following error: Grave: ERRO ao Inserir Promocao -…
-
1
votes1
answer151
viewsConcatenate what is equal and separate what is different with MYSQL/PHP
Well, I think it’s gonna get a little messy maybe, but I need to do this: In an example table I am inserting several names in the name column, in which many of these names are equal, I would like to…
-
1
votes1
answer1147
viewsSELECT in a parent table where ALL children are in the same situation - Mariadb/Mysql
I need to select in a parent table, where all children in that table NEED to be in the same situation. For example: In the parent table I have the following fields: pai_id, pai_nome In the table son…
-
1
votes0
answers49
viewsMysql Procedure query error
Because only the stmt2 doesn’t work? DELIMITER $$ CREATE PROCEDURE abc_produtos_total_geral( OUT v_total_geral decimal(14,2), IN v_dt_inicial date, IN v_dt_final date, IN v_table_name varchar(40),…
-
1
votes1
answer23
viewsError in Phpmalier class
I would like your help! Have the following class to send emails in php: <?php // Import PHPMailer classes into the global namespace // These must be at the top of your script, not inside a…
-
1
votes1
answer107
viewsHow to save to type Numeric in Mysql
Hello, I am using to save the price of a product in MYSQL the type Numeric(9,2) but in my system I am using Double and when printing it appears R $ 2.2 instead of R $ 2.20 what kind of data could…
-
1
votes1
answer61
viewsHelp with a mysql query
personal to breaking the head here with a query I assembled where I pick up the dates informed in the form and search in the database. it makes the query only that it does not bring all the data If…
-
1
votes2
answers76
viewsProblem in consultation with Join
I’m having a little problem with the consultation to generate a report. I made a JOIN of the orders table (that will take the report) with the table of customers and products. Until then everything…
-
1
votes0
answers45
viewsSearch MYSQL with PHP and JSON
I have a table in mysql database that has a field genre with that amount: [{"id": 2, "genre_name": "action"}, {"id": 1, "genre_name": "comedy"}] and would like to display all lines containing the…
-
1
votes1
answer121
viewsNullpointerexception in database connection
Anyway, I’m getting one nullpointerException just that I have no idea how to deal with it, I took a look on the net about and apparently the problem is in uninitiated variables and things like that,…
-
1
votes1
answer289
viewsHow do I show an image that is in the database using jsp?
Well, here’s the thing. I’m using JSP, SERVLET and Mysql to insert images into my project, it turns out I just keep the image path in the database, and then call this path to show the image. Then…
-
1
votes1
answer40
viewsReturn "Alert" if an IF is not executed
How can I check whether an if was executed or not, and whether it was not it to display an Alert? Take the example: if ($newtime!=0) { $qryupd = "update registration set dados=" . $dadosnew . "…
-
1
votes2
answers156
viewsSelect in the database using "like"
I am trying to make a select in mysql database, but would like to use the like, that should receive the value of a java variable. How can I do this interaction? public void…
-
1
votes2
answers95
viewsDifficulty to rescue information from AFFILIATE given a PRODUCT, many relationship to many
I recently started my studies in the area and I have a difficulty in the code. I need to display the data as follows: Product code Product class Product description Name of the subsidiary holding…
-
1
votes1
answer152
viewsQuery in Mysql when there are two ids
I have a table in Mysql that records link information from a PABX IP. It always stores the connection with a uniqueid own. But I noticed that time in IVR is also stored in the same table with the…
-
1
votes1
answer253
viewsUpdate database
So I have a modal that shows the data of the number that was searched, I want that when clicking the button edit of the modal release the inputs: work, rca and region to be able to write inside…
-
1
votes3
answers4262
viewsHow do I get the difference between dates on business days in Mysql?
I would like to know if it is possible to calculate the difference between 2 dates by counting working days. In that reply there is even a solution, but from what I saw, the check is only for…
mysqlasked 6 years, 12 months ago celsomtrindade 8,038 -
1
votes1
answer142
viewsInsert in Mariadb giving timeout
What are the reasons that the simple Insert described below would take so long that it even gives timeout on the server? INSERT INTO wkvmk_postmeta (post_id, meta_key, meta_value) VALUES(904,…
-
1
votes1
answer198
viewsChange PDF background according to database data (PHP, MYSQL, FPDF)
I’m trying to personalize my report on FPDF, It is a system that generates discount tickets, where they are printed in batches, for example batch 50 units. Tickets in this batch will have the same…
-
1
votes1
answer242
viewsError at agupar Mysql subquery
I have a select to display 4 fields, but a field that is the valor_pago is from another table, but I cannot use JOIN otherwise the return of the records conflicts So I created a Subquery but my…
-
1
votes3
answers886
viewsLoad Datagridview with Mysql
I have the following problem to display the data in a pulling gridView of Mysql database public string CarregarAluno() { string retorno = ""; string sql = "select * from alunos"; MySqlConnection…
-
1
votes2
answers512
viewsUpdate modal database
I made a code that updates the data entered by the user in the database, however, it is giving the message that the data has been updated, but does not update anything. The system works as a search.…
-
1
votes1
answer291
viewsCalculation function with dynamic cursor
I am trying to create a database function that when receiving a parameter value that contains a certain value it creates a cursor with the specific table. Follows DELIMITER $$ drop function if…
mysqlasked 6 years, 12 months ago Don't Panic 4,006 -
1
votes2
answers97
viewsHow to use pseudo names with CONCAT and Mysql?
A question about Mysql asks the result to exit in this answer format. When finishing my solution through a consultation made on Mysql, find the following problem. Below is a first example solution…
-
1
votes1
answer106
viewsHow to do "When selecting an option in dropdwn, it loads other database data into a Textarea" in php, mysql and Jquery
I have a form that has a select field name="nome_cliente" retrieving all registered clients from the mysql database. in this same form I have several inputs that will be registered to that selected…
-
1
votes1
answer435
viewsSave file to Mysql database using ajax and php function
I need to save files that I can already select in a modal using a js function. Below follows the modal html <div class="modal fade" id="modal_arquivo"> <div class="modal-dialog"> <div…
-
1
votes0
answers223
viewshow to connect VM with mysql on another VM with PHP/Apache?
Good evening, people. I am developing a php/mysql system to improve my knowledge in the area. Knowing this, I now need to simulate a server, doing the following steps: 1° Create three virtual…
-
1
votes1
answer77
viewsInsert Mysql query value in a comma-separated array
I am trying to insert a result of a query made on MySql in a comma-separated array, but I’m having trouble doing so. I have this appointment: SELECT `gasUsuarioUnicoopSis`.IdUnicoop FROM…
-
1
votes2
answers132
viewsConditions in the SQL
Hi, I have a question in SQL. In the company system there are several registered products, and these products have different sales unit, that is, some are sold by Package, Box, Unit and etc... Every…
-
1
votes1
answer194
viewsHow to add value to an input when pressing a link with jquery?
I’m having the following problem: I’m not getting to set the value in one input when he’s inside a function. Example: $(document).on('click',".edita_cliente", function(){ var id = $(".seq").val();…
-
1
votes1
answer459
viewsUpdate table with the highest value from another table in Mysql
I have a table called employees, with the following fields and values: nome salário a 10 b 100 c 30 d 40 I have a second table called function_more_caro, with the same fields as the previous one,…
-
1
votes0
answers51
viewsTruncating data when entering into the database
The system is on a common host with the following config: Apache 2.4.25 PHP 5.4.45 Mysql 5.5.58-cll It is intended for O.S. control and each user has a login with his password. During the…
-
1
votes1
answer43
viewsUser with own page
I’m making a portal, and to register need Cpf and email. Then I send a confirmation email, it clicks on the link and its situation in my comic changes. So the user can access the portal. It will…
-
1
votes1
answer632
viewsHow to make a ranking with SQL?
Well, I have a "voting uniform" table that receives in the columns "voto_uniforme1", "voto_uniforme2" and "voto_uniforme3" a value of type "BOOLEAN", where 1 means that the person voted in this…
mysqlasked 6 years, 11 months ago Lone Tonberry 525 -
1
votes1
answer55
viewsSummation in SQL
I need to make a report with SQL, that asks me the following situation. In the general report, I need it to stay that way: Produto Quantidade Total Valor total Salpicão 30kgs 810,00 The detail is,…
-
1
votes1
answer98
viewsGet INT as INT and not as string - Codeigniter - Ajax
I have the following tabela, controller and model, I want to get what it is int as int, and not string. Note that when the item is recovered, the field int is in quotes. How do I recover the data…
-
1
votes2
answers58
viewsPHP Search error
I do the search with the existing numMec and appears to me that does not exist in the database <?php if(isset($_POST['search'])){ $searchq = $_POST['search']; $searchq =…
-
1
votes1
answer88
viewsTake data from a column in Mysql via POST and put into a Textview
How can I take data from a column and put it in a Textview? ? I tried this way: private static final String REGISTER_URL="http://localhost/teste.php"; private void register(String nome){ String…
-
1
votes1
answer131
viewsmysql PHP problem when using trema
I need to develop a script that checks for an accented character with trema in the string and saves a string variable without the trema. The script I list below compiles //Checa Especial…
-
1
votes1
answer347
viewsWhich database connection is best?
I started working and am updating the company system, it currently uses this connection: $link = mysqli_connect("0.0.0.0", "teste", "teste", "teste"); mysqli_set_charset($link, "utf8"); if…
-
1
votes2
answers578
viewsReceive POST ID and play to Location via GET
I need to get the ID of the entity that has just been registered. Only it will be played to another screen, to be registered other information. I would like to know how I can get the entity ID when…
-
1
votes0
answers240
viewsMysql Codeigniter Parcel System
I need a system that registers multiple installments of title in my Mysql BD I have this code below that registers and repeats the Insert according to installments Qtde informed, but it happens that…
-
1
votes0
answers266
viewsAvoid SQL Injection Login Form
Good morning, everyone, I’m new to anti-sql security Injection. I always learned only to validate the inputs and then use them in the query, always with mysqli_query and mysqli_fetch_array. I have…