There is a case when we want to get the unique number of non-NULL values in one table column.
Before MS SQL 2019 to accomplish this task, we could use the COUNT(DISTINCT([Column_Name])) syntax. For larger tables this approach can generate noticeable performance problems.
MS SQL 2019 introduced us the APPROX_COUNT_DISTINCT function that approximates the count within a 2% precision to the actual value but at a fraction of the time and with noticeable decrease of used resources (memory and CPU).
With basic Linux knowledge let’s try to step by step install MS SQL Server on a Linux server (Ubuntu).
Sometimes using user defined functions (before SQL 2019) could lead us to performance problems. Let’s see how the usage of UDF performs in SQL 2019 and in earlier versions.
Let’s find out how MS SQL 2019 handles the problem that generates the commonly known error “String or binary data would be truncated”.
Database normalization is a process used to organize a database into tables and columns. The idea is that a table should be about a specific topic and that and only supporting topics included. Normalization is a systematic approach of decomposing tables to eliminate data redundancy.
A database View is nothing else than a stored query! When you create a database view (CREATE VIEW), the database engine stores the input query and give him a specified name. When you query the view, the database engine take the stored definition of the query and execute it with added statements by you (e.g. ORDER BY, WHERE, etc.) and execute it.
A database key provides the possibility to identify, access and update information in a database table. A key is a single field (column) or combination of multiple fields. Its purpose is to access or retrieve data rows from table according to the requirement. The keys are defined in tables to access or sequence the stored data quickly and smoothly. They are also used to create links between different tables.
Alias is a shorten name for a table (sometime even a function) that can be used in queries.
When talking about values in database world there are three possible states. The three states are: there is a value, there is not a value (empty) and the value is NULL (unknown). Let's find out more about the NULL value.
Let’s find out what is a JOIN and how to use it. The main difference between JOIN and UNION operator is that union combines results vertically, while the JOIN combines result's horizontally. There are different types of JOIN-s depending on the business need and we will discuss about them. Since the databases should be normalized it is essential to use joins to get details for some records.
Sorry, no posts matched your criteria