A scrollable cursor, however, can move forward and backward, and can seek any desired record in the cursor. Such operations are common in applications that present results sets in scrolling windows. With a scrollable cursor, application developers do not need to create and manage their own buffer for the records.
SIGN (a): Returns 1 if a is positive or if a is 0, and -1 if a is less than 0.
This is called dynamic SQL. An example would be:
set lines 90 pages 0 termout off feedback off verify off
select ?drop user ?||username||? cascade;? from dba_users
where username not in ("SYS?,?SYSTEM?);
Essentially you are looking to see that they know to include a command (in this case DROP USER...CASCADE;) and that you need to concatenate using the ?||? the values selected from the database.
Insert/Update/Delete :- 3
Row Level/Statement Level:-2
For sorting we use order by clause in select statement. This is used to sort data in ascending order or descending order.
To group data based on perticulr column we use groupby clause.
Both are used to get distinct values.
Use the DISTINCT keyword right after SELECT...
i.e. SELECT DISTINCT customername FROM customer
select * from emp e where rownum=
(select max(rownum) from emp ee
Integrity constraint is a rule that restricts values to a column in a table.
A Cartesian product is the result of an unrestricted join of two or more tables. The result set of a three table Cartesian product will have x * y * z number of rows where x, y, z correspond to the number of rows in each table involved in the join.
There are 5 types
1.data definition type
SQL is Structured Query Language is a database computer language designed for managing data in relational database management systems (RDBMS).
PostgreSQL is an object-relational database management system (ORDBMS).It is released under a BSD-style license and is thus free software. As with many other open-source programs, PostgreSQL is not controlled by any single company, but has a global community of developers and companies to develop it.
SQLite is an ACID-compliant embedded relational database management system contained in a relatively small (~225 KB) C programming library. The source code for SQLite is in the public domain.
MySQL is a relational database management system (RDBMS) which has more than 6 million installations. MySQL stands for "My Structured Query Language". The program runs as a server providing multi-user access to a number of databases.