The amazing technical experts who have never seen it come to watch. mysql automatically inserts two pieces of data at a time to solve the problem.

Source: Internet
Author: User
The amazing technical experts who have never seen them come to watch !!! Mysql automatically inserts two data records at a time to solve the problem .... At the end of this post, helpmbbm will edit mysql_connect ("XXX.com", "XXX", "XXX") from 2012-06 "); mysql_sele, the amazing technical experts you have never seen before, come and watch !!! Mysql automatically inserts two data records at a time to solve the problem ....
At the end of this post, helpmbbm edited mysql_connect ("XXX.com", "XXX", "XXX") at 02:08:16 ");
Mysql_select_db ("XXX ");
Mysql_query ("set names 'utf-8 '");
$ Ip = "222 ";
$ Insql = "insert into 'IP' ('IP') VALUES ('$ IP ')";
Mysql_query ($ insql );

Php code of all pages is not html, no form is not include ....
But insert two identical entries at a time...

I have removed all the code for getting IP addresses. all the code is above. now it's amazing that two pieces of data are inserted at a time to set the value of the variable ip address to 222, you also get a local IP address that is not obtained in any way !!!!!
I thought it was a ghost cache and changed the IP address, and inserted two more, and it was a new IP address and 222.

Is it possible to obtain the built-in variable $ Ip ?? Change to $ iip and insert two ,,

Okay, change the SQL statement ID to $ insql = "INSERT INTO 'IP' ('id', 'IP') VALUES ('null ','". $ iip. "');";
In a magic result !!!!

I'm dreaming ??? I met a ghost ???



Table structure

Create table 'IP '(
'Id' int (8) not null,
'IP' varchar (20) NOT NULL
) ENGINE = InnoDB default charset = utf8;

Finally, I tried to insert only one piece of data, instead of inserting a magic IP address. After I changed the table name to an IP address, I still couldn't help but explain it to someone else .. Without any code to obtain the ip address .. Why can I get a magic IP address and insert 2 .....

After the refresh is performed, two more entries are inserted. The table name is ipip. Which of the following is an SQL statement saved ????
However, I have no way to obtain the IP address .. No framework or external files are introduced...

I want someone to believe that what I'm talking about is true? This is true ..



I can't figure it out, afraid of my own illusion .... or dreaming .. then I beat myself .. then debug the same job locally and insert a normal one, solve the magic cache technology of the above application ........................... and how to insert only one .......


The problem has been found. each person gives three chances to guess. What is the cause? I don't believe someone can guess it !! Haha
------ Solution --------------------
Try Me

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.