Its me ZovkT

[SOLVED] DB ERROR NEW UPDATE!

13 posts in this topic

anyone can help me ?

i become this error.  i make the DB complete New.

19:08:07    CREATE TABLE `clan` (   `id` int(11) UNSIGNED NOT NULL,   `name` varchar(64) NOT NULL,   `leader_uid` varchar(32) NOT NULL,   `created_at` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP,   `insignia_texture` varchar(255) DEFAULT NULL ) ENGINE=InnoDB DEFAULT CHARSET=utf8    Error Code: 1046. No database selected Select the default DB to be used by double-clicking its name in the SCHEMAS list in the sidebar.    0.000 sec

 

Share this post


Link to post
Share on other sites
Advertisement

Create a new database called exile then execute the exile.sql there.

Also, to the op, make sure you're running at least MySQL 5.6 or higher as the new database syntax won't work with older versions.

Edited by MGTDB
  • Like 1

Share this post


Link to post
Share on other sites
11 minutes ago, Verazon said:

#1067 - Invalid default value for 'first_connect_at' 

What is up with that?

 

17 minutes ago, MGTDB said:

make sure you're running at least MySQL 5.6 or higher as the new database syntax won't work with older versions.

 

Share this post


Link to post
Share on other sites

Can anyone help me also with this? got same problem as posted above with:
CREATE TABLE `account` (
   `uid` varchar(32) NOT NULL,
   `clan_id` int(11) UNSIGNED DEFAULT NULL,
   `name` varchar(64) NOT NULL,
   `money` double NOT NULL DEFAULT '0',
   `score` int(11) NOT NULL DEFAULT '0',
   `kills` int(11) UNSIGNED NOT NULL DEFAULT '0',
   `deaths` int(11) UNSIGNED NOT NULL DEFAULT '0',
   `first_connect_at` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP,
   `last_connect_at` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP,
   `last_disconnect_at` datetime DEFAULT NULL,
   `total_connections` int(11) UNSIGNED NOT NULL DEFAULT '1'
 ) ENGINE=InnoDB DEFAULT CHARSET=utf8Error Code: 1046. No database selected
 Select the default DB to be used by double-clicking its name in the SCHEMAS list in the sidebar.0.000 sec

Got latest version of MSQL / workbench 6.3.6

msqlerror.PNG

Edited by HeadRox

Share this post


Link to post
Share on other sites
15 minutes ago, HeadRox said:

Can anyone help me also with this? got same problem as posted above with:
CREATE TABLE `account` (
   `uid` varchar(32) NOT NULL,
   `clan_id` int(11) UNSIGNED DEFAULT NULL,
   `name` varchar(64) NOT NULL,
   `money` double NOT NULL DEFAULT '0',
   `score` int(11) NOT NULL DEFAULT '0',
   `kills` int(11) UNSIGNED NOT NULL DEFAULT '0',
   `deaths` int(11) UNSIGNED NOT NULL DEFAULT '0',
   `first_connect_at` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP,
   `last_connect_at` datetime NOT NULL DEFAULT CURRENT_TIMESTAMP,
   `last_disconnect_at` datetime DEFAULT NULL,
   `total_connections` int(11) UNSIGNED NOT NULL DEFAULT '1'
 ) ENGINE=InnoDB DEFAULT CHARSET=utf8Error Code: 1046. No database selected
 Select the default DB to be used by double-clicking its name in the SCHEMAS list in the sidebar.0.000 sec

Got latest version of MSQL / workbench 6.3.6

msqlerror.PNG

Select a database on the left side that you want to execute the code on...

Share this post


Link to post
Share on other sites
6 minutes ago, Taylor Swift said:

Select a database on the left side that you want to execute the code on...

You mean 'sakila, test or world' ?

Share this post


Link to post
Share on other sites
5 minutes ago, HeadRox said:

You mean 'sakila, test or world' ?

Create a new one called "Exile"

Share this post


Link to post
Share on other sites
Advertisement
Guest
This topic is now closed to further replies.

  • Recently Browsing   0 members

    No registered users viewing this page.