MySQL Stored Procedure 4 - Creating Variables within SELECT

710 views

0   0

Let's learn how to create variables within a SELECT statement! This is great for when we want to have a result table showing the result of our variable. Keep in mind that you must put a colon before the equals in the assignment operator. If you forget to do this, MySQL is going to think you are doing a comparison!

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

SUPPORT ME!: http://www.patreon.com/calebcurry

Subscribe to my newsletter: http://eepurl.com/-8qtH

Donate!: http://bit.ly/DonateCTVM2.

~~~~~~~~~~~~~~~Additional Links~~~~~~~~~~~~~~~

More content: http://CalebCurry.com
Facebook: http://www.facebook.com/CalebTheVideoMaker
Google+: https://plus.google.com/+CalebTheVideoMaker2
Twitter: http://twitter.com/calebCurry

Amazing Web Hosting - https://www.dreamhost.com/r.cgi?1487063 (The best web hosting for a cheap price!)
View More
Comments

0 Comments