How will you create a mysql database using php ?

Answers were Sorted based on User's Feedback



How will you create a mysql database using php ?..

Answer / suma

mysql_create_db('dbname')

Is This Answer Correct ?    30 Yes 1 No

How will you create a mysql database using php ?..

Answer / modi[achir communication]

<?php

$linkid = mysql_connect("servername", "username", "password");
mysql_query("CREATE DATABASE db");
mysql_select_db("db");

mysql_query("CREATE TABLE table (...)");

?>

Is This Answer Correct ?    5 Yes 2 No

How will you create a mysql database using php ?..

Answer / mruttu

mysql_connect('servername','username','password');

Is This Answer Correct ?    5 Yes 18 No

Post New Answer

More PHP Interview Questions

What is filter_var?

0 Answers  


What is the meaning of die in php?

0 Answers  


Tell me are parent constructors called implicitly inside a class constructor?

0 Answers  


How to create a text file in PHP?

0 Answers  


What is difference between static and constant?

0 Answers  






How can we optimize or increase the speed of a mysql select query?

6 Answers  


how to select the multiple data in selection button

1 Answers   xasis technologies,


What are Routines?

0 Answers  


which is the best institute for php training near delhi & NCR......& what is the fee for the same....

2 Answers  


What is session in php w3schools?

0 Answers  


Does php has a future?

0 Answers  


What is the use of mvc in php?

0 Answers  


Categories