IST 272 Chapter 8 quiz

Réussis tes devoirs et examens dès maintenant avec Quizwiz!

Which uses the least amount of storage? 'gr' stored in a column of type varchar(20) 'apple' stored in a column of type varchar(20) 'grape' stored in a column of type varchar(20) They all use the same amount of storage

'gr' stored in a column of type varchar(20)

The integer and decimal data types are considered ________________ because their precision is exact.

exact numeric data types

Which data types are used to store whole numbers?

integer

The _______________ of a decimal value indicates the total number of digits that can be stored in a decimal data type.

precision

___________________ is the total # of digits that can be stored.

precision

All of the following values can be stored in a column that's defined as decimal(6,2), except

32492.05

Which of the following pieces of code cast a decimal field named InvoiceAmount to a varchar datatype using the CAST function:

CAST(InvoiceAmount AS varchar)

The difference between the CAST function and the CONVERT function is that the _____________ function accepts an optional style argument that lets you specify a format for the result.

CONVERT

Which of the following statements is true about the CONVERT and TRY_CONVERT functions?

CONVERT returns an error if the expression can't be converted, but TRY_CONVERT returns a NULL value.

Which of the following statements is true?

Implicit data type conversion is performed when you mix values of different data types in an expression.

Which uses the least amount of storage? 'apple' stored in a column of type nchar(20) 'grape' stored in a column of type nchar(20) 'gr' stored in a column of type nchar(20)

They all use the same amount of storage.

The char and nchar data types are used to store fixed-length strings. Which of the statements below are true? Data stored using these data types occupies the same number of bytes regardless of the actual length of the string. They are typically used to define columns that have a fixed number of characters. The char(2) data type will always contain two characters.

all of the above

To store a date value without storing a time value, you can use the

date data type

You can use what data type to store a date that includes a time zone offset?

datetimeoffset

The float data type can be used to store a _________________, which provides for numbers with up to 15 significant digits.

double-precision number

If you assign a value with one data type to a column with another data type, SQL Server converts the value to the data type of the column using what?

implicit conversion

________________ is the # of digits a value has to the right of the decimal point.

scale

The real data type can be used to store a _________________, which provides for numbers with up to 7 significant digits.

single-precision number

To code a/an _____________ value as a literal, precede the value with the character N.

unicode

______________ characters can be used to encode most of the characters in most of the languages of the world.

unicode


Ensembles d'études connexes

Lymphatic System Organs & Functions

View Set

Pharm Ch. 23 - Antianginal Drugs

View Set

Legal Environment Exam 2 (Chapters 10-14)

View Set

FIN Ch.4 Analysis of Financial Statements

View Set

Chapter 38: Nursing Care of the Child With an Alteration in Intracranial Regulation/Neurologic Disorder

View Set

Biology Chapter 51 Online Quiz, Biology

View Set

APES CHP 10 Forestry Percentages

View Set

Student question Bank chapter 17: Textbook Clinical chemistry Principles, Techniques, and Correlations 7th edition

View Set

Tema 2: Descripción numérica de una variable

View Set