Why MySQL Database?

MySQL has its own client interface, allowing you to move data around and change database configuration. Note that you must use a password to log in. Assigning database users allows you to limit access to server tables that have multiple users. Each MySQL server, where tables are grouped together, can host many databases. Normally, a web application has its own proprietary database.
You may have installed MySQL yourself or have access through your ISP. Most ISPs that support PHP also provide a MySQL database for your use. Should you have difficulty, check their support pages or contact them to determine connection details. You'll need to know the following:
  • The IP address of the database server
  • The name of the database
  • The username
  • The password
If you've installed MySQL on your computer, you'll be able to use the defaults from the installation and the password you specified. This chapter looks at two ways to communicate with MySQL, the command line and phpMyAdmin, a web-based tool.

Once you reach the command line, type mysql and press Enter. The syntax for the mysql command is:
mysql -h hostname -u user -p

If you've installed MySQL on your computer, the default username is root. You can omit the hostname flag and value. Enter your password when MySQL displays the Enter password prompt.

At the MySQL prompt, you can enter database commands followed by Enter. There is also a set of commands that MySQL itself interprets. For a list of these commands, type help or \h at the mysql> prompt.  

Command prompt meanings
Prompt
Meaning
mysql>
Waiting for a command
->
Waiting for the next line of a command
'>
Waiting for the next line of a string that starts with a single quote
">
Waiting for the next line of a string that starts with a double quote

MySQL client commands
Command
Parameter
Meaning
quit
Exit the command-line utility
use
Database name
Use a specific database
show
tables or databases
Show lists such as tables or databases available
describe
Table name
Describe a table's columns
status
Display database version and status
source
Filename
Execute commands from a file as a script


To display the available databases, type:

mysql> SHOW DATABASES;

PHP Functions
Php tutorial - imagemagick
php.ini Basics
PHP Sessions
Cookies Versus Sessions
PHP Web-Related Variables
PHP ERRORS
maximum size of a file uploaded
Php Image upload
php file_get_contents
MySQL Data on the Web
What are GET and POST
php and pdf
$_ENV and $_SERVER
PEAR with php
SELECTING DATA PHP
prevent hijacking with PHP
LAMP
PHP MySQL Functions
PHP Zip File Functions
Substrings PHP
PHP Variable names
PHP magic methods
How to get current session id
Add variables into a session
$_GET , $_POST,$_COOKIE
different tables present in mysql
PHP CURL
php Sessions page
PHP-sorting an array
PHP-count the elements of array
Operators for If/Else Statements
PHP file uploading code
PHP global variables
Testing working using phpinfo
PHP Code for a Valid Number
PHP-Associative Arrays
PHP mvc tutorial
PHP get_meta_tags-Extracts
difference between print and echo
PHP best tutorial-PHP variables
Reading DOC file in PHP
PHP interview questions
convert time PHP
PHP implode array elements
header function-PHP
PHP-Renaming Files Directories
PHP Classes
in_array function in PHP
keep your session secure PHP
Web Application with PHP
What is SQL Injection
PHP-extract part of a string
PHP urlencode
PHP- know browser properties
PHP- Extracting Substrings
Checking Variable Values /Types
PHP-best 20 Open Source cms
IP AddressPHP
PHP-Scope Resolution Operator
how create new instance of object
how eliminate an object
PHP- ob_start
XML file using the DOM API
PHP- MVC
PHP- CAPTCHA
PHP- Position of a Value in an Array
PHP-Mail Functions
PHP-difference include vs require
calculate the sum of values in an array
PHP-total number of rows
Show unique records mysql
MySQL Triggers
MySQL data directory
MySQL Subqueries
PHP- Networking Functions
PHP- Operators
Restore database
Conditional Functions mysql
PHP-function overloading
Friend function
mysql_connect /mysql_pconnect
PHP-Error Control Operators
what is IMAP
Apache-Specific Functions
Send Email from a PHP Script
SQL inherently
WAMP, MAMP, LAMP
Php tutorial-SYMBOLS
Table Types-MySQL
PHP-Encryption data management
PHP Array
Running MySQL on Windows
Maximum Performance MySQL
XML-RPC
PHP-static variables
Advanced Database Techniques
FTP
Codeigniter
Apache Pool Size
Why NoSQL
MySQL Server Performance
Database software
SQL Interview Answers
PHP Redirect
PHP Interview Questions with Answers
Advanced PHP

Advantages of Using PHP with MySQL

Advantages of Using PHP with MySQL

 

There are several factors that make using PHP and MySQL together a natural choice:

PHP and MySQL work well together
PHP and MySQL have been developed with each other in mind, so they are easy to use together. The programming interfaces between them are logically paired up. Working together wasn't an afterthought when the developers created the PHP and MySQL interfaces.

PHP and MySQL have open source power
As they are both open source projects, PHP and MySQL can both be used for free. MySQL client libraries are no longer bundled with PHP. Advanced users have the ability to make changes to the source code, and therefore, change the way the language and programs work.

PHP and MySQL have community support
There are active communities on the Web in which you can participate and they'll answer your questions. You can also purchase professional support for MySQL if you need it.

PHP and MySQL are fast
Their simplicity and efficient design enables faster processing.

PHP and MySQL don't bog you down with unnecessary details.
You don't need to know all of the low-level details of how the PHP language interfaces with the MySQL database, as there is a standard interface for calling MySQL procedures from PHP. Online APIs at http://www.php.net offer an unlimited resource.

As we mentioned above, both PHP and MySQL are open source projects, so there's no need to worry about user licenses for every computer in your office or home. In open source projects and technologies, programmers have access to the source code; this enables individual or group analysis to identify potentially problematic code, test, debug, and offer changes as well as additions to that code. For example, Unixthe forerunner in the open source software communitywas freely shared with university software researchers. Linux, the free alternative to Unix, is a direct result of their efforts and the open source licensing paradigm.

PHP is ubiquitous and compatible with all major operating systems. It is also easy to learn, making it an ideal tool for web-programming beginners. Additionally, you get to take advantage of a community's effort to make web development easier for everyone. The creators of PHP developed an infrastructure that allows experienced C programmers to extend PHP's abilities. As a result, PHP now integrates with advanced technologies like XML, XSL, and Microsoft's COM. At this juncture, PHP 5.0 is being used.

MySQL was developed in the 1990s to fill the ever-growing need for computers to manage information intelligently. The original core MySQL developers were trying to solve their needs for a database by using mSQL, a small and simple database. It become clear that mSQL couldn't solve all the problems they wanted it to, so they created a more robust database that turned into MySQL
MySQL supports several different database engines. The database engine determines how MySQL handles the actual storage and querying of the data. Because of that, each storage engine has its own set of abilities and strengths.


PHP Functions
Php tutorial - imagemagick
php.ini Basics
PHP Sessions
Cookies Versus Sessions
PHP Web-Related Variables
PHP ERRORS
maximum size of a file uploaded
Php Image upload
php file_get_contents
MySQL Data on the Web
What are GET and POST
php and pdf
$_ENV and $_SERVER
PEAR with php
SELECTING DATA PHP
prevent hijacking with PHP
LAMP
PHP MySQL Functions
PHP Zip File Functions
Substrings PHP
PHP Variable names
PHP magic methods
How to get current session id
Add variables into a session
$_GET , $_POST,$_COOKIE
different tables present in mysql
PHP CURL
php Sessions page
PHP-sorting an array
PHP-count the elements of array
Operators for If/Else Statements
PHP file uploading code
PHP global variables
Testing working using phpinfo
PHP Code for a Valid Number
PHP-Associative Arrays
PHP mvc tutorial
PHP get_meta_tags-Extracts
difference between print and echo
PHP best tutorial-PHP variables
Reading DOC file in PHP
PHP interview questions
convert time PHP
PHP implode array elements
header function-PHP
PHP-Renaming Files Directories
PHP Classes
in_array function in PHP
keep your session secure PHP
Web Application with PHP
What is SQL Injection
PHP-extract part of a string
PHP urlencode
PHP- know browser properties
PHP- Extracting Substrings
Checking Variable Values /Types
PHP-best 20 Open Source cms
IP AddressPHP
PHP-Scope Resolution Operator
how create new instance of object
how eliminate an object
PHP- ob_start
XML file using the DOM API
PHP- MVC
PHP- CAPTCHA
PHP- Position of a Value in an Array
PHP-Mail Functions
PHP-difference include vs require
calculate the sum of values in an array
PHP-total number of rows
Show unique records mysql
MySQL Triggers
MySQL data directory
MySQL Subqueries
PHP- Networking Functions
PHP- Operators
Restore database
Conditional Functions mysql
PHP-function overloading
Friend function
mysql_connect /mysql_pconnect
PHP-Error Control Operators
what is IMAP
Apache-Specific Functions
Send Email from a PHP Script
SQL inherently
WAMP, MAMP, LAMP
Php tutorial-SYMBOLS
Table Types-MySQL
PHP-Encryption data management
PHP Array
Running MySQL on Windows
Maximum Performance MySQL
XML-RPC
PHP-static variables
Advanced Database Techniques
FTP
Codeigniter
Apache Pool Size
Why NoSQL
MySQL Server Performance
Database software
SQL Interview Answers
PHP Redirect
PHP Interview Questions with Answers
Advanced PHP

PHP function using PDO for databse

function db_connect()
{
    $dsn = "mysql:host=localhost;dbname=test;charset=utf8";
    $opt = array(
        PDO::ATTR_ERRMODE            => PDO::ERRMODE_EXCEPTION,
        PDO::ATTR_DEFAULT_FETCH_MODE => PDO::FETCH_ASSOC
    );
    return new PDO($dsn,'root','', $opt);
}
 
 
$pdo = db_connect();

but note again - unlike with mysql_query(), you have to always use this $pdo variable for your queries.
 
you need not a boolean but PDO object. 
 
 
  • PDO is OO, meaning the connection to the database is represented by a PDO Object.
  • Your db_connect() function should return the object that gets created.
  • Passing in the parameters required by PDO will give you more flexibility!
 

Create the months table With MySQL

Create the months table as follows:
CREATE TABLE months (
   month_id INT NOT NULL AUTO_INCREMENT,
   month VARCHAR (20),
   days INT,
   PRIMARY KEY (month_id)); 
 
 
To add the months to the new table, specify:
INSERT INTO months VALUES (NULL,'January',31);
INSERT INTO months VALUES (NULL,'February',28);
INSERT INTO months VALUES (NULL,'March',31);
INSERT INTO months VALUES (NULL,'April',30);
INSERT INTO months VALUES (NULL,'May',31);
 INSERT INTO months VALUES (NULL,'June',30);
INSERT INTO months VALUES (NULL,'July',31);
INSERT INTO months VALUES (NULL,'August',31);
INSERT INTO months VALUES (NULL,'September',30);
 INSERT INTO months VALUES (NULL,'October',31);
INSERT INTO months VALUES (NULL,'November',30);
INSERT INTO months VALUES (NULL,'December',31);
 
 
 
 
 

Nokia Oyj

The Microsoft acquisition of Nokia Contrivances and Accommodations is expected to close later
 this month and to prepare for the transition a letter has been sent out to Nokia's supplier base.

The letter, which has leaked online, suggests that Nokia Oyj will get an incipient name: Microsoft Mobile Oy. The company is going to subsist as a plenarily-owned Microsoft subsidiary and as you would expect it is going to handle the mobile contrivances engenderment. The letter reveals that current terms and conditions that suppliers were having with Nokia until now will not be transmuted.

Nokia is keeping its relationship with subsisting supplier partners, but considering the company's main operations remain NSN, HERE Maps and Advanced Technology unit, it may not soon need some of them, as most deal with hardware. Nokia has been rumored to be working on a smartwatch, but we don't ken if the company is going to keep the development.

Oppo N1

Oppo N1


Oppo N1, the company's last year flagship smartphone is now available for
 a discounted price tag in Europe. The smartphone can now be picked from
the Oppo Style webstore for €369 (about $500). Oppo N1 on a mundane day
costs $449 about $620, but the store is offering the smartphone for a bargain
 price as a promotional campaign. The deal is applicable to the 16GB white

version and is valid until April 25. However, please note that Oppo Style Store
 ships their products only to certain regions across the globe. For your mazuma,
 you will be getting 5.9-inch exhibit with a resolution of 1080 x 1920 pixels.

The smartphone features a Qualcomm Snapdragon 600 chipset with 1.7 GHz quad-core
 processor, Adreno 320 GPU and 2 GB of RAM. There is a 13 megapixel swirling
camera with dual-LED flash and you get 16 GB of internal storage. You can check
 out our detailed review of Oppo N1 to ken more about the smartphone.

Jobs At ISRO Development and Educational Communication

Indian Space Research Organisation (ISRO) 
Development and Educational Communication Unit (DECU),  Ahmedabad


ISRO SAC Development and Educational Communication Unit, Ahmedabad invites online application for the following posts :

  1. Social Research Officer - C : 01 post 
  2. Junior Producer : 01 post
  3. Social Research Assistant : 03 posts
  4. Programme Assistant : 03 posts
  5. Technical Assistant (Sound Recording) : 01 post
  6. Scientific Assistant - A (Multimedia) : 05 posts
  7. Media Library Assistant - A : 01 post
  8. Library Assistant - A : 01 post
How to apply : The application for on-line registration is hosted in the ISRO web-site between 16/04/2014 and 05/05/2014.

More Details  http://www.sac.isro.gov.in 

Job At IIT Kanpur

IIT Kanpur invites online applications for the following posts on Regular/ Deputation/ contract basis for a period of 5 years which is extendable on noteworthy performance :

  1. Medical Officer : 01 post
  2. Junior Superintendent : 04 posts
  3. Sanitary Inspector Gr.I : 01 post
  4. Junior Technical Superintendent : 22 posts
  5. Junior Technician : 13 posts
  6. Junior Assistant : 10 posts
  7. Assistant Coach : 04 posts
How to Apply :  Apply Online at IIT Kanpur website on or before 05/05/2014 only.

Online application form,  http://www.iitk.ac.in/infocell/recruitment/

Job for Faculty National Institute of Technology

Advertisement for Faculty Positions

NIT Arunachal Pradesh  invites Online applications from Indian nationals for following Faculty posts :

  • Professor / Associate Professor : in Computer Science & Engineering/ Electronics & Communication Engineering/ Electrical Engineering 
  • Assistant Professor : in Civil Engineering/ Mechanical Engineering / Mathematics
Application Fee : Rs.600/- (Rs.150/- for SC/ST) in the form of Bank Draft, payable  in favour of National Institute of Technology payable at SBI, Nirjuli.

How to Apply : Apply Online at NIT Arunachal website and send printout of the system generated application form should be dispatched through Speed Post/Registered Post on or before 31/05/2014 to The Confidential Assistant (Miss Abi Tayeng),  National Institute of Technology (NIT), Arunachal Pradesh, Yupia, District Papum Pare,  Arunachal Pradesh - 791112 

View Details:-  http://www.nitap.in/Vacancies.aspx  

Jobs Executives-HINDUSTAN COPPER LIMITED

HINDUSTAN COPPER LIMITED
Hindustan Copper Limited (HCL) invites online applications from qualified and experienced Indian Nationals  for the following 60 posts of Executives in various disciplines and grades in :

  1. Dy. General Manager : 02 posts
  2. Assistant General Manager : 02 posts
  3. Chief Manager : 08 posts
  4. Senior Manager : 03 posts
  5. Manager : 02 posts
  6. Deputy Manager : 16 posts
  7. Assistant Manager : 27 posts
Freshers will be taken as Graduate Engineer Trainee (GET) / Management Trainee (MT)

Application Fee :  Rs.750/- in the form of DD in favour of Hindustan Copper Limited payable at Kolkata. Rs. 250/- from SC/ST/PWD/ Female candidates.
 Apply Online at Hindustan Copper website from 17/04/2014 to 16/05/2014 only.
Online application form:-  http://www.hindustancopper.com/career.asp