From the course: MySQL Essential Training (2019)
Unlock this course with a free trial
Join today to access over 22,600 courses taught by industry experts.
Comments - MySQL Tutorial
From the course: MySQL Essential Training (2019)
Comments
- [Instructor] My SQL supports a form of the standard SQL comments thought they haven't always, and it's not exactly correct and older versions have not always supported it at all. A standard SQL comment looks something like this and I can put after that some code and when I shift execute to make sure I get all of this, you notice that I get a result that I expect which is from the select foo. Now this is a standard SQL comment, and this works fine in My SQL. If I remove this space between the double dash and the first word of the comment, you'll notice this is no longer recognized as a comment in My SQL. When I shift execute this, I get an error. So this is still a standard SQL comment. Standard SQL does not require this space, and you'll see this often times in standard SQL code and it'll create problems in My SQL. So My SQL requires that space after the double dash and I've just gotten in the habit of including that space even when I'm not using My SQL. It just seems like good…
Practice while you learn with exercise files
Download the files the instructor uses to teach the course. Follow along and learn by watching, listening and practicing.