Python and MySQL - Populating our Database and Table

preview_player
Показать описание
A series of Python Tutorials covering all the basics of Python and MySQL. This video will cover populating our database and table in MySQL with Python. We'll understand how to execute SQL commands to push single and multiple sets of data.

♦♦♦♦♦♦♦♦♦♦

THECODEX is a company focused on empowering and enabling anyone to learn how to code. Established in 2015 by Avinash Jain, THECODEX has taught over 175,000 students around the world how to code. With over 15 programming courses on a wide variety of topics, and more than 10,000 5-Star reviews, THECODEX is the right choice for you.

We provide engaging and comprehensive videos that break down complex information and cover everything you need to know about the subject. All students get access to our Q/A forums where you can get your doubts and problems cleared up. At the end of every course, you will receive a certificate of completion.

Jumpstart your Coding Journey with THECODEX today!

♦♦♦♦♦♦♦♦♦♦

Music: Flash Funk (Marshmello)
Рекомендации по теме
Комментарии
Автор

Finally, I found the perfect tutorial, Thank you❤❤

shyampatel
Автор

best ever coding experience from video

archiessingh
Автор

Thank you so much for putting this tutorial out! Very easy to follow and explained very well!

daywalker
Автор

These videos make everything seem so clear! Thank you for the help and keep up the good work!!

uzmapatel
Автор

excellent this is the perfect tutorial

sakshamkumar
Автор

Thank you and also do not forget to commit your changes, you need to commit with your "CONNECTOR" value which is mydb for this example
mydb.commit() or you won't be seeing your datas in MySQL sometimes

unlucky-
Автор

i kicked the views to 51, 100
no difference not 51, 099 or less or 51, 101 or more
exact.
i love your videos and was your 100th subscriber

adityajha
Автор

Very informative video !!! Helped me a lot !!! Very good presentation !!!

vivekgupta
Автор

very informative and easy to understand, thanks for your sharing

wkbnyxv
Автор

2:43 For some reason, the database has not been stored in MySQL Workbench... If someone could help... It would be appreciated. Thank you!

alexkerasidis
Автор

here we put age as also a string, even though its integer. Also put the age 51 in ‘51’.
If not is will not work

ourmaths
Автор

Thank you so much! Awesome From Russia with Love))))

djpatronrussia
Автор

I have tried the new python3 syntax and I am still getting the Not all parameters were used In the SQL statement. Help, please.
mydb = mysql.connector.connect(
user="root",
host="localhost",

database="testdb"
)

mycursor = mydb.cursor()

sqlFormula = "INSERT INTO students (name, age) VALUES {%s, %d}"
student1 = ("Hurcules, 94)

mycursor.execute(sqlFormula, student1)

mydb.commit()

gcmceachin
Автор

The information will not sync into my database there is not error in sql but there is a error in my python in cmd_query
raise errors.get_mysql_exception(exc.errno, msg=exc.msg,
1292 (22007): Incorrect date value: '1963' for column 'Birthday' at row 1

and I don't know what it means. I put it in date format YYY-MM-DD

tntaylor
Автор

A better example for commit is the idea that all changes you make are cached, and wont be updated unless you commit to it.

zeektm
Автор

What if you have more than just two columns, would it be like

(Col1, col2, col3, col4, col5)

prod.kashkari
Автор

Thanks for the great tutorial! Anyway, if we already have the student&age table already (a csv file for example), can we directly input them to the testdb and how? Thank you

nfttri
Автор

Is INSERT the only operator where we can use %s?

marceloa.
Автор

So say if I had a GUI that has a function for inputting the student values would it look like sqlFormula = "INSERT INTO students (name, age) VALUES (function)?

Shigazane
Автор

The sqlformula keeps showing a syntax error, I think its because its reading the whole like code as a text from the quotation marks. How do I fix this?

fatdoodlecake