Create tables in a mysql database hosted on Locaweb

0

I need to add a table in my database. How do I add a table to this bank hosted on locaweb? Do you have to have any software or can I upload some files?

    
asked by anonymous 18.11.2016 / 13:36

1 answer

3

You must enter the cPanel of the domain in question, click on the icon for phpMyAdmin and on the top menu bar click the SQL tab. It will open a text area where you will type the command to add a table.

Following this template:

CREATE TABLE table_name
(
column_name1 data_type(size),
column_name2 data_type(size),
column_name3 data_type(size),
....
);

An example:

CREATE TABLE MyGuests (
id INT(6) UNSIGNED AUTO_INCREMENT PRIMARY KEY,
firstname VARCHAR(30) NOT NULL,
lastname VARCHAR(30) NOT NULL,
email VARCHAR(50),
reg_date TIMESTAMP
)
    
18.11.2016 / 13:52