how do you restrict number of rows for a particular value
in a column.For example:there is a table called
fruits,having apples,bananas ,papayas.I dont want to have
more than 100 apples in that table ,so how can u restrict
number of rows for apple to hundred?

Answer Posted / suresh babu

create check constraint is the best way to restrict the
limited number of entries,because the constraint won't take
a separate space,but Trigger required separate memory
space.perhaps the trigger got error,it would affect all
entries in table.

Is This Answer Correct ?    2 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Explain cursor types?

757


what are the advantages and disadvantages of views in a database? : Sql dba

777


What is the current version of postgresql?

749


What are the main features of cursor?

839


What is compilation error in pl sql?

713


what are the nonstandard string types? : Sql dba

816


How can we solve sql error: ora-00904: invalid identifier?

898


How to fetch alternate records from a table?

890


What is crud stand for?

755


What are literals in sql server?

749


How many sql databases can you have on one server?

772


What is view explain with example?

698


List the different type of joins?

761


What do we need to check in database testing?

738


what are all types of user defined functions? : Sql dba

773