[MySQL]-differences between MySQL and MSSQL _ MySQL

Source: Internet
Author: User
[MySQL]-differences between MySQL and MSSQL: bitsCN.com

Recently, I switched my website to Mysql as a database server. I encountered some problems. Below is a summary:

1. storage format

When using MySQL for the first time, it is estimated that many people will encounter '? ', We all know the question mark is a storage format problem,

First, you can viewCharacter set, It should beUtf8 -- UTF-8 Unicode. This character set is not used when the default character set is used,

Note the following when creating a database script!

2. SQL statements

MySQL has already started to support stored procedures. if you are used to the SQL syntax in MS SQL, pay attention to the following aspects in My SQL.

1. First, the first few digits are notTOPIn MySQLLIMIT.

SelectColumnFromTableLIMIT5

2. the delete statement must beDelete From

3. the stored procedure parameter is not@, Changed to a keywordINAndOUT

4. add a semicolon (;) at the end of each execution to indicate that the execution is complete.

5. keywords of ms SQL are not recognized when the stored procedure is created.AS

6. when using scripts to create a stored procedure, you must add a parentheses after the name of the stored procedure, regardless of whether there are parameters!

CREATE PROCEDUREPro_GetMaxId ()

BitsCN.com

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.