|Hypertext Markup LanguageCascading Style SheetsExtensible Markup LanguageJava ScriptjQueryAngularJSOracle SQLOracle PL/SQLOracle D2K FormsOracle D2K ReportsOracle DatabaseJavaJava Database ConnectivityJava ServletJava Server PagesHibernateApache TomcatCC++PHPMy-SqlUnix/LinuxMS-DOSHR Interviews|
|What is SQL?|
|Structured Query Language (SQL) is a language that provides an interface to relational database systems. The proper pronunciation of SQL is "sequel". SQL was developed by IBM in the 1970.|
|Difference between TRUNCATE, DELETE and DROP commands?|
DELETE command is used to remove some or all rows from a table. A WHERE clause can be used to only remove some rows. If no WHERE condition is specified, all rows will be removed. After performing a DELETE operation you need to COMMIT or ROLLBACK the transaction to make the change permanent or to undo it. Note that this operation will cause all DELETE triggers on the table to fire.
TRUNCATE removes all rows from a table. The operation cannot be rolled back and no triggers will be fired. As such, TRUNCATE is faster and doesn't use as much undo space as a DELETE.
DROP command removes a table from the database. All the tables' rows, indexes and privileges will also be removed. No DML triggers will be fired. The operation cannot be rolled back.
DROP and TRUNCATE are DDL commands, whereas DELETE is a DML command. Therefore DELETE operations can be rolled back (undone), while DROP and TRUNCATE operations cannot be rolled back.
DELETE will not free up used space within a table. This means that repeated DELETE commands will severely fragment the table and queries will have to navigate this "free space" in order to retrieve rows.
|How does one eliminate duplicates rows from a table?|
Choose one of the following queries to identify or remove duplicate rows from a table leaving only unique records in the table:
Delete from table_name where rowid not in (select max(rowid) from table group by duplicate_values_field_name);
|What the difference between UNION and UNIONALL?|
|Union will remove the duplicate rows from the result set while Union all doesn't.|
|How to Change a SQL prompt name?|
|SQL> set sqlprompt "oracle >" oracle >|
|Find out nth highest salary from emp table?|
|SELECT DISTINCT (a.sal) FROM EMP A WHERE &N = (SELECT COUNT (DISTINCT (b.sal)) FROM EMP B WHERE a.sal<=b.sal);|
|What is the difference between VARCHAR, VARCHAR2 and CHAR data types?|
CHAR should be used for storing fixed length character strings. String values will be space/blank padded before stored on disk. If this type is used to store variable length strings, it will waste a lot of disk space.
|What is difference between Co-related sub query and nested sub query?|
Correlated sub query runs once for each row selected by the outer query. It contains a reference to a value from the row selected by the outer query.
Select e1.empname, e1.basicsal, e1.deptno from emp e1 where e1.basicsal = (select max (basicsal) from emp e2 where e2.deptno = e1.deptno)
Nested sub query runs only once for the entire nesting (outer) query. It does not contain any reference to the outer query row.
Select empname, basicsal, deptno from emp where (deptno, basicsal) in (select deptno, max (basicsal) from emp group by deptno)
|What are the more common pseudo-columns?|
|its associated with table but its a not a part of the table. for example SYSDATE, USER, UID, CURVAL, NEXTVAL, ROWID, ROWNUM|
|What is the difference between group by and order by?|
|Group by controls the presentation of the rows, Order by controls the presentation of the columns.|
|What keyword does an SQL SELECT statement use for a string search?|
|The LIKE keyword used for string searches. The % sign is used as a wildcard and _ for single.|
|What are various constraints / Integrity Constraints used in SQL?|
Data integrity allows defining certain data quality requirements that the data in the database needs to meet.
|Height and Distance|
An aeroplane flying at a height of 300 m above the ground passes vertically above another plane at an instant when the angles of elevation of the two planes from the same point on the ground are 60º and 45º respectively. What is the height of the lower plane from the ground?
From the top of a building 90 m high, the angles of depression of the top and the bottom of a tree are 30º and 45º respectively. What is the height of the tree?
What is the value of sinx √( 1 /1+cosx + 1 /1-cosx ) ?
What is cos4 A - sin4 A / cos2 A - sin2 A equal to?
If 7sin2 x +3cos2 x = 4, 0 < x < 90º ,then what is the value of tan x?
If x = a cosθ + b sinθ and y = a sinθ - b cosθ then what is x2 + y2 equal to?
The mean of 5 numbers is 15. If one more number is included, the mean of the 6 numbers becomes 17. What is the included number?
The mean marks obtained by 300 students in a subject are 60. The mean of top 100 students was found to be 80 and the mean of last 100 students was found to be 50. The mean marks of the remaining 100 students are?
In an asymmetrical distribution, of the mean and median of the distribution are 270 and 220 respectively, then the mode of the data is?
Let a, b, c, d, e, f, g be consecutive even numbers and j, k, l, m, n be consecutive odd numbers. What is the average of all the numbers?
|Alligation or Mixture|
25 kg of alloy X is mixed with 125 kg of alloy Y. If the amount of lead and tin in the alloy X is the ratio 1 : 2 and the amount of lead and tin in the alloy Y is in the ratio 2 : 3, then what is the ratio of lead to tin in the mixture?
The ratio of two numbers is 1 : 5 and their product is 320. What is the difference between the square of these two numbers?
What is the value of cot 4π/3 ?
Article-24 of the Indian Constitution ‘Prohibition of employment of children in factories, etc’ deals with?
Article-134A of the Indian Constitution ‘Certificate for appeal to the Supreme Court’ deals with?
Who invented Aspirin?
A larger force on a rotating body results in larger?
What is the unit of the physical quantity, magnetic flux density?
Institute of Banking Personnel Selection (IBPS) - 8400 Posts - 04/07/2019 Last date
South Indian Bank Recruitment 2019 - 545 Posts - 30/06/2019 Last date
IDBI Bank - 600 Posts - 03/07/2019 Last date
Central Railway - 2167 Posts - 12/07/2019 Last date
MECON Limited - 205 Posts - 20/06/2019 Last date
UPSC CDS II - 417 Posts - 08/07/2019 Last date
EPFO Assistant - 280 Posts - 25/06/2019 Last date
Border Roads Organisation (BRO) - 778 Posts - 14/07/2019 Last date
Defence Research and Development Organisation (DRDO) - 351 Posts - 26/06/2019 Last date
IOCL Technician Apprentice - 64 Posts - 24/06/2019 Last date