Tag Info

New answers tagged

0

by Unique constraint on your payment_method field, you can make sure that payment_method is unique. If the peyment_method is already exists, it will throw a SQL Error. Duplicate entry 'x' for key 'peyment_method' The SQL for that would be: ALTER TABLE YourTableName ADD UNIQUE (payment_method) But if you mean you need to make sure this payment_method ...


-1

Is your MySQL on auto-commit? If not, try immediately after the update to run a commit statement. What I think it is happening is that when you run an update statement from phpMyAdmin you are actually inside a SESSION. If you do not run the statement: COMMIT; when you go outside the SESSION everything gets rolled-back


1

I did the same as you did and it worked. mysql> INSERT INTO `test`.`wp_posts` (`idws_posts`, `post_content`) VALUES ('1', '<img src="http://31.media.tumblr.com/eet1r5co8so1/tumblr_mzlt6zqeet1r5co8so1.gif" alt="" />'); Query OK, 1 row affected (0.01 sec) mysql> INSERT INTO `test`.`wp_posts` (`idws_posts`, `post_content`) VALUES ('2', '<img ...


0

Following steps worked for me in mysql Step 1 : add/edit following Connection con = DriverManager.getConnection("jdbc:mysql://ipaddress:3306/logparser?noAccessToProcedureBodies = true ", "root", ""); Step 2 : Execute following query GRANT ALL ON logparser.proc TO root@'%'; where logparser is DB name and proc is procedure name.


1

I've made it in a TRIGGER calling a Stored Procedure inside resultsTBL table. Table lotteryTBL and resultsTBL: mysql> SELECT * FROM test.lotteryTBL; +----+------+------+------+------+------+------+-------------+ | ID | num1 | num2 | num3 | num4 | num5 | num6 | howmanyknew | +----+------+------+------+------+------+------+-------------+ | 1 | 1 | ...


1

Your syntax is wrong. I don't think putting a loop inside a TRIGGER is a good idea, but I made you a Stored Procedure as example: Procedure: USE `test`; DROP procedure IF EXISTS `new_procedure`; DELIMITER $$ USE `test`$$ CREATE DEFINER=`root`@`localhost` PROCEDURE `new_procedure`() BEGIN SET @counter=0; SET @column=''; WHILE (@counter < 6) DO SET ...


1

Looks like someone inserted data by hand into the primary key of u5z87_extensions, and this primary key is auto-increment, this means you are in trouble. But i think you can solve that using: create table u5z87_extension_back like u5z87_extensions; insert into u5z87_extension_back(all columns excluding the primary key) select (all columns excluding the ...


0

innodb_log_file_size changed between the time you last ran mysqld and now. This problem has been repeatedly answered. I see at least one in the right column.



Top 50 recent answers are included