Folks,
Keep following points in mind when doing database testing. hope this will helpfull.
Keep following points in mind when doing database testing. hope this will helpfull.
- Field size validation
- Check constraints
- Indexes are done or not (for performance related issues)
- Store procedure
- Field size defined in the application is matching with that in database
- Events like insert, update, delete
- Data integrity, data validity and data manipulation and update
Can you elaborate more on each topic?
ReplyDelete
ReplyDeletePlease check below for DB testing
Field Validations
1. Is ‘Allow Null’ condition removed at database level for mandatory fields on UI
2. Is ‘Null’ as value not allowed in database
3. Is Field not mandatory while allowing NULL values on that field
4. Is the Field length specified on UI same as field length specified in table to store same element from UI into database.
5. Is the length of each field of sufficient size
6. Is the Data type of each field is as per specifications
7. Does all similar fields have same names across tables
8. Is there any computed field in the Database
Check Constraints
1. Is required Primary key constraints are created on the Tables
2. Is required Foreign key constraints are created on the Tables
3. Are valid references are done for foreign key
4. Is Data type of Primary key and the corresponding foreign key same in two tables
5. Does Primary key’s ‘Allow Null’ condition not allowed
6. Does Foreign key contains only not NULL values
Indexes
1. Are required Clustered indexes created on the tables
2. Are required Non Clustered indexes created on the tables
Stored Procedures/ Functions
1. Is proper coding conventions followed
2. Is proper handling done for exceptions
3. Are all conditions/loops covered by input data
4. Does TRIM is applied when data is fetched from Database
5. Does executing the Stored Procedure manually gives the correct result
6. Does executing the Stored Procedure manually updates the table fields as expected
7. Does execution of the Stored Procedure fires the required triggers
8. Are all the Stored Procedures/Functions used by the application (i.e. no unused stored procedures present)
9. Does Stored procedures have ‘Allow Null’ condition checked at data base level
10. Are all the Stored Procedures and Functions successfully executed when Database is blank
Data Integrity
1. Is the complete data in the database is stored in tables
2. Is the data well logically organized
3. Is the data stored in tables is correct
4. Is there any unnecessary data present
5. Is the data present in the correct table
6. Is the data present in correct field within the table
7. Is the data stored correct with respect to Front End updated data
8. Is LTRIM and RTRIM performed on data before inserting data into database
Yup absolutely true. Thanks for adding value to it
Deletecould anyone say how do you write test case for this scenario
ReplyDeleteaaa
enter query
ok ->
Exectue query
view as ->
result