Article Categories
- All Categories
-
Data Structure
-
Networking
-
RDBMS
-
Operating System
-
Java
-
MS Excel
-
iOS
-
HTML
-
CSS
-
Android
-
Python
-
C Programming
-
C++
-
C#
-
MongoDB
-
MySQL
-
Javascript
-
PHP
SQL Articles
Found 115 articles
Operations on Files
When working with files in a DBMS, two fundamental types of operations are performed: retrieval (finding and reading records) and update (inserting, deleting, or modifying records). Both use selection conditions to identify target records. Selection Conditions A selection condition specifies criteria that records must meet. Conditions can be − Simple − Uses one field (e.g., Ssn = '123-45-6789') Complex − Combines multiple fields with comparison operators (e.g., Department = 'Sales' AND Salary ≥ 30000) File Operations The typical sequence of file operations − 1. Open file 2. Find first record matching ...
Read MoreObject-Relational Features_ Object Database Extensions to SQL
The object-relational model combines relational databases with object database features. SQL (starting from SQL:1999 and refined in SQL:2008) incorporates object extensions including user-defined types, object identity, encapsulation, and inheritance. Key Object Features in SQL Feature Description Type Constructors ROW type (struct), ARRAY, SET, LIST, BAG for complex objects Object Identity REF types provide unique object identifiers (OIDs) Encapsulation Methods defined within UDTs (User-Defined Types) Inheritance UNDER keyword for type and table inheritance User-Defined Types (UDTs) UDTs allow creating complex-structured objects with custom attributes and ...
Read MoreNested Queries in SQL
A nested query (subquery) is a query placed inside another query. The inner query executes first and its result is used by the outer query for more complex data retrieval. Syntax SELECT column1, column2 FROM table1 WHERE column1 IN ( SELECT column1 FROM table2 WHERE condition ); Types of Nested Queries Non-Correlated Inner runs independently Result passed to outer Operators: IN, NOT IN, ALL, ANY ...
Read MoreDifference between NoSQL and RDBMS
RDBMS stores data in structured tables with fixed schemas using SQL. NoSQL is a non-relational approach with flexible schemas, designed for large-scale distributed data. Companies like Amazon, Facebook, and Google pioneered NoSQL to handle massive data volumes that traditional RDBMS struggled with. RDBMS ID Name Age Fixed Schema | Vertical Scaling vs NoSQL ...
Read MoreWhat is NoSQL and is it the next big trend in databases?
A NoSQL ("non SQL" or "non relational") database stores and retrieves data using models other than relational tables. NoSQL databases are structured as key-value pairs, documents, columns, or graphs − designed for large-scale data, high performance, and flexible schemas. Why NoSQL? Applications like Facebook, Google, and Amazon need to handle massive data volumes that traditional RDBMS struggles with. NoSQL allows adding new data fields without redesigning the entire schema − ideal for agile development. SQL vs NoSQL Example SQL requires predefined tables and schema changes for new features ? CREATE TABLE users (id INT ...
Read MoreDifference between Function and Procedure
SQL (Structured Query Language) is a computer language which is used to interact with an RDBMS (Relational Database Management System). It is basically a method of managing, organizing, and retrieving data from a relational database. In SQL, two important concepts are used namely, function and procedure. A function calculates the results of a program based on the inputs provided, whereas a procedure is used to perform some tasks in a specific order. There are many other differences between functions and procedures, which we will discuss in this article. What is Function? A function, in the context of ...
Read MoreAnalogous to IN operator of SQL in SAP
You can get similar functionality to SQL's IN operator done in many ways in SAP. You can use an internal table usage or a range table approach. Let me showcase an example with an internal table for your reference. Using Internal Table with FOR ALL ENTRIES The FOR ALL ENTRIES clause in SAP allows you to filter data based on values from an internal table, similar to the IN operator in SQL − SELECT Id, Name, DOB FROM sEmployee INTO ...
Read MoreUsing SQL statements in ABAP Programming and Database performance
The basic principle for performance in ABAP database operations is that there should be minimal data transferred between the application server and database. SQL Performance Best Practices in ABAP Field Selection Strategy Select only the fields that are required. Avoid using SELECT * unless you need all fields. However, in specific scenarios where you have multiple SELECT statements in different parts of your program querying the same table but different columns, it may be advisable to use SELECT * because the output is stored in a ...
Read MoreDelete duplicate alphanumeric entries from column data in SQL
You can use regular expressions to remove duplicate consecutive alphanumeric characters from column data in SQL. The REPLACE_REGEXPR function with pattern matching allows you to identify and replace repeated characters with a single occurrence. Syntax The basic syntax for removing duplicate alphanumeric entries using regular expressions is − REPLACE_REGEXPR ('([A-Za-z0-9])\1+' in column_name WITH '\1' OCCURRENCE ALL) Where ([A-Za-z0-9])\1+ is the regex pattern that captures any alphanumeric character and matches one or more consecutive occurrences ...
Read MoreUsing a SQL View in SAP BusinessOne
Yes, it is possible to use a SQL view in SAP Business One client and you can use it effectively for your business reporting needs. Using SQL Views in SAP Business One A view in SAP Business One is a virtual table that displays data from one or more underlying tables. Views are particularly useful for creating custom reports and simplifying complex queries by presenting a pre-defined data structure. Query Syntax Please find below the standard format that you should be using ...
Read More