Filter interviews by
I applied via Walk-in and was interviewed before Aug 2020. There were 4 interview rounds.
Constraints are rules enforced on data in a table, while triggers are actions performed in response to certain events.
Constraints ensure data integrity and consistency, while triggers automate actions based on specific events.
Constraints are defined at the time of table creation, while triggers are created separately.
Constraints can be used to enforce rules such as unique values, primary keys, and foreign keys, while t...
Top trending discussions
I applied via Referral and was interviewed before Jun 2023. There was 1 interview round.
Oracle pl sql developer
Create a function based on shared logic
Identify common logic that can be reused in multiple functions
Create a separate function to encapsulate the shared logic
Call the shared function from other functions where the logic is needed
I applied via Approached by Company and was interviewed in Sep 2023. There were 3 interview rounds.
Window functions in SQL are used to perform calculations across a set of table rows related to the current row.
Window functions are used to calculate values based on a set of rows related to the current row.
They allow you to perform calculations without grouping the rows into a single output row.
Examples of window functions include ROW_NUMBER(), RANK(), and LAG().
Packages in PL/SQL are used to group related procedures, functions, variables, and other PL/SQL constructs together for better organization and security.
Packages help in modularizing code for easier maintenance and debugging
They provide encapsulation and hide implementation details
Packages can contain multiple procedures, functions, variables, cursors, and exceptions
They improve performance by reducing network traffic
E...
Joins in SQL are used to combine rows from two or more tables based on a related column between them.
Joins are used to retrieve data from multiple tables based on a related column.
Common types of joins include INNER JOIN, LEFT JOIN, RIGHT JOIN, and FULL JOIN.
Example: SELECT * FROM table1 INNER JOIN table2 ON table1.column = table2.column;
Some built-in functions in SQL include AVG, COUNT, MAX, MIN, SUM, and CONCAT.
AVG: Calculates the average value of a numeric column
COUNT: Counts the number of rows in a result set
MAX: Returns the maximum value in a column
MIN: Returns the minimum value in a column
SUM: Calculates the sum of values in a column
CONCAT: Concatenates two or more strings together
Types of cursors in database management systems include implicit, explicit, and parameterized cursors.
Implicit cursors are automatically created by the database when a SQL statement is executed.
Explicit cursors are defined by the programmer and give more control over the result set.
Parameterized cursors allow for dynamic SQL statements with parameters.
Examples: SELECT statement using implicit cursor, DECLARE, OPEN, FET...
Procedures are used to perform an action, while functions return a value.
Procedures do not return a value, while functions do.
Functions can be used in SQL queries, while procedures cannot.
Functions can be called from within SQL statements, while procedures cannot.
Procedures can have OUT parameters to return multiple values, while functions can only return a single value.
Use a subquery to find the third highest salary in a table.
Use the RANK() function to assign a rank to each salary in descending order.
Filter the results to only include rows with a rank of 3.
Consider handling ties in salaries appropriately.
A package is a collection of related procedures, functions, variables, and other PL/SQL constructs.
Packages help organize and encapsulate code for easier maintenance and reuse.
They can contain both public and private elements.
Packages can be used to group related functionality together, improving code modularity.
Example: CREATE PACKAGE my_package AS ... END my_package;
Resolved a critical bug causing data loss and implemented a new feature for better user experience.
Identified root cause of data loss bug by analyzing database queries and logs
Collaborated with cross-functional teams to prioritize and implement a fix
Designed and implemented a new feature based on user feedback to enhance usability
Different types of indexes include B-tree, Bitmap, Function-based, and Reverse key indexes.
B-tree indexes are the most common type and are suitable for most indexing needs.
Bitmap indexes are used for columns with low cardinality, such as gender or status columns.
Function-based indexes are created based on expressions or functions applied to columns.
Reverse key indexes store keys in reverse order to reduce contention in
Analytical functions in SQL are used to perform calculations across a set of rows related to the current row.
Analytical functions operate on a group of rows and return a single result for each row.
They can be used to calculate running totals, moving averages, rank, percentiles, etc.
Examples include ROW_NUMBER(), RANK(), DENSE_RANK(), SUM() OVER(), AVG() OVER().
Aggregate functions in SQL are functions that operate on a set of values and return a single value as output.
Aggregate functions include functions like SUM, AVG, COUNT, MIN, and MAX.
They are used with the GROUP BY clause to perform calculations on groups of rows.
Examples: SELECT SUM(salary) FROM employees; SELECT AVG(age) FROM students GROUP BY class;
I identified and optimized slow-performing SQL queries by analyzing execution plans and indexing strategies.
Identified slow-performing SQL queries using tools like Oracle SQL Developer or TOAD.
Analyzed execution plans to understand query performance bottlenecks.
Optimized queries by rewriting SQL code, adding indexes, or restructuring data.
Used tools like Explain Plan or SQL Tuning Advisor to improve query performance.
R...
Data modeling is the process of creating a visual representation of data structures and relationships within a database.
Data modeling helps in organizing and understanding complex data systems.
It involves identifying entities, attributes, and relationships between them.
Examples include ER diagrams, UML diagrams, and relational data models.
I conducted thorough analysis by reviewing code, logs, and discussing with team members.
Reviewed code to identify potential issues
Analyzed logs for error messages and patterns
Discussed with team members to gather insights and perspectives
Used debugging tools to trace the root cause
A trigger in database management is a special type of stored procedure that is automatically executed when certain events occur in a database.
Triggers can be used to enforce business rules, maintain referential integrity, and automate repetitive tasks.
There are two main types of triggers: row-level triggers and statement-level triggers.
Row-level triggers are fired for each row affected by a triggering statement, while ...
I applied via Naukri.com and was interviewed in Oct 2024. There was 1 interview round.
Developed a PL/SQL project for managing inventory and sales data in a retail store.
Designed database tables to store product information, sales transactions, and customer details.
Implemented PL/SQL procedures and functions for adding, updating, and querying data.
Created triggers to enforce business rules and maintain data integrity.
Developed reports using PL/SQL queries to analyze sales performance and inventory levels
I work on performance optimization by analyzing query execution plans, indexing, and code refactoring.
Analyzing query execution plans to identify bottlenecks
Creating appropriate indexes to improve query performance
Refactoring code to optimize resource usage
Using tools like Explain Plan and SQL Tuning Advisor
Factorial of a number is the product of all positive integers up to that number.
To calculate factorial of a number, multiply all positive integers up to that number.
Factorial of 0 is 1.
Example: Factorial of 5 is 5*4*3*2*1 = 120.
Modelling of schema involves designing the structure of a database to organize and represent data.
Identify entities and their relationships
Define attributes for each entity
Establish primary and foreign keys
Normalize the schema to reduce redundancy
Consider performance and scalability
I applied via Naukri.com and was interviewed in Feb 2022. There were 3 interview rounds.
Temp table is a table created temporarily in memory. Temp variable is a variable that holds temporary data.
Temp table is used to store data temporarily during a session
Temp variable is used to hold temporary data that is not needed after a certain point
Temp table and variable are created using the 'CREATE GLOBAL TEMPORARY' and 'DECLARE' statements respectively
Example: CREATE GLOBAL TEMPORARY TABLE temp_table (id NUMBER...
A mutating table or mutating trigger occurs when a trigger tries to update a table that is currently being modified.
Mutating table occurs when a trigger references the table that is being modified.
It can happen when a trigger is fired by an INSERT, UPDATE, or DELETE statement on the table.
This can lead to unpredictable results or errors, such as ORA-04091: table is mutating, trigger/function may not see it.
To avoid mut...
Autonomous transaction is a separate transaction initiated by a parent transaction.
It allows a subtransaction to commit or rollback independently of the parent transaction.
It is useful for logging or auditing purposes.
It can be created using the PRAGMA AUTONOMOUS_TRANSACTION statement.
Example: A parent transaction updates a table, while an autonomous transaction logs the changes made.
Example: An autonomous transaction ...
Cursors are used to retrieve and manipulate data from a database in PL/SQL.
Cursors are like pointers to a result set, allowing us to fetch and process rows one by one.
There are two types of cursors: implicit and explicit.
Implicit cursors are automatically created by Oracle when executing a SQL statement.
Explicit cursors are declared and used by the programmer.
Explicit cursors provide more control and flexibility compar...
Triggers are database objects that automatically execute in response to certain events.
Triggers can be used to enforce business rules, audit data changes, and maintain referential integrity.
They can be defined to execute before or after an event, such as a row being inserted, updated, or deleted.
Triggers can also be nested, meaning one trigger can execute another trigger.
Examples of triggers include automatically updat...
Truncate removes all data, delete removes selected data.
Truncate is faster than delete as it doesn't log individual row deletions.
Truncate cannot be rolled back, delete can be.
Truncate resets identity columns, delete doesn't.
Truncate doesn't fire triggers, delete does.
Truncate is a DDL operation, delete is a DML operation.
A procedure in PL/SQL is a named block of code that can be called and executed multiple times.
Syntax: CREATE [OR REPLACE] PROCEDURE procedure_name [(parameter1 [mode1] datatype1 [, parameter2 [mode2] datatype2]...)] IS
Difference between procedure and function: Procedures do not return a value, while functions return a value.
Procedures are used to perform an action, while functions are used to calculate and return a val...
To find if two tables have similar data, compare the records in both tables using a join or a subquery.
Use a join operation to compare the records in both tables based on a common column.
If the tables have a primary key, you can join them on that key to check for similar data.
Alternatively, you can use a subquery to compare the data in both tables and check for matching records.
Consider using the MINUS operator to find...
HAVING is used to filter groups while GROUP BY is used to group rows based on a column.
HAVING is used with GROUP BY to filter groups based on a condition
GROUP BY is used to group rows based on a column
HAVING is used after GROUP BY in a query
GROUP BY is used before HAVING in a query
Example: SELECT department, AVG(salary) FROM employees GROUP BY department HAVING AVG(salary) > 5000;
Software Developer
95
salaries
| ₹0 L/yr - ₹0 L/yr |
Software Support Executive
15
salaries
| ₹0 L/yr - ₹0 L/yr |
Java Developer
12
salaries
| ₹0 L/yr - ₹0 L/yr |
Senior Software Developer
10
salaries
| ₹0 L/yr - ₹0 L/yr |
System Administrator
10
salaries
| ₹0 L/yr - ₹0 L/yr |
Infosys
TCS
Wipro
HCLTech