Jump to content

[SOLVED] confusion with names


asmith

Recommended Posts

these names has made me so messed up .

 

when i study php on my computer , i had localhost and mysql been set up ...

 

i had a username and passwords for "entering" mysql ,  then after logging i gave a user privilage for php coding like :

 

mysql_connect("localhost","user","pass");

 

and i had created database with names "user" , "site_info"    IN THE mysql . and so on ...

 

the confussion i have now is  :

 

i've get a hosting package , it has said i can have 3 mysql databases.

 

first question is i can have 3 databases IN mysql database ?  (like my "user" and "site_info" )      OR 

i can have 3 copy of the mysql database (3 mysql softwares?)

 

my site works with cpanel.

in the mysql link , there is "create database" part . i let me create 3 databases, i tried to create more ,but it said i have my 3 databases, now in there i can create users with password and add them to these databases .

 

when i added database "test1"  , it added  "mydomain_test1"  . 

now in all php pages i've write,  for example there are mysql_select_db("test1") , i should change all to mysql_select_db("mydomain_test1")  (assumin i can have 3 databases INSIDE one mysql database ) ...

 

!!!?  !!?  !!?!?!

 

(please talk in my language , like  3 IN  one mysql , or 3 mysql copies . .so i can understand ..    thanks in advance)

 

 

Link to comment
Share on other sites

when i added database "test1"  , it added  "mydomain_test1"  .  

now in all php pages i've write,  for example there are mysql_select_db("test1") , i should change all to mysql_select_db("mydomain_test1")   (assumin i can have 3 databases INSIDE one mysql database ) ...

You need to give mysql_select_db() the actual name of your database, i.e. mydomain_test1.

 

first question is i can have 3 databases IN mysql database ?  (like my "user" and "site_info" )

When you've created the database then you can have as many tables as you would like inside that database.

 

(please talk in my language , like  3 IN  one mysql , or 3 mysql copies . .so i can understand ..     thanks in advance)

Seeing as you have a curious way of using punctuation and spacing I don't think that will be possible ;)

Link to comment
Share on other sites

thanks for replying  , 

 

the thing i think has made me confused here is  i can have as many databases here on my localhost in mysql database, using :

 

create database example1

 

then in those databases i can have as many tables i want to . 

so in mysql in localhost  can have infinite databases with infinite tables .

 

but now i'm being limited to 3 databases, that was the point ...

 

so , i have to search all the codes and made every "test1" to "mydomian_test1"  ??

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.