0% found this document useful (0 votes)
299 views21 pages

Intership Report

This document is an internship report submitted by Namburi Venkata Saiprathap, roll number 20F65A0327, to partial fulfillment of the Bachelor of Technology degree in Mechanical Engineering from Siddharth Institute of Engineering & Technology. The report details the topics covered during a Java Full Stack internship at QSPIDERS in Bangalore, including introductions to web development, HTML, CSS, Java, databases, and more. It provides an overview of the key concepts and technologies learned during the internship.
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
299 views21 pages

Intership Report

This document is an internship report submitted by Namburi Venkata Saiprathap, roll number 20F65A0327, to partial fulfillment of the Bachelor of Technology degree in Mechanical Engineering from Siddharth Institute of Engineering & Technology. The report details the topics covered during a Java Full Stack internship at QSPIDERS in Bangalore, including introductions to web development, HTML, CSS, Java, databases, and more. It provides an overview of the key concepts and technologies learned during the internship.
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 21

An Internship Report

On
JAVA FULL STACK
Submitted

in partial fulfillment for the award of the degree


Of
Bachelor of Technology
in
Mechanical Engineering
By

NAME: NAMBURI VENKATA SAIPRATHAP ROLL NO: 20F65A0327

Department of Mechanical Engineering


SIDDHARTH INSTITUTE OF ENGINEERING & TECHNOLOGY
(AUTONOMOUS)
(Approved by AICTE & Affiliated to JNTUA, Ananthapuramu)
(Accredited by NBA for Civil, EEE, ECE, MECH and CSE, New
Delhi)
(Accredited by NAAC with ‘A+’ Grade, an ISO 9001:2008 Certified Institution)
Siddharth Nagar, Narayanavanam road, Puttur-517583, A.P
2019- 2023
SIDDHARTH INSTITUTE OF ENGINEERING & TECHNOLOGY
(AUTONOMOUS)
(Approved by AICTE & Affiliated to JNTUA, Ananthapuramu)
(Accredited by NBA for Civil, EEE, ECE, MECH and CSE, New
Delhi)
(Accredited by NAAC with ‘A+’ Grade, an ISO 9001:2008 Certified Institution)
Siddharth Nagar, Narayanavanam road, Puttur-517583, A.P

DEPARTMENT OF MECHANICAL ENGINEERING

CERTIFICATE
This is to certify that the Mr. / Ms. NAMBURI VENKATA SAIPRATHAP _

bearing Roll No. _20F65A0327 of IV year B.Tech I semester in the


department of _Mechanical Engineering has completed his / her
Internship in the topic of JAVA FULL STACK_ at
QSPIDERS, BANGALORE during the academic
year 2022 - 2023.

Date: Head of the Department


TOPICS Covered During Training:
Introduction to WEB
 What is web?
 Web Features?
Core HTML
 Introduction
 Parts in HTML Document
 Head section
 Body Section
 HTML forms

Introduction to CSS
 CSS Basics
 CSS Introduction
 Styling Fonts
 Styling Text
Introduction to JAVA
 Why Java was developed?
 History of JAVA
 Different Java Platforms
 JVM Architecture
 Installing java on windows
JAVA Language Fundamentals
 Identifiers
 Keywords
 Variables
 Literals
 Data Types
 Operators
 Looping Statements
 Condition Statements
 Type Casting
 Comments
OOP implementation
 Why OOP?
 OOP concepts with Real life Examples
 Class & Object
 Reference variable
 Constructors
 Instance & static Variables & Methods
 These Keyword & it’s usages
 Inheritance & it’s Syntax
 Types of Inheritance
 Object Class as Root of java class hierarchy
 Variable Hiding
 Method Hiding
 Method Overriding & Overloading
 Super Keyword & it’s usages
 Final Keyword & it’s usages
 Constructor Chaining
 Upcasting and Down casting
 Static and Dynamic Binding

`
3
 Run time Polymorphism
 Abstract Keyword (Abstract classes and methods)
 Understanding Interfaces
 Implementation of Encapsulation
PACKAGES
 Understanding Packages
 Setting Class path
 Reading Input from Keyboard
 Access Modifiers
ARRAYS
 General Definition of Array
 Advantages of Array
 Arrays in Java
 1-D Array
 2-D Array
 Array of reference type
 Operations on Arrays
EXCEPTION HANDLING
 Types of Runtime Errors
 Understanding Exception
Working with STRING
 What is String
 String Class
 Creating String Object
 Operations on String
Designing your web Database
Relational Database
Concepts
How to Design Your
Database

Creating Your web


Database
 Creating Databases and Users
 Introduction to My SQL
 Setting Up a user for the web
 Creating Database Tables
Working with Your My SQL Database
 Inserting Data
 Retrieving Data
 Updating Data
 Altering Tables after Creation

4
Introduction to WEB: -

What is web?
The Web is the common name for the World Wide Web, a subset of the Internet consisting
of the pages that can be accessed by a Web browser. Many people assume that the Web is the
same as the Internet, and use these terms interchangeably. However, the term Internet refers to the
global network of servers that makes the information sharing that happens over the Web possible.
So, although the Web does make up a large portion of the Internet, but they are not one and same.
Web Features: -
 Easy navigation.
 Trendy, intuitive design and user experience<
 Relevant, authoritative website content<
 Product visuals and descriptions<
 Social media as an extension of the business website<
 Company blog<

Core HTML: -

 Introduction: -
HTML stands for HyperText Markup Language. It is used to design web pages
using a markup language. HTML is the combination of Hypertext and Markup language.
Hypertext defines the link between web pages. A markup language is used to define the text
document within the tag which defines the structure of web pages. This language is used to
annotate (make notes for the computer) text so that a machine can understand it and manipulate
text accordingly. Most markup languages (e.g., HTML) are human-readable. The language uses
tags to define what manipulation has to be done on the text.

Parts in HTML Document: -


 The HEAD element.
 The TITLE element.
 The title attribute.
 Meta data. Specifying meta data. The META element. Meta data profiles.

Head section: -
The <head> element is a container for metadata (data about data) and is placed
between the <html> tag and the <body> tag. HTML metadata is data about the HTML
document. Metadata is not displayed. Metadata typically define the document title, character set,
styles, scripts, and other meta information.

Body Section: -
The <body> tag defines the document's body. The <body> element contains all the
contents of an HTML document, such as headings, paragraphs, images, hyperlinks, tables, lists,
etc. Note: There can only be one <body> element in an HTML document.

5
HTML forms: -

HTML Form is a document which stores information of a user on a web server using
interactive controls. An HTML form contains different kind of information such as username,
password, contact number, email id etc. The elements used in an HTML form are check box, input
box, radio buttons, submit buttons etc.

Introduction to CSS: -
CSS Basics: -
Like HTML, CSS is not a programming language. It's not a markup language
either. CSS is a style sheet language. CSS is what you use to selectively style HTML
elements. For example, this CSS selects paragraph text, setting the color to red:

p{
color: red;
}

CSS Introduction: -

Cascading Style Sheets, fondly referred to as CSS, is a simply designed language


intended to simplify the process of making web pages presentable. CSS allows you to apply
styles to web pages. More importantly, CSS enables you to do this independent of the HTML
that makes up each web page. It describes how a webpage should look: it prescribes colors,
fonts, spacing, and much more. In short, you can make your website look however you want.
CSS lets developers and designers define how it behaves, including how elements are positioned
in the browser.

Styling Fonts: -
1. CSS Font color: This property is used to change the color of the text. (Standalone
attribute)
2. CSS Font family: This property is used to change the face of the font.
3. CSS Font size: This property is used to increase or decrease the size of the font.
4. CSS Font style: This property is used to make the font bold, italic, or oblique.
5. CSS Font variant: This property creates a small-caps effect.
6. CSS Font weight: This property is used to increase or decrease the boldness and
lightness of the font.

Styling Text: -

CSS defines five generic names for fonts: serif, sans-serif, monospace, cursive, and
fantasy.

These are very generic and the exact font face used from these generic names can vary
between each browser and each operating system that they are displayed on.

6
Introduction to JAVA: -
Why Java was developed?
The Java programming language originated as part of a research project to develop advanced
software for a wide variety of network devices and embedded systems. The goal was to
develop a small, reliable, portable, distributed, real-time operating platform.

History of JAVA: -
The history of Java is very interesting. Java was originally designed for interactive
television, but it was too advanced technology for the digital cable television industry at the time.
The history of Java starts with the Green Team. Java team members (also known as Green Team),
initiated this project to develop a language for digital devices such as set-top boxes, televisions,
etc. However, it was best suited for internet programming. Later, Java technology was
incorporated by Netscape.

Different Java Platforms: -

There are four platforms of the Java programming language:


 Java Platform, Standard Edition (Java SE)
 Java Platform, Enterprise Edition (Java EE)
 Java Platform, Micro Edition (Java ME)
 Java FX.
JVM Architecture: -
JVM (Java Virtual Machine) is an abstract machine. It is a specification that provides
runtime environment in which java bytecode can be executed. JVMs are available for
many hardware and software platforms (i.e., JVM is platform dependent).

Installing java on windows: -

1. Check if Java Is Installed.


2. Download Java for Windows 10.
3. Install Java on Windows 10. Step 1: Run the Downloaded File. Step 2: Configure the
Installation Wizard.
4. Set Environmental Variables in Java. Step 1: Add Java to System Variables. ...
5. Test the Java Installation. Step 1: Write a Test Java Script.

JAVA Language Fundamentals: -


Classes, objects, methods, arrays, and lists. Object-oriented programming and de- sign
utilizing inheritance, polymorphism, and abstraction. The proper use of Oracle's online Java
documentation. Debugging Java programs using an IDE.
 Identifiers: -
An identifier is a sequence of one or more characters. The first
character must be a valid first character (letter, $, _) in an identifier of the Java
programming language, hereafter in this chapter called simply “Java.”
 Keywords: -
Java keywords are also known as reserved words. Keywords are particular words
that act as a key to a code. These are predefined words by Java so they cannot be used as
a variable or object name or class name.

7
Variables: -
A variable is a container which holds the value while the Java program is executed.
A variable is assigned with a data type. Variable is a name of memory location. There are
three types of variables in java: local, instance and static. There are two types of data types
in Java: primitive and non-primitive.

 Literals: -
Literals in Java are a synthetic representation of boolean, character,
numeric, or string data. They are a means of expressing particular values within a
program. They are constant values that directly appear in a program and can be assigned
now to a variable.

 Data Types: -
Data types specify the different sizes and values that can be stored in the variable.
There are two types of data types in Java:
Primitive data types: The primitive data types include boolean, char, byte,
short, int, long, float and double.
Non-primitive data types: The non-primitive data types
include Classes, Interfaces, and Arrays.

 Operators: -

Operator in Java is a symbol that is used to perform operations. For


example: +, -, *, / etc.
There are many types of operators in Java which are given below:
a. Unary Operator,
b. Arithmetic Operator,
c. Shift Operator,
d. Relational Operator,
e. Bitwise Operator,
f. Logical Operator,
g. Ternary Operator and
h. Assignment Operator.

 Looping Statements: -

The Java for loop is used to iterate a part of the program several times. If the
number of iterations is fixed, it is recommended to use for loop

There are three types of for loops in Java.

 Simple for Loop.


 For-each or Enhanced for Loop.
 Labelled for Loop.

8
Condition Statements: -

Java has the following conditional statements: Use if to specify a block of code to be
executed, if a specified condition is true. Use else to specify a block of code to be executed, if the
same condition is false. Use else if to specify a new condition to test, if the first condition is false.

Type Casting: -
In Java, type casting is a method or process that converts a data type into another data
type in both ways manually and automatically. The automatic conversion is done by the
compiler and manual conversion performed by the programmer. In this section, we will discuss
type casting and its types with proper examples.

Comments: -

Comments in Java are the statements that are not executed by the compiler and
interpreter. It can be used to provide information or explanation about the variable, method,
class, or any statement. It can also be used to hide program code for a specific time.

OOP implementation: -

Why OOP?
OOP provides a clear structure for the programs. OOP helps to keep the Java code
DRY "Don't Repeat Yourself", and makes the code easier to maintain, modify and debug.
OOP makes it possible to create full reusable applications with less code and shorter
development time.

OOP concepts with Real life Examples: -


Let's take an example of one of the OOPs concepts with real time examples: If you had a
class called “Expensive Cars,” it could contain objects like Mercedes, BMW, Toyota,
and so on. The price or speed of these autos could be one of its attributes (data).

Class & Object: -


A Class in object-oriented programming is a blueprint or prototype that defines the
variables and the methods (functions) common to all Java Objects of a certain kind. An
object in OOPS is a specimen of a class. Software objects are often used to model real-
world objects you find in everyday life.

9
Reference Variable: -

A reference variable is a variable that points to an object of a given class, letting you
access the value of an object. An object is a compound data structure that holds values that you
can manipulate. A reference variable does not store its own values.

Constructors: -

Constructor in java is used to create the instance of the class. Constructors are almost
similar to methods except for two things - its name is the same as the class name and it has no
return type. Sometimes constructors are also referred to as special methods to initialize an object.

Instance & static Variables & Methods: -

Instance variables are just variables defined inside a class, and every instance of a
class can have a different value for an instance variable. In this module, we'll look at defining
static variables in our Java classes.

Static variables are also defined as variables inside a class, but with the keyword
'static'.

Static methods are the methods in Java that can be called without creating an object of
class. Static method is declared with static keyword. Instance method is not with static keyword.

This Keyword & it’s usages: -

This keyword refers to the current object in a method or constructor. The most
common use of this keyword is to eliminate the confusion between class attributes and parameters
with the same name (because a class attribute is shadowed by a method or constructor parameter).

Inheritance & it’s Syntax: -

Inheritance in Java is a mechanism in which one object acquires all the properties and
behaviours of a parent object. It is an important part of OOPs (Object Oriented programming
system).The idea behind inheritance in Java is that you can create new classes that are
built upon existing classes.

When you inherit from an existing class, you can reuse methods and fields of the parent class.
Moreover, you can add new methods and fields in your current class also.

Inheritance represents the IS-A relationship which is also known as a


parent- child relationship.

10
Object Class as Root of java class hierarchy: -

Class Object is the root of the class hierarchy. Every class has Object as a
superclass. All objects, including arrays, implement the methods of this class.

Variable Hiding: -
Variable Hiding happens when a variable declared in the child class has the
same name as the variable declared in the parent class. In contrast, variable
shadowing happens when a variable in the inner scope has the same name as the
variable in the outer scope.

Method Hiding: -

In this section, we will discuss what is method hiding in Java, method hiding factors
(MHF), and the differences between method hiding and method overriding. Also, implement
the method hiding concept in a Java program. To understand the method hiding concept in
Java, first, we will understand the method overriding. Because the method hiding concept is very
similar to the method overriding.

Method Overriding & Overloading: -


If a class has multiple methods having same name but different in parameters, it is
known as Method Overloading.

If subclass (child class) has the same method as declared in the parent class, it is known as
method overriding in Java. In other words, if a subclass provides the specific implementation of
the method that has been declared by one of its parent classes, it is known as method overriding.

Super Keyword & it’s usages: -


The super keyword refers to superclass (parent) objects. It is used to call
superclass methods, and to access the superclass constructor. The most common use
of the super keyword is to eliminate the confusion between superclasses and subclasses
that have methods with the same name.

Final Keyword & it’s usages: -

The final keyword in java is used to restrict the user. The java final keyword can be used
in many contexts. Final can be:
11
1. Variable.
2. method.
3. class.

Constructor Chaining: -

Constructor chaining refers to the ability to call a constructor inside another


constructor. You can use a constructor chain either within the same class or even with another
one. For the latter, the constructor should be through inheritance from the super class.

Upcasting and Down casting: -

A process of converting one data type to another is known as


Typecasting and Upcasting and Downcasting is the type of object typecasting. In Java, the
object can also be typecasted like the datatypes. Parent and Child objects are two types of
objects. So, there are two types of typecasting possible for an object, i.e., Parent to Child and
Child to Parent or can say Upcasting and Downcasting.

Static and Dynamic Binding: -

Static Binding: The binding which can be resolved at compile time by compiler is
known as static or early binding. Binding of all the static, private and final methods is done
at compile-time.
Dynamic Binding: When type of the object is determined at run-time, it is known as
dynamic binding.

12
Run time Polymorphism: -

Runtime polymorphism, also known as the Dynamic Method Dispatch, is a process that
resolves a call to an overridden method at runtime. The process involves the use of the
reference variable of a superclass to call for an overridden method.

Abstract Keyword (Abstract classes and methods): -

The abstract keyword is a non-access modifier, used for classes and methods:
Abstract class: is a restricted class that cannot be used to create objects (to access it, it must be
inherited from another class). Abstract method: can only be used in an abstract class, and it does
not have a body.

Understanding Interfaces: -

In Java, an interface specifies the behaviour of a class by providing an abstract type.


As one of Java's core concepts, abstraction, polymorphism, and multiple inheritance are supported
through this technology. Interfaces are used in Java to achieve abstraction.

Implementation of Encapsulation: -

In encapsulation, the variables of a class will be hidden from other classes, and can be
accessed only through the methods of their current class. Therefore, it is also known as data
hiding. Declare the variables of a class as private. Provide public setter and getter methods to
modify and view the variables values.

PACKAGES: -

Understanding Packages: -

A package in Java is used to group related classes. Think of it as a folder in a file


directory. We use packages to avoid name conflicts, and to write a better maintainable code.
Packages are divided into two categories.

Setting Class path: -

Class path is a parameter in the Java Virtual Machine or the Java compiler
13
that specifies the location of user-defined classes and packages. The parameter may be set
either on the command-line, or through an environment variable.

Reading Input from Keyboard: -

Input from the keyboard:

1. import java. util. Scanner; - imports the class Scanner from the library java.util.
2. Scanner scanner = new Scanner (System.in); - creates a new Scanner object, that is
connected to standard input (the keyboard)
3. String inputString = scanner. nextLine ();

Access Modifiers: -

There are two types of modifiers in Java: access modifiers and non-access modifiers.

The access modifiers in Java specifies the accessibility or scope of a field, method,
constructor, or class. We can change the access level of fields, constructors, methods, and class by
applying the access modifier on it.

There are four types of Java access modifiers:

1. Private: The access level of a private modifier is only within the class. It cannot be
accessed from outside the class.
2. Default: The access level of a default modifier is only within the package. It cannot be
accessed from outside the package. If you do not specify any access level, it will be the
default.
3. Protected: The access level of a protected modifier is within the package and outside the
package through child class. If you do not make the child class, it cannot be ac- cessed
from outside the package.
4. Public: The access level of a public modifier is everywhere. It can be accessed from
within the class, outside the class, within the package and outside the package.

ARRAYS: -

General Definition of Array: -

An array is a container object that holds a fixed number of values of a single type.
The length of an array is established when the array is created. After creation, its length is fixed.

Advantages of Array: -

 We can access any element randomly by using indexes provided by arrays.

14
 Primitive type to wrapper classes object conversion will not happen so it is fast.
 Array can store many number of elements at a time.
Arrays in Java: -
An array is a collection of similar types of data. For example, if we want to store the
names of 100 people then we can create an array of the string type that can store 100 names.
String [] array = new String [100];
Here, the above array cannot store more than 100 names.
1-D Array (One-Dimensional Array): -
One-dimensional array or single dimensional array must deal with values of only one
data type. One dimensional array can also store multiple objects of the same class. An array in
java is an object of a dynamically generated class that can be initialized and created using the
new operator.
2-D Array (Two-Dimensional Array): -
Here i and j are the size of the two dimensions, i.e., i denotes the number of rows while j
denotes the number of columns. Example: int A [10][20]; Here we declare a two- dimensional
array in C, named A which has 10 rows and 20 columns.

Array of reference type: -

Array, which itself is derived from System. Object. This means that all arrays are always
reference types which are allocated on the managed heap, and your app's variable contains a
reference to the array and not the array itself.

Operations on Arrays: -

Traverse − print all the array elements one by one. Insertion − Adds an element at
the given index. Deletion − Deletes an element at the given index. Search − Searches an
element using the given index or by the value.

EXCEPTION HANDLING: -

Types of Runtime Errors: -


The 10 most common examples of RuntimeExceptions in Java are:

1. Arithmetic Exception

2. NullPointerException

3. ClassCastException

4. DateTimeException

5. ArrayIndexOutOfBoundsException.

15
Understanding Exception: -
An exception (or exceptional event) is a problem that arises during the execution of a
program. When an Exception occurs the normal flow of the program is disrupted and the
program/Application terminates abnormally, which is not recommended, therefore, these
exceptions are to be handled.

An exception can occur for many different reasons. Following are some scenarios where an
exception occurs.
 A user has entered an invalid data.
 A file that needs to be opened cannot be found.
 A network connection has been lost in the middle of communications or the
JVM has run out of memory.

Working with STRING: -


What is String: -

Strings, which are widely used in Java programming, are a sequence of characters. In
the Java programming language, strings are objects. The Java platform provides the String class to
create and manipulate strings.

String Class: -

The String class represents character strings. All string literals in Java programs, such
as "abc,” are implemented as instances of this class. Strings are constant; their values cannot be
changed after they are created. String buffers support mutable strings. Because String objects are
immutable, they can be shared.

Creating String Object: -

There are two ways to create a String object:

1. By string literal: Java String literal is created by using double quotes. For Example:
String s= “Welcome;”
2. By new keyword: Java String is created by using a keyword “new”. For example:
String s=new String(“Welcome”);
Operations on String: -

Java String class provides a lot of methods to perform operations on strings such as
compare (), concat (), equals (), split (), length (), replace ().

The string operations include concatenation, scanning, substringing, translation, and


verification.

16
String operators represent the various types of operations that we can employ on the
string type of the variables in the program. Moreover, python lets us apply numerous string
operators on the python string and these are explained well in this article.

Creating Your web Database

Creating Databases and Users: -

This tutorial provides an example on how to create a Database using JDBC application.
Before executing the following example, make sure you have the following in place −
 You should have admin privilege to create a database in the given schema. To
execute the following example, you need to replace the username and pass- word
with your actual user name and password.
 Your MySQL or whatever database is up and running.
Required Steps
The following steps are required to create a new Database using JDBC application −
 Import the packages − Requires that you include the packages containing the
JDBC classes needed for database programming. Most often, using import
java.sql. * Will suffice.
 Open a connection − Requires using the DriverManager.getConnec- tion()
method to create a Connection object, which represents a physical con- nection
with the database server.
To create a new database, you need not give any database name while preparing
database URL as mentioned in the below example.
 Execute a query − Requires using an object of type Statement for building and
submitting an SQL statement to the database.
 Clean up the environment. try with resources automatically closes the re-
sources.
Introduction to My SQL: -
MySQL is a fast, easy-to-use RDBMS being used for many small and big businesses.
MySQL is developed, marketed and supported by MySQL AB, which is a Swedish company.
MySQL is becoming so popular because of many good reasons −
 MySQL is released under an open-source license. So, you have nothing to pay to
use it.
 MySQL is a very powerful program in its own right. It handles a large subset of
the functionality of the most expensive and powerful database packages.
 MySQL uses a standard form of the well-known SQL data language.
 MySQL works on many operating systems and with many languages including
PHP, PERL, C, C++, JAVA, etc.
 MySQL works very quickly and works well even with large data sets.
 MySQL is very friendly to PHP, the most appreciated language for web devel-
opment.
 MySQL supports large databases, up to 50 million rows or more in a table. The
default file size limit for a table is 4GB, but you can increase this (if your op-
erating system can handle it) to a theoretical limit of 8 million terabytes (TB).
 MySQL is customizable. The open-source GPL license allows programmers to
modify the MySQL software to fit their own specific environments.

17
Setting Up a user for the web: -

With a user account, a visitor creates a personalized profile on your website in order to
tailor their experience with your web content.

Accounts empower users to access exclusive offers, contribute to a community of fellow


customers, reach out to customer support, and receive content recommendations relevant to
them.

All of these benefits help you gain consumer trust and convert visitors into engaged leads.
After all, they’re called “user accounts,” not “visitor accounts.”

Many sites can gain from providing user accounts, regardless of the product or industry. If your
website...

 offers paid products and/or services for account holders

 facilitates social or professional networking

 facilitates e-commerce and stores users’ payment information, orders, and/or carts

 offers exclusive content for registered users

 hosts public user-generated content, like blog posts, videos, or reviews

 hosts private user-provided content, like cloud storage, notes, or e-journal entries

 aims to build a community around users

 allows reactions to content in the form of comments, ratings, and/or reviews

 uses visitor-related information to tailor the browsing experience to individuals then you
will likely need user accounts on your website.

But before you continue, consider whether it’s best for your specific site to suggest or
require accounts. An account should first and foremost enhance the user experience, so
make sure the benefits to the customer are worth the time and effort of signing up.

No one should feel “forced” to create an account when they don’t need to.

Creating Database Tables: -

Create a new table in an existing database: -

1. Click File > Open, and click the database if it is listed under Recent. If not, select one
of the browse options to locate the database.
2. In the Open dialog box, select the database that you want to open, and then click
Open.
3. On the Create tab, in the Tables group, click Table.

18
Working with Your My SQL Database: -
Inserting Data: -

Data insertion is the process of inserting rows into a table. The data insertion methods
and an example of specifying SQL statements are shown as follows. The INSERT statement is
used to insert rows.
Data insertion methods
The INSERT statement is used to insert rows. The following two methods are
available for inserting rows into a table:

 Inserting rows by column


 Inserting rows by row (specify ROW in the INSERT statement)

Data insertion SQL specification example


An example of inserting rows by column is explained as follows.

Example
In this example, the INSERT statement inserts in each column of the stock table
(STOCK) the values set in embedded variables (: ZPCODE, ZPNAME, ZCOLOR,
ZPRICE, and: ZSQUANTITY) that are used for transferring values between a table and
UAPs:

INSERT INTO STOCK (PCODE, PNAME, COLOR, PRICE, SQUANTITY)


VALUES (: ZPCODE, ZPNAME, ZCOLOR, ZPRICE, ZSQUANTITY);

Retrieving Data: -

Data retrieval means obtaining data from a Database Management System


(DBMS) such as ODBMS. In this case, it is considered that data is represented in a structured
way, and there is no ambiguity in data. In order to retrieve the desired data, the user present a
set of criteria by a query.
With the accurate classification of data, you can add a time element to various pieces of
information. This easy retrieval of data will allow you to find, identify, and execute processes
based on chronological significance.
Data extraction is the process of collecting or retrieving disparate types of data
from a variety of sources, many of which may be poorly organized or completely
unstructured.
information retrieval, recovery of information, especially in a database stored in a
computer. Two main approaches are matching words in the query against the database index
(keyword searching) and traversing the database using hypertext or hypermedia links.

Updating Data: -
The modification of data that is already in the database is referred to as updating. You
can update individual rows, all the rows in a table, or a subset of all rows. Each column can be
updated separately; the other columns are not affected.
To update data in a table, you need to: First, specify the table name that you want to
change data in the UPDATE clause. Second, assign a new value for the column that you
want to update.

19
In case you want to update data in multiple columns, each column = value pair is separated by a
comma (,).

Altering Tables after Creation: -

The SQL ALTER TABLE command is used to change the structure of an existing
table. It helps to add or delete columns, create, or destroy indexes, change the type of existing
columns, or rename columns or the table itself. It can also be used to change the comment for the
table and type of the table.

20
21

You might also like