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
How to avoid using cursors? What to use instead of cursor and in what cases to do so?
what is the difference between primary key and unique key? : Sql dba
What are sql ddl commands?
What is not null in sql?
Is there any restriction on the use of union in embedded sql?
what is a view? : Sql dba
Why are aggregate functions called so?
Why left join is used in sql?
How do I save the results of sql query in a file?
how to shutdown mysql server? : Sql dba
what are the 'mysql' command line arguments? : Sql dba
How do we use distinct statement? What is its use?
What is %type in sql?
How many postgresql users are there, worldwide?
Why do we use sqlite?