What is the use of * in mysql | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
+ 2

What is the use of * in mysql

4th Dec 2018, 12:31 AM
vansh
vansh - avatar
2 Answers
4th Dec 2018, 1:32 AM
Lambda_Driver
Lambda_Driver - avatar
+ 1
The * is used to select all fields in a table without having to list each individual field. For example, say you have a table named customer that contains 3 fields: id_num, name, address. If you need to pull all of the fields you can write: SELECT id_num, name, address FROM customer or you could write: SELECT * FROM customer
4th Dec 2018, 1:06 AM
Shannon S
Shannon S - avatar