What is temporal database? Explain the terms date, time, timestamp, interval and period.

 Temporal Database Concepts.

  • A temporal database stores data relating to time instances. It offers temporal data types and stores information relating to past, present, and future times.


  • A Temporal Database is a database with built-in support for handling time-sensitive data. Usually, databases store information only about the current state, and not about past states. 
  • For example in an employee database, if the address or salary of a particular person changes, the database gets updated, and the old value is no longer there. However, for many applications, it is important to maintain the past or historical values and the time at which the data was updated. That is, the knowledge of evolution is required. That is where temporal databases are useful.
  •  It stores information about the past, present, and future. Any data that is time-dependent is called temporal data and these are stored in temporal databases.
  • Temporal Databases store information about states of the real world across time. Temporal Database is a database with built-in support for handling data involving time. It stores information relating to past, present, and future times of all events.

DATE: The type date contains four digits for the year (1–9999), two digits for the month (1–12), and two digits for the date (1–31) and provided specifying Year, Month, and Day as YYYY-MM-DD), 

 TIME: The type time contains two digits for the hour, two digits for the minute, and two digits for the second, plus optional fractional digits and provided specifying Hour, Minute, and Second as HH:MM: SS,

TIMESTAMP: The type timestamp contains the fields of date and time, with six fractional digits for the second's field. (specifying a Date/Time combination, with options for including sub-second divisions if they are needed), 

Since different places in the world have different local times, there is often a need for specifying the time zone along with the time.

 The Universal Coordinated Time (UTC) is a standard reference point for specifying time, with local times defined as offsets from UTC. (The standard abbreviation is UTC, rather than UCT, since it is an abbreviation of “Universal Coordinated Time” written in French as universel temps coordonne ´.)

INTERVAL (a relative time duration, such as 10 days or 250 minutes),

PERIOD (an anchored time duration with a fixed starting point, such as the 10-day period from January 1, 2009, to January 10, 2009, inclusive). 10Time Representation in SQL

Comments

Popular posts from this blog

Suppose that a data warehouse for Big-University consists of the following four dimensions: student, course, semester, and instructor, and two measures count and avg_grade. When at the lowest conceptual level (e.g., for a given student, course, semester, and instructor combination), the avg_grade measure stores the actual course grade of the student. At higher conceptual levels, avg_grade stores the average grade for the given combination. a) Draw a snowflake schema diagram for the data warehouse. b) Starting with the base cuboid [student, course, semester, instructor], what specific OLAP operations (e.g., roll-up from semester to year) should one perform in order to list the average grade of CS courses for each BigUniversity student. c) If each dimension has five levels (including all), such as “student < major < status < university < all”, how many cuboids will this cube contain (including the base and apex cuboids)?

Suppose that a data warehouse consists of the four dimensions; date, spectator, location, and game, and the two measures, count and charge, where charge is the fee that a spectator pays when watching a game on a given date. Spectators may be students, adults, or seniors, with each category having its own charge rate. a) Draw a star schema diagram for the data b) Starting with the base cuboid [date; spectator; location; game], what specific OLAP operations should perform in order to list the total charge paid by student spectators at GM Place in 2004?

Explain network topology .Explain tis types with its advantages and disadvantges.