Joinutility seperatorLogin utility seperator Infobright.com
   
 
Some standard datatypes are not supported
Posted: 16 November 2008 10:12 AM   Ignore ]  
Newbie
Rank
Total Posts:  2
Joined  2008-11-16

Here is the Create Table I did trying to migrate some data:

mysql> CREATE TABLE `performance_log_080601` ( -> `ip` varchar(15) NOT NULL,
-> `server_ip` varchar(25) NOT NULL,
-> `page` varchar(255) NOT NULL,
-> `utime` float NOT NULL,
-> `wtime` float NOT NULL,
-> `mysql_time` float NOT NULL,
-> `sphinx_time` float NOT NULL,
-> `mysql_count_queries` int(11) NOT NULL,
-> `mysql_queries` text NOT NULL,
-> `stime` float NOT NULL,
-> `logged` timestamp NOT NULL default CURRENT_TIMESTAMP on update CURRENT_TIMESTAMP,
-> `user_agent` varchar(255) NOT NULL,
-> `referer` varchar(255) NOT NULL,
-> `key` varchar(32) NOT NULL default ‘’,
`is_new_seo` tinyint(3) unsigned NOT NULL default ‘0’,
-> `country_code` varchar(5) NOT NULL default ‘’,
-> `ad_type` varchar(20) NOT NULL default ‘’,
-> `is_new_seo` tinyint(3) unsigned NOT NULL default ‘0’,
-> `bot` enum(’’,’google’,’yahoo’,’msn’,’lycos’,’infoseek’,’altavista’,’baidu’,’yodao’,’ask’,’voila’,’twiceler’,’holmes’,’sosospider’,’yeti’,’sogou’,’rixbot’,’mlbot’,’newsgator’,’gigabot’,’archive.org’,’google adsense’) NOT NULL,
-> `page_type` enum(’’,’search’,’ajax’,’forumprofile’,’siteprofile’,’threadprofile’,’topicprofile’,’domainprofile’,’iconws’,’graphdata’,’linksGraphXML’,’rss’,’jump’,’ad’,’imagesearch’,’forumsearch’) NOT NULL
-> );
ERROR 8 (HY000): Unsupported data type.

The type ENUM as well as UNSIGNED flag for TINYINT are not supported.

Furthermore the error message is not overly helpful - it would be much nicer to report which data type was not supported. You at least could use WARNING for this purpose if Error message can’t be modified easily.

Profile
 
Posted: 16 November 2008 03:08 PM   Ignore ]   [ # 1 ]  
Jr. Member
Avatar
RankRank
Total Posts:  97
Joined  2008-08-18

Hi Peter,

You may safely use “VARCHAR(...) comment ‘lookup’ “ instead of ENUM and INT instead of UNSIGNED TINYINT. It should behave similarly from performance/storage point of view.
About TEXT type: if there is any reasonable limitation for size, it is better to use VARCHAR. Even VARCHAR(10000) will behave better than TEXT.

Best regards,

[ Edited: 16 November 2008 05:23 PM by Jakub Wroblewski]
Signature 
Profile
 
Posted: 16 November 2008 09:23 PM   Ignore ]   [ # 2 ]  
Newbie
Rank
Total Posts:  2
Joined  2008-11-16

Sure,

I know the workaround.  I just thought for community edition in particular you would wish things to “just work” and them tune them later.

I spend a lot of time on OpenSQLCamp with Alex Esterkin today so he should bring some more issues back home smile

Profile