SunQuest
 
       Administration
  Home arrow Administration arrow Page 7 - Database Essentials
Dev Shed Forums 
Administration  
AJAX  
Apache  
BrainDump  
DHTML  
Flash  
Java  
JavaScript  
Multimedia  
MySQL  
Oracle  
Perl  
PHP  
Practices  
Python  
Reviews  
Security  
Style-Sheets  
Web Services  
XML  
Zend  
Zope  
Forums Sitemap 
IBM® developerWorks 
Sun Developer Network 
Dedicated Servers 
E-Commerce Hosting 
Linux Web Hosting 
Managed Hosting 
Small Business Hosting 
Actuate Whitepapers 
VeriSign Whitepapers 
VPS Hosting 
Weekly Newsletter

 
Developer Updates  
Free Website Content 
 RSS  Articles
 RSS  Forums
 RSS  All Feeds
Write For Us Get Paid 
Request Media Kit
Contact Us 
Site Map 
Privacy Policy 
Support 
 USERNAME
 
 PASSWORD
 
 
  >>> SIGN UP!  
  Lost Password? 
ADMINISTRATION

Database Essentials
By: icarus, (c) Melonfire
  • Search For More Articles!
  • Disclaimer
  • Author Terms
  • Rating: 4 stars4 stars4 stars4 stars4 stars / 7
    2001-02-26

    Table of Contents:
  • Database Essentials
  • The Customer Is King
  • Relationships
  • Invasion Of The Foreign Keys
  • Looking Up The Index
  • Joined At The Hip
  • Room With A View
  • Pulling The Trigger
  • So That's Where All My Money Went...

  • Rate this Article: Poor Best 
      ADD THIS ARTICLE TO:
      Del.ici.ous Digg
      Blink Simpy
      Google Spurl
      Y! MyWeb Furl
    Email Me Similar Content When Posted
    Add Developer Shed Article Feed To Your Site
    Email Article To Friend
    Print Version Of Article
    PDF Version Of Article
     
     
    ADVERTISEMENT

    Stay one step ahead of the competition. Evaluate and give feedback on some of the hottest web development tools on the market today. Make your opinion heard! Click Here

    Database Essentials - Room With A View


    (Page 7 of 9 )

    Closely related to joins and subqueries is the concept of "views", which offers yet another way of displaying specific data slices.

    Unlike joins and subqueries, which are based on actual database tables, a view is a table derived from the content present in other tables. Think of a view as a virtual table, one which contains values from other tables (these values selected on the basis of user-defined rules), and which can be manipulated in exactly the same way as a regular table.

    Since a view is based on the data present in "real" tables, the data you see in the view changes as the data in the base tables changes. A view also provides a simple way to restrict access to sensitive fields in a database table, allowing you to exclude certain fields from display, and can be used in combination with joins to discover new relationships between different data items.

    For example, the following command creates a view named "highRollers", which only contains a list of accounts with a balance in excess of $1000.00

    sql> CREATE VIEW highRollers AS SELECT CustomerID FROM balance WHERE AccountBalance >=1000.00;

    And now, when you display the contents of the "highRollers" view, this is what you'll see:

    sql> SELECT * FROM highRollers; +------------+ | CustomerID | +------------+ | 734736 | | 234673 | +------------+

    Any changes made to the "customers" table will be immediately reflected in the view; similarly, changes made to the data in the view will be executed on the underlying table.

    More Administration Articles
    More By icarus, (c) Melonfire


     

       

    ADMINISTRATION ARTICLES

    - Network Administration with FreeBSD 7
    - Components of an Information Architecture
    - The Anatomy of an Information Architecture
    - Configuring Load-Balanced Clusters
    - Load-Balanced Clusters
    - UNIX Time Format Demystified
    - Making Changes in the CVS
    - Building Your First CVS Repository
    - CVS Quickstart Guide
    - Authorizing Users in Samba
    - Handling User Accounts in Samba
    - Authentication in Samba
    - Accounts, Authentication, and Authorization
    - Advanced Concepts on Dealing with Files and ...
    - Dealing with Files and Filesystems





    © 2003-2008 by Developer Shed. All rights reserved. DS Cluster 3 hosted by Hostway