Home > Computer Tutorials > Computer Knowledge > What are the common database functions?

What are the common database functions?

王林
Release: 2024-01-09 11:41:53
forward
1180 people have browsed it

What are the database functions? anyone there

There is Funciton, which is a function

There is Procedure, which is a stored procedure

There is a Package, which is a code package (including head and body, which can be understood as a package that defines multiple stored procedures or functions)

There are Types, that is, custom data types

There are Triggers, that is, triggers

There are Jobs, that is, database jobs (periodic execution)

There is Table, which is a table (tables include ordinary tables, temporary tables, and partition tables)

There is Index, which is the index

There is Constraint, which is a constraint (that is, what constraints must be met for a certain column in a table)

There is a View, that is, a view

There is Materialized View, called "materialized view", which is a bit complicated.

There is Sequence, called sequence number.

There is User, called User

There is Profile, called user properties file (used to limit the database resources occupied by each user)

There are Synonyms, called "synonyms" (used to conveniently access objects under other users)

There is a Database link called "link database" (used to access Oracle databases on other machines)

There is TableSpace called table space (used to store table data)

There is CURSOR called cursor, which is used in stored procedures to traverse data.

Database function count

Count function

Calculate the number of records returned from the query.

grammar

Count(expr)

Where expr represents a string expression that either identifies a field that contains the data to be calculated; or is an expression that uses the data in this field to perform the calculation. The operand in expr may include a table field name, a constant, or a function (which may be intrinsic or user-defined, but is not an SQL aggregate function). You can calculate any kind of data, including text data.

illustrate

You can use Count to calculate the number of records for the next level query. For example, you can use Count to count the number of orders for goods shipped to a specified country.

Although expr can perform calculations on a field, Count simply counts the number of records. It doesn't matter what value is saved in the record.

The Count function does not count records with Null fields unless expr is the asterisk (*) wildcard character. If asterisk is used, Count will count the total of all records, including records with Null fields. Count(*) is much faster than Count([Column Name]).

The above is the detailed content of What are the common database functions?. For more information, please follow other related articles on the PHP Chinese website!

source:docexcel.net
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template