Thanks to visit codestin.com
Credit goes to www.scribd.com

0% found this document useful (0 votes)
6 views14 pages

DAY 3 SQL Server Lab1 - p2

The document outlines various data types used in SQL Server, including int, money, decimal, and datetime types, emphasizing their specific uses and advantages. It also discusses the importance of backing up and restoring databases in SQL Server to protect and recover data. Additionally, it highlights the use of character strings for different languages and the significance of precision in datetime data types.

Uploaded by

marwa.mah1956
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
6 views14 pages

DAY 3 SQL Server Lab1 - p2

The document outlines various data types used in SQL Server, including int, money, decimal, and datetime types, emphasizing their specific uses and advantages. It also discusses the importance of backing up and restoring databases in SQL Server to protect and recover data. Additionally, it highlights the use of character strings for different languages and the significance of precision in datetime data types.

Uploaded by

marwa.mah1956
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
You are on page 1/ 14

We usually use int.

The bit store one of three values 0, 1, and NULL


The money and smallmoney data type store currency values.
The decimal and numeric data types are identical
We use decimal instead of money as is also available in c#
 Real & float store floating point numeric data. They are often used
in scientific calculations.
you should use the time, date, datetime2 and datetimeoffset data types.
Because these types align with the SQL Standard and have more
seconds precision.

datetimeoffset supports time zone.


We usually use int.
Character strings data types allow you to store either fixed-length
(char) or variable-length data (varchar).
nchar & nvarchar to strore other languages (e.g arabic).
 use max size when the data size is unknown.

The text data type can store non-Unicode data in the code page of
the server.
DML - Examples
DML - Examples
DML - Examples
SQL Server – Creating Backups

•Backup is a copy of data/database, etc. Backing up


MS SQL Server database is essential for protecting
data.
SQL Server – Restoring Databases

Restoring is the process of copying data from a


backup and applying logged transactions to the data.

Restore is what you do with backups. Take the backup


file and turn it back into a database.

You might also like