Traditional Culture Encyclopedia - Traditional customs - The difference between database and data warehouse

The difference between database and data warehouse

The database is transaction-oriented and the data warehouse is subject-oriented. Databases generally store online transaction data, while data warehouses generally store historical data.

"Time-related": When saving information in the database, it is not emphasized that there must be time information. The data warehouse is different, because of the need of decision-making, the data in the data warehouse should be marked with time attribute. Time attribute is very important in decision making. The same customer bought a total of nine cars, one bought nine cars in the last three months, and the other didn't buy a car in the last year, which has different significance to decision makers. ?

"Unmodifiable": The data in the data warehouse is not the latest, but comes from other data sources. Data warehouse reflects historical information, rather than daily transaction data processed by many databases (some databases, such as telecom billing database, even process real-time information). Therefore, the data in the data warehouse is rarely or never modified; Of course, adding data to the data warehouse is allowed. ?

The emergence of data warehouse is not to replace database. The purpose of data warehouse is to further mine data resources to meet the needs of decision-making under the condition that a large number of databases already exist. It is by no means a so-called "large database".

At present, most data warehouses are managed by relational database management system. It can be said that database and data warehouse complement each other and have their own advantages.