SQL : PostgreSQL

  Aggregate Functions Like most other relational database products,  PostgreSQL  supports  aggregate functions . An aggregate function computes a single result from multiple input rows. For example, there are aggregates to compute the  count ,  sum ,  avg  (average),  max  (maximum) and  min  (minimum) over a set of rows. As an example, we can find the highest low-temperature reading anywhere with: SELECT max(temp_lo) FROM weather; max ----- 46 (1 row) If we wanted to know what city (or cities) that reading occurred in, we might try: SELECT city FROM weather WHERE temp_lo = max(temp_lo); WRONG but this will not work since the aggregate  max  cannot be used in the  WHERE  clause. (This restriction exists because the  WHERE  clause determines which rows will be included in the aggregate calculation; so obviously it has to be evaluated before aggregate functions are computed.) However, as is o...

Database vs. spreadsheet: advantages and disadvantages

 Database vs. spreadsheet: advantages and disadvantages

Databases

AdvantagesDisadvantages
Large volume of data
Consistency and integrity of data
Data redundancy control
Shareability and multi-access to data 
Data security
Filtering and querying
Scalability
Backup and recovery of data
Steep learning curve
Cost of setup and maintenance
Cost of staff training
Cost of converting data files into a database
Cost of querying

Spreadsheets

AdvantagesDisadvantages
Free or low cost
Shallow to medium learning curve
Data formatting and visualization
Calculation ability
Preset function for data manipulation
Flexibility
Limited shareability
Security
Poor performance with large volumes of data
Scalability


DatabaseSpreadsheet
System that stores data arranged in tablesWhat it isFile that contains tabular data
Storage of large volumes of dataWhat is it for?Different data manipulations such as reporting, analysis, etc.
Requires technological expertiseLearning curveUser friendly
Limited by the number of files with tabular dataHow much can it store?Limited by the number of cells 
Advanced querying and filtering options thanks to SQLQueryLimited querying and filtering options
Data is stored and output in tabular formatFormattingMultiple formatting and data visualization features 
Pretty expensive to set up and maintainBudgetFree or low-budget solution
Organizations, departments, companies, and other entities with huge volumes of dataTarget userAccountants, marketers, teachers, small business owners, and many other categories of users

Comments

Popular posts from this blog

SQL : PostgreSQL

Using BigQuery / MySQL / other SQL

The R-versus-Python debate