1.

What is the best datatype for a column that is expected to store values up to 2 million?(a) SMALLINT(b) TINYINT(c) MEDIUMINT(d) BIGINTThis question was posed to me in my homework.This interesting question is from Setting Up Secure Connections in section Access Control and Security of MySQL

Answer»

Right option is (d) BIGINT

For explanation I would say: The different NUMERIC types used in MySQL are used to store a different RANGE of values. To store values of the order of a million, the MEDIUMINT or BIGINT DATATYPE is SUFFICIENT.



Discussion

No Comment Found

Related InterviewSolutions