Questions tagged as 'mysql'

1
answer

Query to join specific tables

I need to join 3 different tables. But the result I want is: When the reference exists it should join, when it does not exist it should show blank or NULL. My structure: Contact table +------+------------+ | ID | Nome | +------...
asked by 25.07.2016 / 20:12
2
answers

Error Trying to get property ... PHP + Error og: image API Facebook (Share)

I have other examples here but none worked for me I have an instruction to pull an image from the database, but it is giving the error    "Notice: Trying to get property of non-object in ..."; $q= $db->Select("produto", "nome, imagem...
asked by 04.07.2018 / 18:47
1
answer

Call to undefined method PDO :: bindParam (), how do I resolve it?

So, guys, I'm starting OO studies and I decided to take a look at PDO, but it's not going to happen, please help me: class Cliente { private $nome; private $email; private $telefone; protected $cpf; protected $senha; pri...
asked by 08.12.2016 / 01:05
1
answer

Parse error: syntax error, unexpected '=' [closed]

I'm building a connection to the database, but I get this error: Parse error: syntax error, unexpected '=' in C: \ wamp64 \ www \ login \ connection.php on line 2 Code: <?php @connect = mysql_connect("localhost","root","") or die ("Erro...
asked by 06.12.2016 / 22:53
1
answer

How to check if a trigger exists or not before creating it?

I want to create a trigger in table_X but first I would like to check if it already exists on my base .... how do I? CREATE TRIGGER IF NOT EXISTS before_update_tableX ... ect     
asked by 16.12.2016 / 17:02
1
answer

Error in insert in database

Well I'm developing an IT inventory besides giving some error, when inserting a hd of 80 it only saves the zero and the other data are not entered as well. how can I solve this. Thisisthecode<formmethod="post" action="cadastrando.php" onSub...
asked by 22.12.2016 / 21:34
2
answers

Compare MySQL search results

I need to compare the result of a query to not repeat the result. For example: I have in the unit register your cod and speed, but I can have 2 situations: 1) more than one occurrence for the same unit and different speeds, and need to...
asked by 21.11.2014 / 14:51
2
answers

PHP statement executed directly by MySQL

Currently, as the sending of the email was giving a lag in the application, because it has to connect with Gmail etc, I transferred to the server the mission to send these messages, as follows: / p> User writes the% s message to the recipie...
asked by 17.09.2014 / 19:21
2
answers

How to compare an inserted phrase with those in the DB returning the probability of being similar?

I would like to know how to compare a phrase entered by the user with the phrase in the DB so that it returns the probability of being similar. I have a similar code that compares two strings in JAVA but needed to do it in PHP + MySQL     
asked by 07.11.2014 / 13:23
2
answers

Put value in everything that is null in mysql

I have the following problem, I created a table in mysql I added all the records and after that I created a foreign key in it, in this table it contains information of only one "thing", however in the future it will have more things. I would lik...
asked by 15.01.2015 / 18:37