Posts Tagged ‘sql’

nosql vs sql databases differences

Following are major differences between NoSql and Sql databases NoSQL Database SQL Databases Open Source databases Mixed(Open source and closed source) Different types including key-value stores, document databases, wide-column stores, and graph databases One type (SQL database) with minor variations Examples: MongoDB, HBase, Cassandra, Neo4j Oracle, PostgreSQL, MySQL, Microsoft SQL Server, Sybase


  Tables: Table is a database object which holds the data and contains one or more columns associated with its datatypes Creating a Table: we use the create table statement to create a table. The simple syntax for the creation of table. Syntax: CREATE Table table_name (column_name type [CONSTRAINT constraint_def DEFAULT default_exp], column_name type [CONSTRAINT […]

SQL Queries

1) SQL Query to write ‘ORACLE’ string vertically Query: SELECT SUBSTR(‘ORACLE’, ROWNUM, 1)FROM DUAL CONNECT BY LEVEL <= LENGTH(‘ORACLE’) 2) Display 1 to 10 numbers using DUAL table Query: SELECT ROWNUM FROM DUAL CONNECT BY LEVEL <= 10


1 triggers A Database Trigger is a stored procedure that is fired when a DML operation is performed on the table.In total there are 13 types of Triggers Sytax for creating a trigger: CREATE OR REPLACE TRIGGER <TRIGGERNAME> before / after [INSERT / UPDATE / DELTE ] ON <TABLE NAME> {For each Statement / Row} […]

Powered by k2schools