Questions tagged as 'mysql'

1
answer

Subtract Dates MYSQL

I want to delete users with the same name from the table, but only those that are different from the date of the database and the current date (at the time of the select) are less than 5 minutes. The structure of my database is: Login | Nom...
asked by 30.05.2015 / 17:47
1
answer

Problem reading properties file

I created a propertie file for the bank to read this file from there but the console gives me the following error: Erronull\properties\conexao.propertie (O sistema não pode encontrar o caminho especificado) Erronull\properties\conexao.properti...
asked by 08.06.2015 / 14:28
1
answer

Mysql error 1215: Unable to add foreign key constraint

How do I resolve this error? I know that one reason for this is that the columns must have the same size and specification. But I've tried everything and it's not working. CREATE DATABASE'sistema'/*!40100DEFAULT CHARACTER SET utf8*/...
asked by 07.06.2015 / 17:37
1
answer

How to change link of my page with htaccess

My normal url is: http://localhost/paginas/noticias.php?id=1 I wanted it this way: http://localhost/paginas/noticias/1 The id 1 is generated by php, I do not know how to make it look like this in htaccess.     
asked by 24.07.2015 / 00:17
1
answer

The form does not send data to the bank

I've created a discussion topic registration form. Discussion topics are linked to a foreign key category. So if I click on a category a list of topics appears. What I want is to be able to register a topic linked to a category with a form on th...
asked by 26.05.2015 / 21:50
2
answers

Login system (error when banned)

I have a login system and wanted to see ERROR if the user is banned. The SQL name in the table is "ban", if "ban" is equal to "0" the user will not be banned, and if "ban" is equal to "1" the user will be banned and will not be able to log in....
asked by 24.07.2015 / 13:25
1
answer

Error insert PHP [duplicate]

I'm having a problem inserting data into the database, already checked if there is any field where it is not accepting null value, but everything is ok, when the error appears the following code is given:    Array ([type] => 8192 [message]...
asked by 27.07.2015 / 18:11
1
answer

Problem with PHP and MySQL

I'm doing a chat using PHP and MySQL, and I'm having problems. I think it has to do with the fact that php 5.5 does not accept mysql anymore, (now you need to use mysqli) Well, I have two files: index.php <html> <head&g...
asked by 07.07.2015 / 22:45
1
answer

Access design to MySql database [closed]

I've been investigating good implementations that allow easy adaptability to my db connection. I would like to receive feed backs and suggestions about improvements to this design. For example: how would you implement more than one database in...
asked by 09.07.2015 / 12:47
2
answers

How do I get the file path and insert it into a table?

I need to create a MySQL statement that takes all the file paths of the files in a specific folder and inserts them into a MySQL table. For example, if my folder is called PastaTeste , I need to have something in my table like this: C:\P...
asked by 05.05.2015 / 15:30