Questions tagged as 'mysql'

2
answers

Trigger to link multiple records

I have 3 tables: Usuarios (id, nome) Desafios (id, descricao) Usuarios_tem_desafios (id_usuario, id_desafio, status) The goal is to add a new user by filling in the Usuarios_tem_desafios table with the link between the added user an...
asked by 16.01.2018 / 13:02
1
answer

java.lang.ClassNotFoundException: Could not load requested class: com.mysql.jdbc.Driver

I have a Dynamic Web Project in Eclipse and I have been constantly receiving this error: java.lang.ClassNotFoundException: could not load requested class: com.mysql.jdbc.Driver. My persistence.xml file: <persistence-unit name="casos">...
asked by 24.01.2018 / 21:53
1
answer

Write textarea line break in database

I have <textarea class="form-control" id="informacoes" name="informacoes" rows="3" placeholder="descreva aqui..."></textarea> where the user can enter various information. Information is sent via ajax : function sal...
asked by 23.01.2018 / 12:01
1
answer

Presentation of data in the view with CodeIgniter

I'm trying to display the data coming from my database in View. I followed the various tutorials I found on the internet but none of them could answer me: /. Model public function get_titles() { $title = $this->db->get('TB_TITLE...
asked by 22.01.2018 / 18:55
1
answer

Failed to pass ownership of an entity as a parameter in MySqlCommand

I have the following code in my application: public Usuario checkLogin(Usuario entity) { //return Usuario userEntity = new Usuario(); connection = mysql.OpenConnection(); try { MySqlComm...
asked by 21.01.2018 / 23:14
1
answer

Problem with RAND in SQL

I'm using MySQL "5.6.38-log - MySQL Community Server (GPL)" I have a procedure that runs every second, and it has a validation with a RAND: WHERE t.auc_due_time < GREATEST(LEAST(TRUNCATE(12 * RAND(),0),12),2) The problem I am facing i...
asked by 28.11.2017 / 00:46
1
answer

How to avoid performance problems with tables that contain lots of data?

I'm developing a payroll system, in which there is a 'problem' in one of your tables. For, to control the discounts in the pay of each employee, I thought of creating a table with the name: Discounts that would have the fields, such as: id,...
asked by 28.11.2017 / 15:54
1
answer

Insert in MariaDB giving timeout

What reasons would it take for the simple insert described below to take so long that it even timeout the server? INSERT INTO wkvmk_postmeta (post_id, meta_key, meta_value) VALUES(904, '_order_key', '') Table structure: +------------+----...
asked by 28.11.2017 / 14:55
1
answer

Change PDF background according to bank data (PHP, MYSQL, FPDF)

I'm trying to customize my report in FPDF , it's a system that generates discount tickets, where they are printed in batches, for example batch of 50 units. Tickets on this lot will have the same profile where it can be 10%, 20% and 30% of...
asked by 28.11.2017 / 15:43
2
answers

How to search for something in 100% of MySQL database

Is there a MySQL query in which I can fetch all data from all tables in a database at one time? Equivalent to something like this: "SELECT todos_os_campos FROM todas_as_tabelas WHERE qualquer_campo = 'isso'"     
asked by 30.11.2017 / 12:36