SQL Server BasicsWhat is SQL Server database?What is RDBMS?What is Normalization?Why we use Denormalization?What_is_SQL?What is PL/SQL?Difference between SQL and PL/SQLDatabase TableOne to One RelationshipOne to Many RelationshipMany to Many RelationshipMany to One RelationshipString Data TypesNumber Data TypesDate Data TypesOther Data TypesCreate DatabaseDrop DatabaseCreating and Managing Users in SQL ServerCreate TableAlter TableDrop TableConstraints in SQL serverPrimary KeyForeign KeyUnique KeyCandidate KeyComposite KeyDifference between primary key and candidate keyPrimary key and foreign key relationshipSurrogate KeyCascading Referential Integrity ConstraintsSelf Referential Integrity ConstraintsInsert into statementInsert multiple recordsUpdate statementDelete statementTruncate statementDifference between Delete and TruncateAlias in SQL ServerSelect statementSelect DistinctSelect TopSelect IntoNull Functions(ISNULL(),NULLIF(),COALESCE())Sub QueryIdentity ColumnSequence objectDifference between sequence and identity columnSQL Server ClausesWHERE ClauseOrder By ClauseTop N ClauseGroup By ClauseHaving ClauseDifference between Where and HavingSQL Server OperatorsArithmetic OperatorsComparison OperatorsLogical OperatorsBitwise OperatorsAny OperatorsAll OperatorsUnion OperatorsUnion All OperatorsDifference between Union and Union AllIntersect OperatorExcept OperatorDifference between Except and IntersectJoinsInner JoinLeft JoinRight JoinFull JoinSelf JoinCross JoinViewsWhat are views?Create views using SSMSIndexed ViewsComplex ViewsCheck Option in ViewCheck Encryption in ViewSchema Binding Option in ViewRead-only ViewsUpdatable ViewsAdvantages and disadvantages of viewsCreate multiple views on one tableCan we implement index on views?Can we Perform Insert, update, delete operation on views?Stored Procedure and FunctionsWhat are Stored Procedures?Why we use stored procedures?Passing parameters to Stored procedureUser-Defined FunctionsDifference between UDF and Stored procedurePre-Defined Functions@@Indentity and Scope_IndentityNULLIF, ISNULL and COALESCE

Number Data Types in SQL Server

In SQL Server, there are several number data types that you can use to store numeric data. Here are the commonly used number data types in SQL Server:

  1. INT: Integer data type used to store whole numbers. It can hold values from -2,147,483,648 to 2,147,483,647.
  2. BIGINT: Large integer data type used to store larger whole numbers. It can hold values from -9,223,372,036,854,775,808 to 9,223,372,036,854,775,807.
  3. SMALLINT: Small integer data type used to store small whole numbers. It can hold values from -32,768 to 32,767.
  4. TINYINT: Tiny integer data type used to store very small whole numbers. It can hold values from 0 to 255.
  5. DECIMAL(p, s) or NUMERIC(p, s): Fixed-point decimal data type used to store precise numeric values. The 'p' parameter specifies the total number of digits, and the 's' parameter specifies the number of digits after the decimal point. For example, DECIMAL(10, 2) can store numbers up to 10 digits long with 2 decimal places.
  6. FLOAT: Floating-point data type used to store approximate numeric values. It can hold large or small numbers with decimal places. The precision depends on the size specified.
  7. REAL: Floating-point data type used to store single-precision floating-point numbers.
  8. MONEY: Data type used to store monetary values. It stores values up to four decimal places, representing a fixed-point decimal number.
  9. SMALLMONEY: Data type used to store small monetary values. It stores values up to four decimal places, representing a fixed-point decimal number.

It's important to choose the appropriate number data type based on the range and precision requirements of your numeric data. Using the correct data type ensures efficient storage and appropriate handling of your numerical values in SQL Server.