1 / 9

Relational Database Concept and technology

A Relational Database Management System (RDBMS) is a server that manages data for you. The data is structured into tables, where each table has some number of columns, each of which has a name and a type. For example, to keep track of James Bond movies, we might have a &#8220;movies&#8221; table that records the title (a string), year of release (a number), and the actor who played Bond in each movie (an index into a table of Bond actors).<br>https://www.ducatindia.com/phptraining/

ducathub
Download Presentation

Relational Database Concept and technology

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. WELCOME TO DUCAT INDIA Relational Database Concept and technology CONTACT US:- 70-70-90-50-90 info@ducatindia.com

  2. Relational Database Concept and technology A Relational Database Management System (RDBMS) is a server that manages data for you. The data is structured into tables, where each table has some number of columns, each of which has a name and a type. For example, to keep track of James Bond movies, we might have a “movies” table that records the title (a string), year of release (a number), and the actor who played Bond in each movie (an index into a table of Bond actors). Tables are grouped together into databases, so a James Bond database might have tables for movies, actors playing Bond, and villains. An RDBMS usually has its own user system, which controls access rights for databases (e.g., “user Fred can update database Bond”). PHP communicates with relational databases such as MySQL and Oracle using the Structured Query Language (SQL). You can use SQL to create, modify, and query relational databases.

  3. The syntax for SQL is divided into two parts. The first, Data Manipulation Language, or DML, is used to retrieve and modify data in an existing database. DML is remarkably compact, consisting of only four verbs: select, insert, update, and delete. The set of SQL commands, used to create and modify the database structures that hold the data, is known as Data Definition Language, or DDL. The syntax for DDL is not as standardized as that for DML, but as PHP just sends any SQL commands you give it to the database, you can use any SQL commands your database supports. Web Database Design A web database is a wide term for managing data online. A web database gives you the ability to build your own databases/data storage without you being a database guru or even a technical person. Website operators can manage this collection of data and present analytical results based on the data in the Web database application. Databases first appeared in the 1990s, and have been an asset for businesses, allowing the collection of seemingly infinite amounts of data from infinite amounts of customers. Web SQL Database is a web page API for storing data in databases that can be queried using a variant of SQL.Databases are everywhere, including everywhere in the world of web development. Everything from the simplest blogs and directories and to robust user-oriented websites use databases. No matter how complex or simple the website and corresponding database may be though, each takes careful planning in order to run efficiently and also securely.

  4. What Functionality is Needed from the Database? The first method for planning for a database is to simply brainstorm, on paper or otherwise, concerning what the database will need to store, and what the site will need out of it. Try not to think of the individual fields or tables that will be needed at this point – all that specific planning can take place later. The goal is to start with a general and complete view and narrow down. It can often times be more difficult to add in items later, rather than get it right the first time. Think outside the database. Try to think about what the website will need to do. For example, if a membership website is needed, the first instinct may be to begin thinking of all the data each user will need to store. Forget it, that’s for later. Rather, write down that users and their information will need to be stored in the database, and what else? What will those members need to do on the site? Will they make posts, upload files or photos, or send messages? Then the database will need a place for files/photos, posts, and messages. What information will they need to derive from the site? Will they need to search for their favorite recipe, be able to access member-only content, or need to look up products and their recently purchased or viewed products? Then the database will need a place to hold those recipes, a place for content that is defined as members-only or not or hold all products and create a method to link certain products to a specific member.

  5. Determining Tables and Fields The next phase would be to begin determining exactly what tables and fields one would need in the database. This is the core of database design, and the most difficult part. Using correct methods for linking tables together, sorting the data within each table correctly, and grouping it or keeping it separate are all arising problems when it comes to database design. At this point, list out what tables and fields are clear at this point, trying to be as specific as possible. Through the process, items can be rearranged or reorganized to improve the database’s efficiency and security. Use a Data Modeling Tool Now that you know what the site will need to do, it’s time to organize what exact information needs to be stored. A great database design tool can be helpful for this; specifically, one that can help set up visual database models, such as MySQL Workbench (for MySQL databases only) or DBDesigner4. Cliffy is also a great free online application for creating flowcharts and database models. An example of output of data modelling tool is: Database Design Using Data Modelling Tools Become familiar with the common icons and standard visual elements necessary to create database models and begin planning via flowcharts and diagrams ahead of time. This can sort out logical errors before any actual databases are created.

  6. Relational Databases Almost all databases are relational databases. This means that the tables in the database are related to each other in some way. For example, if a there is a member on an ecommerce website, that member may be related to certain products based on what they ordered last, or what they have expressed they are interested in. For a blog database, authors would have to be somehow related to the posts they wrote and logged in users could be related to any comments they’ve left. By using the techniques for relational databases, we can store plenty of information in an organized fashion within separate tables: one table for members, one for posts, another for comments, and yet another for products. Then, we can link the data between different tables together via unique keys. The below figure shows the table present in relational database: Table Structure in Relational Database Every entry in every table needs a unique primary key. This is the “social security number” or “bar code” for each entry. It is unique to each entry, and no other entry can have the same ID in the same table. Having unique usernames or product names in a database table is not enough. It is far more efficient, and best practice as well, to use unique primary keys. Even with other types of unique fields, a database is still vulnerable to duplicate records, which can later break code within the website.

  7. Relationship Diagram This is a simple one-to-one relationship model. There are also models for one-to-many and many-to-many relationships. Grouping or Separating Data info Fields Within fields, it’s also important to know when to group certain pieces of data together, and when to keep them separate. A good way to determine which information should be in the same field or otherwise is to think about what it would take to change that piece of information if necessary. For example, would it be necessary to place a full address in separate fields, based on 1) street address, 2) city, 3) state, 4) zip code, and then 5) country? Is it essential for the functionality of the site (perhaps users or admins would need to search addresses by state only), or is it just a waste of fields and database space? If it’s not essential, just to change an address the database would have to update five separate fields, when it could just update one field in string form. To keep such a field organized, one could take in the information via an HTML form with these fields separated, but then concatenate them into one single string before placing the address into the database. This is just one example, but always keep in mind the most efficient ways to organize table fields, and when to combine them, or when to keep them separate for the sake of the website’s functionality. Database Normalization Database normalization is a set of guidelines created by the community for organizing data in a database efficiently. We’ve mentioned a few of the most important and basic practices already, which are included in some of the most standard normalization forms. There are five normal forms to follow, and it’s a good idea to learn about these five forms in order to conform any database’s design to their best practices. Database normalization is a large topic, but just understanding the basics can help tremendously.

  8. Web Database Architecture • A database management system (DBMS) is system software for creating and managing databases. The DBMS provides users and programmers with a systematic way to create, retrieve, update and manage data. • A Database Management system is not always directly available for users and applications to access and store data in it. A Database Management system can be centralised(all the data stored at one location), decentralised(multiple copies of database at different locations) or hierarchical, depending upon its architecture. • 1-tier DBMS architecture also exist, this is when the database is directly available to the user for using it to store data. Generally, such a setup is used for local application development, where programmers communicate directly with the database for quick response. • Database Architecture is logically of two types: • 2-tier DBMS architecture • 3-tier DBMS architecture • 2-tier DBMS Architecture • An application interface known as ODBC(Open Database Connectivity) provides an API that allow client side program to call the DBMS. Most DBMS vendors provide ODBC drivers for their DBMS.

  9. THANK YOU CONTACT US:- 70-70-90-50-90 info@ducatindia.com

More Related