Quick Links

Typical Interview Questions for Software Testing Typical Interview Questions for JAVA-J2EE
Typical Interview Questions for Hadoop - Bigdata Typical SQL Interview Questions for Software Testing

Typical Interview Questions

Typical Interview Questions for Software Testing
1. What is the difference between white box, black box, and gray box testing?

Black box testing is a testing strategy based solely on requirements and specifications. Black box testing requires no knowledge of internal paths, structures, or implementation of the software being tested. White box testing is a testing strategy based on internal paths, code structures, and implementation of the software being tested. White box testing generally requires detailed programming skills. There is one more type of testing called gray box testing. In this we look into the "box" being tested just long enough to understand how it has been implemented. Then we close up the box and use our knowledge to choose more effective black box tests.

2. What is the difference between the QA and software testing?

QA is more focused on managing the product life cycle and verifying that the software meets the defined quality standards or customer agreements. Testing, on the other hand, may keep an eye on the processes and often owns them, but is far more concerned with finding ways to break the software.

3. What is bug leakage and bug release?

A bug leakage results when a bug is detected which should have been detected in earlier builds/versions of the application. A bug release is when a particular version of s/w is released with a set of known bug(s)/defect(s). These bugs are usually low severity and/or low priority bugs.

4. What Test Techniques are there and what is their purpose?

Test Techniques are primarily used for two purposes: a) To help identify defects, b) To reduce the number of test cases. Equivalence partitioning is mainly used to reduce number of test cases by identifying different sets of data that are not the same and only executing one test from each set of data Boundary Value Analysis is used to check the behaviour of the system at the boundaries of allowed data. State Transition Testing is used to validate allowed and disallowed states and transitions from one state to another by various input data.

5. What is Testware?

Testware is the subset of software, which helps in performing the testing of application. It is a term given to the combination of software application and utilities which is required for testing a software package.

6. WWhich is the best testing model?

In real projects, tailored models are proven to be the best, because they share features from The Waterfall, Iterative, Evolutionary models, etc., and can fit into real life time projects. Tailored models are most productive and beneficial for many organizations. If it's a pure testing project, then the V model is the best.

7. What is the difference between a defect and a failure?

When a defect reaches the end customer it is called a failure and if the defect is detected internally and resolved it's called a defect.

8. What is validation and verification in software testing?

In verification, all the key aspects of software developments are taken in concern like code, specifications, requirements and document plans. Verification is done on the basis of four things list of issues, checklist, walkthroughs and inspection meetings. Following verification, validation is done, it involves actual testing, and all the verification aspects are checked thoroughly in validation.

9. How does testing affect risk?

A risk is a condition that can result in a loss. Risk can only be controlled in different scenarios but not eliminated completely. A defect normally converts to a risk.

10. What is Smart identification?

If the recorded description does not enable QTP to identify a specific object then QTP uses "Smart identification" mechanism. It uses the following additional properties to identify the object a) Base Filter Properties (primary) – The set of properties that cannot be changed without changing the object type b) Optional Filter Properties (secondary) – additional properties that help identify the object uniquely.

11. Why should Selenium be selected as a test tool?

Selenium is free and open source have a large user base and helping communities have cross Browser compatibility (Firefox, chrome, Internet Explorer, Safari etc.) have great platform compatibility (Windows, Mac OS, Linux etc.) supports multiple programming languages (Java, C#, Ruby, Python, Pearl etc.) has fresh and regular repository developments supports distributed testing.

12. What are the testing types that can be supported by Selenium?

Selenium supports the following types of testing: Functional Testing Regression Testing.

13. What is Selenese?

Selenese is the language which is used to write test scripts in Selenium IDE.

14. What is Test Harness?

Test Harness is configuring a set of tools and test data to test an application in various conditions, which involves monitoring the output with expected output for correctness. The benefits of Testing Harness are: Productivity increase due to process automation and increase in product quality.

15. What is Difference between QA, QC and testing?

QA: It is process oriented Aim is to prevent defects in an application QC:Set of activities used to evaluate a developed work product It is product oriented. Testing:Executing and verifying application with the intention of finding defects.

16. Is it possible to switch between recording modes during a test creation?

Yes, in the middle of recording, we can switch to Analog/Low-level mode, finish the task required and go back to normal recording. The switch to Analog mode is available only during recording and not during editing.

17. What is Smart identification?

If the recorded description does not enable QTP to identify a specific object then QTP uses "Smart identification" mechanism. It uses the following additional properties to identify the object a) Base Filter Properties (primary) – The set of properties that cannot be changed without changing the object type b) Optional Filter Properties (secondary) – additional properties that help identify the object uniquely.

18. What is the difference between QTP and Selenium?

QTP is not open source tool while Selenium is open source tool. We can use QTP to test different kinds of applications like web, .net, java, mainframe, peoplesoft etc. But Selenium is used only for Web application testing. QTP supports only vb script as language but we can develop selenium scripts using JAVA, .Net, Ruby, Perl etc.

19. What is the selenium's recording language?

QTP is not open source tool while Selenium is open source tool. We can use QTP to test different kinds of applications like web, .net, java, mainframe, peoplesoft etc. But Selenium is used only for Web application testing. QTP supports only vb script as language but we can develop selenium scripts using JAVA, .Net, Ruby, Perl etc.

20. What are the verification points available in Selenium?

There are largely three types of verification points available with Selenium – Check for page title Check for certain text Check for certain element (text box, drop down, table etc.).

Typical Interview Questions for JAVA-J2EE
1. What is difference between JDK,JRE and JVM?

JVM - JVM is an acronym for Java Virtual Machine, it is an abstract machine which provides the runtime environment in which java bytecode can be executed. It is a specification. JVMs are available for many hardware and software platforms (so JVM is platform dependent).
JRE - JRE stands for Java Runtime Environment. It is the implementation of JVM.
JDK - JDK is an acronym for Java Development Kit. It physically exists. It contains JRE + development tools.

2. What is JIT compiler?

Just-In-Time(JIT) compiler:It is used to improve the performance. JIT compiles parts of the byte code that have similar functionality at the same time, and hence reduces the amount of time needed for compilation.Here the term "compiler" refers to a translator from the instruction set of a Java virtual machine (JVM) to the instruction set of a specific CPU.

3. What is difference between object oriented programming language and object based programming language?

Object based programming languages follow all the features of OOPs except Inheritance. Examples of object based programming languages are JavaScript, VBScript etc.

4. Why Java main method is static?

Because object is not required to call static method if it were non-static method, jvm create object first then call main() method that will lead the problem of extra memory allocation.

5. Which class is the superclass for every class?

Object class.

6. Why Java does not support pointers?

Pointer is a variable that refers to the memory address. They are not used in java because they are unsafe(unsecured) and complex to understand.

7. What is the difference between static binding and dynamic binding?

In case of static binding type of object is determined at compile time whereas in dynamic binding type of object is determined at runtime.

8. What is the base class for Error and Exception?

Throwable.

9. What are JSP actions?

JSP actions use constructs in XML syntax to control the behavior of the servlet engine. You can dynamically insert a file, reuse JavaBeans components, forward the user to another page, or generate HTML for the Java plugin.

110. What is difference between GET and POST method in HTTP protocol?

The GET method sends the encoded user information appended to the page request. The page and the encoded information are separated by the ? Character. The POST method packages the information in exactly the same way as GET methods, but instead of sending it as a text string after a ? in the URL it sends it as a separate message. This message comes to the backend program in the form of the standard input which you can parse and use for your processing.

11. What are differences between Swing and AWT?

1) AWT component are considered to be heavyweight while Swing component are lightweights.
2) Swing has plug-gable look and feel.
3) AWT is platform depended same GUI will look different on different platform while Swing is developed in Java and is platform dependent.

12. Why Java is not supporting multiple inheritance?

Main features of java is that it is very Simple. If multiple inheritance is supported, it would create ambiguity around Diamond problem and it does complicate the design and creates problem during casting, chaining etc. So Java supports multi-inheritance via single inheritance with interfaces to overcome above issues.

13. What is a class and an object?

Class : Template/Blue print of an object. It is a logical construct. Object : It is an instance of a class. Object have states and behaviors. A Physical reality.

14.What is meant by final keyword in Java?

If final variable is used in front of variable, we can't change the value. If the variable is used in front of method, it can't be overridden. If it is used in front of Class, class can't be extended by any other class.

15. Why Java is considered dynamic?

Java is designed to adapt to an evolving environment. Java programs can carry extensive amount of run-time information that can be used to verify and resolve accesses to objects on run-time.

16. Is it possible to override an overloaded method in Java?

Yes. We can override an overloaded method if that method in not a static or final.

17. Is it possible to have multiple public classes in Java?

As per java language specification, there can be only one public class in a file (.java) and file name should be same as public class name. If you want another class accessible in other places, you may create a separate java file.

18. What is the first argument of the String array in main method?

The String array is empty. It does not have any element. This is unlike C/C++ where the first element by default is the program name.

19. Can an application have multiple classes having main method?

Yes it is possible. While starting the application we mention the class name to be run. The JVM will look for the Main method only in the class whose name you have mentioned. Hence there is not conflict amongst the multiple classes having main method.

20. What do you mean by cold backup, hot backup?

This question is not directly related to JDBC but some time asked during JDBC interviews. Cold back is the backup techniques in which backup of files are taken before the database restarted. In hot backup backup of files and table is taken at the same time when database is running. A warm is a recovery technique where all the tables are locked and users cannot access at the time of backing up data.

Typical Interview Questions for Hadoop - Bigdata
1. What is Big Data?

Big data is defined as the voluminous amount of structured, unstructured or semi-structured data that has huge potential for mining but is so large that it cannot be processed using traditional database systems.

2. What do the four V's of Big Data denote?

The four critical features of big data: a) Volume –Scale of data b) Velocity –Analysis of streaming data c) Variety – Different forms of data d) Veracity –Uncertainty of data

3. Differentiate between Structured and Unstructured data.

Data which can be stored in traditional database systems in the form of rows and columns, for example the online purchase transactions can be referred to as Structured Data. Data which can be stored only partially in traditional database systems, for example, data in XML records can be referred to as semi structured data. Unorganized and raw data that cannot be categorized as semi structured or structured data is referred to as unstructured data.

4. What are the main components of a Hadoop Application?

Core components of a Hadoop application are- 1) Hadoop Common 2) HDFS 3) Hadoop MapReduce 4) YARN

5. What is Hadoop streaming?

Hadoop distribution has a generic application programming interface for writing Map and Reduce jobs in any desired programming language like Python, Perl, Ruby, etc. This is referred to as Hadoop Streaming.

6. What is a block and block scanner in HDFS?

Block - The minimum amount of data that can be read or written is generally referred to as a "block" in HDFS. The default size of a block in HDFS is 64MB. Block Scanner - Block Scanner tracks the list of blocks present on a DataNode and verifies them to find any kind of checksum errors.

7. Explain about the indexing process in HDFS.

Indexing process in HDFS depends on the block size. HDFS stores the last part of the data that further points to the address where the next part of data chunk is stored.

8. What happens to a NameNode that has no data?

There does not exist any NameNode without data. If it is a NameNode then it should have some sort of data in it.

9. Explain the difference between HBase and Hive.

HBase and Hive both are completely different hadoop based technologies-Hive is a data warehouse infrastructure on top of Hadoop whereas HBase is a NoSQL key value store that runs on top of Hadoop. Hive helps SQL savvy people to run MapReduce jobs whereas HBase supports 4 primary operations-put, get, scan and delete.

10. Explain the difference between RDBMS data model and HBase data model.

RDBMS is a schema based database whereas HBase is schema less data model. RDBMS does not have support for in-built partitioning whereas in HBase there is automated partitioning. RDBMS stores normalized data whereas HBase stores de-normalized data.

11. What happens when a user submits a Hadoop job when the NameNode is down- does the job get in to hold or does it fail.

The Hadoop job fails when the NameNode is down.

12. How Sqoop can be used in a Java program?

The Sqoop jar in classpath should be included in the java code. After this the method Sqoop.runTool () method must be invoked. The necessary parameters should be created to Sqoop programmatically just like for command line.

Typical SQL Interview Questions for Software Testing
1. Define join in SQL?

Join keyword is used to fetch data from related two or more tables. It returns rows where there is at least one match in both the tables included in join.

2. What is a primary key?

A Primary key is a column whose values uniquely identify every row in a table. Primary key values can never be reused. Primary key values can never be duplicate or NULL.

3. What is NULL in SQL?

A value of NULL is different from an empty or zero value. No two null values are equal. Comparisons between two null values, or between a NULL and any other value, return unknown because the value of each NULL is unknown.

4. What is an identity in SQL?

An identity column in the SQL automatically generates numeric values. A start and increment value can be defined for identity column.

5. Is it possible for a table to have more than one foreign key?

Yes, a table can have many foreign keys and only one primary key.

6. What are the possible values for BOOLEAN data field.

For a BOOLEAN data field two values are possible: -1(true) and 0(false).

7. Explain DML and DDL?

DML stands for Data Manipulation Language. INSERT, UPDATE and DELETE are DML statements. DDL stands for Data Definition Language. CREATE ,ALTER, DROP, RENAME are DDL statements.

8. Difference between TRUNCATE, DELETE and DROP commands?

DELETE removes some or all rows from a table based on the condition. It can be rolled back. TRUNCATE removes ALL rows from a table by de-allocating the memory pages. The operation cannot be rolled back DROP command removes a table from the database completely.

9. What is difference between UNIQUE and PRIMARY KEY constraints?

A table can have only one PRIMARY KEY whereas there can be any number of UNIQUE keys. Primary key cannot contain Null values whereas Unique key can contain Null values.

10. What is the Subquery?

A Subquery is sub set of select statements whose return values are used in filtering conditions of the main query.

11. Explain the difference between Rename and Alias?

Rename is a permanent new name given to a table or column whereas Alias is a temporary name given to a table or column.

12. What is CTE?

A CTE or common table expression is an expression which contains temporary result set which is defined in a SQL statement.

13. What is the difference between sub queries and joins.

Sub Queries : To write sub queries between two or more tables, there is no need to be relation exist among those tables Joins:To write joins between two or more tables, there should be relation exist among those tables.

14. What is the difference between union and union all?

The UNION operator selects only distinct values by default. To allow duplicate values, use UNION ALL.

15. Why can a "group by" or "order by" clause be expensive (time consuming) to process?

Processing of "group by" or "order by" clause often requires creation of Temporary tables to process the results of the query, which depending of the result set can be very expensive.

16. How can duplicating records be avoided in a query?

By using DISTINCT keyword duplicating records in a query can be avoided.

17. What is difference between Having clause and Where clause?

Both specify a search condition but Having clause is used only with the SELECT statement and typically used with GROUP BY clause.If GROUP BY clause is not used then Having behaves like WHERE clause only.

18. Can a primary key contain more than one columns?

Yes. Primary key created on more than one column is called composite primary key.

19. Define COMMIT?

COMMIT saves all changes made by DML statements. Once COMMIT is done, the changes cannot be rolled back.

20. List the various privileges that a user can grant to another user?

SELECT, CONNECT, RESOURCES.

21. Difference Between Primary Key and Unique Key In Sql?

Although Both PRIMARY KEY and UNIQUE KEY enforces the Uniqueness of the values , they differ in following ways.
1. Primary Key doesn't allow Null values whereas Unique Key Allows Null value. But only one Null value.
2. A table can have only one PRIMARY KEY Column[s] whereas A table can have more than one UNIQUE Key Column[s].