php? Posted December 31, 2007 Share Posted December 31, 2007 Theres a guide i'm reading that says to create a database, then it gives me some code and stops. I'm wondering what i would name the database from this code provided: CREATE TABLE `users` ( `ID` int(11) NOT NULL auto_increment, `Username` varchar(255) NOT NULL, `Password` varchar(255) NOT NULL, `Temp_pass` varchar(55) default NULL, `Temp_pass_active` tinyint(1) NOT NULL default '0', `Email` varchar(255) NOT NULL, `Active` int(11) NOT NULL default '0', `Level_access` int(11) NOT NULL default '2', `Random_key` varchar(32) default NULL, PRIMARY KEY (`ID`), UNIQUE KEY `Username` (`Username`), UNIQUE KEY `Email` (`Email`) ) ENGINE=MyISAM; Quote Link to comment https://forums.phpfreaks.com/topic/83813-solved-database-help/ Share on other sites More sharing options...
rajivgonsalves Posted December 31, 2007 Share Posted December 31, 2007 You can name your database anything... however you should use meaningful names for the db.. the code you provided creates a table not a database... Quote Link to comment https://forums.phpfreaks.com/topic/83813-solved-database-help/#findComment-426454 Share on other sites More sharing options...
rameshfaj Posted December 31, 2007 Share Posted December 31, 2007 There's nothing kept in the name of the database,table and their fields. WHat you should use is some sensible names according to the context of the problem domain. Quote Link to comment https://forums.phpfreaks.com/topic/83813-solved-database-help/#findComment-426635 Share on other sites More sharing options...
drranch Posted January 1, 2008 Share Posted January 1, 2008 you must first create a database Then create the tables for the database if your using a hosting service you can create the database through them if you have an account that allows your ability to create the database. Then you can use the code you noted in your posting to create the table. The code you show above will create a table called 'users' Quote Link to comment https://forums.phpfreaks.com/topic/83813-solved-database-help/#findComment-427093 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.