SQL BI Training

What is a relational database?

relational database (RDB) is a collective set of multiple data sets organized by tablesrecords and columns. RDBs establish a well-defined relationship between database tables. Tables communicate and share information, which facilitates data searchability, organization and reporting.

RDBs use Structured Query Language (SQL), which is a standard user application that provides an easy programming interface for database interaction.

Relational databases are based on the relational modelan intuitive, straightforward way of representing data in tables. In a relational database, each row in the table is a record with a unique ID called the key. The columns of the table hold attributes of the data, and each record usually has a value for each attribute, making it easy to establish the relationships among data points.

Benefits of Relational Databases:

  • Data Consistency
  • Commitment and Atomicity
  • Stored Procedures and Relational Databases
  • Database Locking and Concurrency

Relational Database Terms

Below are the unique terms and specific definitions that will help you understand what a RDB can do and how it works:

Row : A set of data constituting a single item.

For example, the data for a single employee (e.g. first name, last name, employee ID, hire date, work location, etc.) of a company would be displayed in a row. A row can also be called a record, an entity, or a tuple.

Column: Labels for elements of rows. A column gives context to the information contained in rows. For an employee database, the column headers could be the items listed above for employees. A column is also known as an attribute or a field.

Table: A group of rows that match the parameters set up for the table. The data in a table must all be related. An employee database may have separate tables for active employees, retired employees, and former employees. A table is also known as a relation or base revelar.

View: A set of data based on a query via the RDBMS; also known as result set or derived revelar.

Domain: The set of possible values for a given column. For example, the phone number and ZIP code columns would be numbers, while first and last names would be limited to letters.

Constraint: A narrowing of a domain. For example, the domain of the work location on a employee record would be alphanumeric, but it could be restricted to a predefined list rather than being a free-form field. The phone number field would be constrained to 10 digits.

Primary key: The unique identifier of a row in a table.

Foreign key: The unique identifier of a row in another table.

Distributed Database: A database that stores data in multiple locations, rather than on a single hard drive or server.

TYPES OF DATABASE RELATIONSHIPS

The power of a relational database is in the links and relations. By connecting rows in different tables through the use of primary and foreign keys, you can create views, reports, and other slices of information to serve your organization. There are three primary types of database relationships:

One-to-One: One row in one table is connected to one and only one row in another table. For example, a Social Security number is linked to a single employee.

One-to-Many: One row in one table is connected to zero, one, or more than one rows in another table. For example, one work location can be linked to many employees.

Many-to-Many: Zero, one, or many rows in one table are linked to zero, one, or many rows in another table. For example, multiple employees can be assigned to multiple projects.

What is Power BI ?

Kindly refer the below video on What is Power BI and it’s uses.

Power BI is a business analytics service by Microsoft. It is a cloud-based, elegant end-to-end business analytics tool that enables anyone to visualize, analyze, forecast any type of data with greater speed, efficiency, and understanding.

Power BI provides cloud-based BI services, known as “Power BI Services“, along with a desktop based interface, called “Power BI Desktop”. It offers data warehouse capabilities including data preparation, data discovery and interactive dashboards. Microsoft released an additional service called Power BI Embedded on its Azure cloud platform. One main differentiator of the product is the ability to load custom visualizations.

Key components:

Power BI Desktop : The Windows-desktop-based application for PCs and desktops, primarily for designing and publishing reports to the Service.

Power BI Service : The SaaS (software as a service) based online service (formerly known as Power BI for Office 365, now referred to as PowerBI.com or simply Power BI).

Power BI Mobile Apps : The Power BI Mobile apps for Android and iOS devices, as well as for Windows phones and tablets.

Power BI Gateway : Gateways used to sync external data in and out of Power BI. In Enterprise mode, can also be used by Flows and PowerApps in Office 365.

Power BI Embedded : Power BI REST API can be used to build dashboards and reports into the custom applications that serves Power BI users, as well as non-Power BI users.

Power BI Report Server : An On-Premises Power BI Reporting solution for companies that won’t or can’t store data in the cloud-based Power BI Service.

Power BI Visuals Marketplace : A marketplace of custom visuals and R-powered visuals

If you wish to learn Power BI, please find the necessary details from below link : https://sqlschool.com/PowerBI-Online-Training.html

This Power BI Online Training includes EVERY detail of each Power BI Visual, Usage and Properties as per the latest versions.

This Power BI course includes On-premise and Cloud Data Access, REST API, Azure Stream and R Integration including Data Modelling and ETL Techniques with Basic to Advanced Power Query (M Language), DAX Language Functions, Power BI Dashboards, Streaming Datasets, App Workspace, Content Packs, Data Gateways, Alerts, Power BI Report Server Components, Power BI Mobile Reports, Excel Integration, Excel Analysis, KPIs for Big Data Analytics, Microsoft OneDrive, Google Big Query, DataFlow and ETL in Cloud are also a part of this Power BI Online Training course in addition to Mock Interviews, Resume Guidance, Concept wise Interview FAQs and ONE Real-time Project.

Website: http://www.sqlschool.com

Contact Us:

Email: contact@sqlschool.com

India : +91 9666 44 0801, +91 9666 64 0801

USA (+1): (510) 400-4845

 

What is SQL?

SQL stands for Structured Query Language. SQL is used to communicate with a database. According to ANSI (American National Standards Institute), it is the standard language for relational database management systems. It is used to perform operations on the data present in database.

SQL statements are used to perform tasks such as update data on a database, or retrieve data from a database.

Although most database systems use SQL, most of them also have their own additional proprietary extensions that are usually only used on their system.

However, the standard SQL commands such as “Select”, “Insert”, “Update”, “Delete”, “Create”, and “Drop” can be used to accomplish almost everything that one needs to do with a database.

SQL commands are divided into several different types, among them data manipulation language (DML) and data definition language (DDL) statements, transaction controls and security measures.

Some common relational database management systems that use SQL are: Oracle, Sybase, Microsoft SQL Server, Access, Ingres, etc.

What is PL/SQL?

What is PL/SQL?

PL/SQL stands for Procedural Language extension of SQL.

PL/SQL is a combination of SQL along with the procedural features of programming languages.

It was developed by Oracle Corporation in the early 90’s to enhance the capabilities of SQL.

The PL/SQL Engine:

Oracle uses a PL/SQL engine to processes the PL/SQL statements. A PL/SQL language code can be stored in the client system (client-side) or in the database (server-side).

What is a NULL Value?

A field with a NULL value is a field with no value.

If a field in a table is optional, it is possible to insert a new record or update a record without adding a value to this field. Then, the field will be saved with a NULL value.

Note: It is very important to understand that a NULL value is different from a zero value or a field that contains spaces. A field with a NULL value is one that has been left blank during record creation!

What is the difference between various types of joins? For instance, there’s inner join, left join, right join, full join, cross join, natural join, equi-join, and semi-join?

Different types of joins are required depending on the type of data wrangling one needs to do. Let’s work with an example here. In this toy example, we have 2 tables-

  1. Married- This contains the name and social security number ( SSN) of the people who are married.
  2. Home Owners- This contains the name and social security number ( SSN) of the people who own a home

SSN is unique for each person and will be used as a primary key to merge two tables.

Let’s now look at the types of joins using the above 2 tables and which group they would provide the information on from both or either tables.

  1. Inner Join- If we want to find out people who are both married and home owners- Mia, Liz, Benjamin, Ava.
  2. Left Join- All married folks, whether or not home owners- John, James, Harper, Amy, Mia, Liz, Benjamin, Ava.
  3. Right Join– All home owners, whether or not married- Mia, Liz, Benjamin, Ava, Sophia, William, Jacob, Michael
  4. Full Join- Everyone from both tables- Mia, Liz, Benjamin, Ava, Sophia, William, Jacob, Michael, John, James, Harper, Amy.

left

Use keys from left frame only

right

Use keys from right frame only

outer

Use union of keys from both frames

inner

Use intersection of keys from both frames

What are the typical uses of service accounts in running SQL Server components?

Service accounts are all about security and access. So, for example, SQL Agent runs as a service and it can be configured (should be) to run under a service account. Let’s assume that you use Agent to run backups. Let’s also assume you backup to a shared file location on your network that’s not local to the machine you’re running SQL Agent on. You’ll need to ensure that the account configured for SQL Agent has access to that shared file location. While this may seem like work, what it in fact is doing is following the method of least access. That service account has to have access to that share, but it doesn’t need access to other file locations on your system, so you only give it what it needs and nothing more. Same thing applies to the other services and service accounts.

For More Information www.sqlschool.com

MS SQL Server – Editions

SQL Server is available in various editions. This chapter lists the multiple editions with its features.

Enterprise − This is the top-end edition with a full feature set.

Standard − This has less features than Enterprise, when there is no requirement of advanced features.

Workgroup − This is suitable for remote offices of a larger company.

Web − This is designed for web applications.

Developer − This is similar to Enterprise, but licensed to only one user for development, testing and demo. It can be easily upgraded to Enterprise without reinstallation.

Express − This is free entry level database. It can utilize only 1 CPU and 1 GB memory, the maximum size of the database is 10 GB.

Compact − This is free embedded database for mobile application development. The maximum size of the database is 4 GB.

Datacenter − The major change in new SQL Server 2008 R2 is Datacenter Edition. The Datacenter edition has no memory limitation and offers support for more than 25 instances.

Business Intelligence − Business Intelligence Edition is a new introduction in SQL Server 2012. This edition includes all the features in the Standard edition and support for advanced BI features such as Power View and PowerPivot, but it lacks support for advanced availability features like AlwaysOn Availability Groups and other online operations.

Enterprise Evaluation − The SQL Server Evaluation Edition is a great way to get a fully functional and free instance of SQL Server for learning and developing solutions. This edition has a built-in expiry of 6 months from the time that you install it.

2005 2008 2008 R2 2012 2014
Enterprise Yes Yes Yes Yes
Standard Yes Yes Yes Yes
Developer Yes Yes Yes Yes
Workgroup Yes Yes No No
Win Compact Edition – Mobile Yes Yes Yes Yes
Enterprise Evaluation Yes Yes Yes Yes
Express Yes Yes Yes Yes
Web Yes Yes Yes
Datacenter No No
Business Intelligence Yes

Types of keys is SQL Server

What is Key? Keys are fields in a table which participate in below activities in RDBMS systems:

  • To create relationships between two tables.
  • To maintain uniqueness in a table.
  • To keep consistent and valid data in database.
  • Might help in fast data retrieval by facilitating indexes on column(s).

SQL Server supports various types of keys, which are listed below:

  1. Candidate Key
  2. Primary Key
  3. Unique Key
  4. Alternate Key
  5. Composite Key
  6. Super Key
  7. Foreign Key

Before discussing each type in brief, have a look on the below image used as an an example to define types of keys.

Lets discuss each type in detail:

  • Candidate Key: Candidate key is a key of a table which can be selected as a primary key of the table. A table can have multiple candidate keys, out of which one can be selected as a primary key.

Example: Employee_Id, License_Number and Passport_Number are candidate keys

  • Primary Key: Primary key is a candidate key of the table selected to identify each record uniquely in table. Primary key does not allow null value in the column and keeps unique values throughout the column. In above example, Employee_Id is a primary key of Employee table. In SQL Server, by default primary key creates a clustered index on a heap tables (a table which does not have a clustered index is known as a heap table). We can also define a nonclustered primary key on a table by defining the type of index explicitly.

A table can have only one primary key and primary key can be defined in SQL Server using below SQL statements: CRETE TABLE statement (at the time of table creation) – In this case, system defines the name of primary key ALTER TABLE statement (using a primary key constraint) – User defines the name of the primary key Example: Employee_Id is a primary key of Employee table.

  • Unique Key: Unique key is similar to primary key and does not allow duplicate values in the column. It has below differences in comparison of primary key:

It allows one null value in the column. By default, it creates a nonclustered index on heap tables. Alternate Key Alternate key is a candidate key, currently not selected as primary key of the table. Example: License_Number and Passport_Number are alternate keys.

  • Composite Key: Composite key (also known as compound key or concatenated key) is a group of two or more columns that identifies each row of a table uniquely. Individual column of composite key might not able to uniquely identify the record. It can be a primary key or candidate key also.

Example: In salary table, Employee_Id and Salary_Month_Year are combined together to identify each row uniquely in Salary table. Independently Employee_Id or Salary_Month_Year column cannot identify each row uniquely. We can create a composite primary key on Salary table using Employee_Id and Salary_Month_Year columns.

  • Super Key: Super key is a set of columns on which all columns of the table are functionally dependent. It is a set of columns that uniquely identifies each row in a table. Super key may hold some additional columns which are not strictly required to uniquely identify each row. Primary key and candidate keys are minimal super keys or you can say subset of super keys.

In above example, In Employee table, column Employee_Id is sufficient to uniquely identify any row of the table, so that any set of column from Employee table which contains Employee_Id is a super key for Employee Table. For example: {Employee_Id}, {Employee_Id, Employee_Name}, {Employee_Id, Employee_Name, Address} etc. License_Number and Passport_Number columns can also identify any row of the table uniquely. Any set of column which contains License_Number or Passport_Number or Employee_Id is a super key of the table. For example: {License_Number, Employee_Name, Address}, {License_Number, Employee_Name, Passport_Number}, {Passport_Number, Employee_Name, Address, License_Number}, {Passport_Number, Employee_Name}, {Passport_Number, Employee_Id} etc.

  • Foreign Key: In a relationship between two tables, a primary key of one table is referred as a foreign key in another table. Foreign key can have duplicate values in it and can also keep null values if column is defined to accept nulls.

Example: Employee_Id (primary key of Employee table ) is a foreign key in Salary table.

SQL School: Best Trainers for Microsoft SQL Server Technologies

SQL School: Best Trainers for Microsoft SQL Server Technologies

Choose SQL School (http://www.sqlschool.com) for LIVE Online, Classroom and Video Trainings.

SQL School: Best Trainers for Microsoft SQL Server Technologies

Best Trainers for Microsoft SQL Server Technologies

 

SQL School: Best Trainers for Microsoft SQL Server Technologies 

 

About SQL School Training Institute

SQL School (Regd: SequelGate Innovative Technologies Pvt. Ltd.) is strongly committed to provide complete real-time and practical training exclusively on Microsoft SQL Server and Datawarehousing technologies. SQL School Training Institute established in February, 2008 is now one of the best training institute offering SQL Server and T-SQL (SQL Server) Training, SQL Database Administration (SQL DBA) Training and Business Intelligence (MSBI / SQL BI) Training.

 

Training Highlights:

  • Highly Interactive, Practical
  • Certifications & Resumes
  • Placements & Job Support
  • THREE Realtime Case Studies
  • One Real-time Project
  • 24×7 LIVE Server with Lab

 

 

Continue reading