Error collection in PHP development, not regularly updated.

Source: Internet
Author: User
Tags array count integer key mysql version query variable
Fatal Error:non-static Method Conn::__construct () cannot is called statically

There is no static method (which refers to the method parameter, the string type) and cannot be referenced from the static context.

Fatal error: [] operator not supported for strings in/file.php

When a variable is set to a non-array type, you cannot use [] to increase the data key value of the variable with the same name
WORKAROUND: 1. Change the variable name, 2. Use $var = Array (...)
Example:
Copy CodeThe code is as follows:
This is the string type
$err = $e->getmessage ();

The error occurs when execution is here.
$err [] = array
(
' gid ' => $this->_get[' id '],
' URL ' => $new,
' Log ' => $err,
' Time ' => time ()
);

Fatal error:declaration of Listing::content () must is compatible with this of inewslist::content () in file\list_1.php on Line 7

Unified interface All class methods must be consistent with the interface: scope declaration, method name, number of parameters

Warning:mysqli::query () [Mysqli.query]: couldn ' t fetch Insert in/file.php

You must use the MYSQLI link database to return the result set to perform the operation.

Warning:1064_you have an error in your SQL syntax; Check the manual that corresponds to your MySQL server version for the right syntax to use near ...

Online search is a MySQL compatibility problem, the actual operation is a syntax error, you need to check the SQL statement is written correctly.

Warning:array_shift () expects parameter 1 to be array, integer given

The first argument of a function must be an array.

#1366-incorrect integer value: ' For column ' ID ' at row 1

The MySQL version is msyql 5.1.14 WIN32 version, the reason for the error is not to assign a value to the ID, although the previous version can be unassigned, automatically increase, but in the new version of the MSYQL to be assigned a null

#1136: Column count doesn ' t match value count at row 1

Check to see if there are any fields added to the number.
The stored data does not match the field type definition of the database table.
Whether the field type is correct, whether it is out of bounds, or not, to store one type of data in another data type.

#1062_Duplicate entry ' ... ' for key ' map '

The keyword is duplicated, may be a primary key ID, or it may be a unique field.

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.