序列可以使用及不能使用的场合

可以在下列场合中使用:
1. VALUES clause of INSERT statements
2. The SELECT list of a SELECT statement
3. The SET clause of an UPDATE statement

而不能在下列场合使用:
■ A subquery
■ A view query or materialized view query
■ A SELECT statement with the DISTINCT operator
■ A SELECT statement with a GROUP BY or ORDER BY clause
■ A SELECT statement that is combined with another SELECT statement with the UNION, INTERSECT, or MINUS set operator
■ The WHERE clause of a SELECT statement
■ DEFAULT value of a column in a CREATE TABLE or ALTER TABLE statement
■ The condition of a CHECK constraint

更多详细内容请参阅:
http://chenzs19850728.blog.163.com/blog/static/762960920083710532829/

[@more@]
请使用浏览器的分享功能分享到微信等