Postgre to MySQL problem

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • webandwe
    New Member
    • Oct 2006
    • 142

    #1

    Postgre to MySQL problem

    Hi

    The code below I took from a postgre file and convert it with a program to a mysql. Once i tried to import it to mysql it gave me an error and when i past in a php file to upload it trough a php file it stats I have loaded the information into the DB but i don't see any tables in the DB.

    Here is the code as it comes from my plain *.txt file. Any suggestions?

    CREATE TABLE categories (
    record int(11) auto_increment NOT NULL,
    category varchar(100),
    description text,
    picture varchar(100),
    `type` varchar(1)
    , PRIMARY KEY(`record`)
    ) TYPE=MyISAM;

    CREATE TABLE subcategories (
    record int(11) auto_increment NOT NULL,
    subcategory varchar(100),
    description text,
    categoryid int(11),
    picture varchar(100)
    , PRIMARY KEY(`record`)
    ) TYPE=MyISAM;

    CREATE TABLE images (
    record int(11) auto_increment NOT NULL,
    title varchar(100),
    description text,
    subcategoryid int(11),
    `type` varchar(1),
    picture varchar(100),
    thumbnail varchar(100),
    `position` int(11)
    , PRIMARY KEY(`record`)
    ) TYPE=MyISAM;

    CREATE TABLE posters (
    record int(11) auto_increment NOT NULL,
    title varchar(100),
    description text,
    `type` varchar(1),
    picture varchar(100),
    `position` int(11),
    thumbnail varchar(100)
    , PRIMARY KEY(`record`)
    ) TYPE=MyISAM;

    CREATE TABLE bannerads (
    record int(11) auto_increment NOT NULL,
    description text,
    hyperlink varchar(50),
    email varchar(30),
    adtype varchar(10),
    picture varchar(100),
    thumbnail varchar(100),
    loaded bigint
    , PRIMARY KEY(`record`)
    ) TYPE=MyISAM;

    CREATE TABLE payments (
    record int(11) auto_increment NOT NULL,
    fullname varchar(100),
    address text,
    city varchar(50),
    postalcode varchar(8),
    email varchar(100),
    contactnum varchar(15),
    product varchar(10),
    productid int(11),
    prsize varchar(20),
    prframe varchar(20),
    price varchar(10),
    trsuc int(11)
    , PRIMARY KEY(`record`)
    ) TYPE=MyISAM;

    CREATE TABLE users (
    record int(11) auto_increment NOT NULL,
    surname varchar(50),
    firstname varchar(50),
    username varchar(20),
    `password` text,
    confirm text,
    registerdate bigint,
    active varchar(1),
    avatarid int(11),
    signature text,
    url text,
    email varchar(100),
    showemail varchar(1),
    isadmin varchar(1),
    avatar varchar(100)
    , PRIMARY KEY(`record`)
    ) TYPE=MyISAM;

    CREATE TABLE avatars (
    record int(11) auto_increment NOT NULL,
    image varchar(100)
    , PRIMARY KEY(`record`)
    ) TYPE=MyISAM;

    CREATE TABLE forums (
    record int(11) auto_increment NOT NULL,
    name varchar(100),
    description text,
    lastdate bigint,
    lastposter int(11)
    , PRIMARY KEY(`record`)
    ) TYPE=MyISAM;

    CREATE TABLE posts (
    record int(11) auto_increment NOT NULL,
    forumid int(11),
    userid int(11),
    subject text,
    date bigint,
    replies int(11),
    message text,
    parent int(11)
    , PRIMARY KEY(`record`)
    ) TYPE=MyISAM;

    CREATE TABLE smilies (
    record int(11) auto_increment NOT NULL,
    image varchar(100),
    code varchar(10),
    emotion varchar(20)
    , PRIMARY KEY(`record`)
    ) TYPE=MyISAM;

    CREATE TABLE basket (
    record int(11) auto_increment NOT NULL,
    price double precision,
    product varchar(10),
    size varchar(20),
    frame varchar(20),
    pic int(11),
    qty int(11),
    userid varchar(6),
    sel int(11)
    , PRIMARY KEY(`record`)
    ) TYPE=MyISAM;

    CREATE TABLE orders (
    record int(11) auto_increment NOT NULL,
    userid varchar(6),
    referencenr varchar(20),
    date bigint,
    paid varchar(1),
    countryid int(11)
    , PRIMARY KEY(`record`)
    ) TYPE=MyISAM;

    CREATE TABLE addresses (
    record int(11) auto_increment NOT NULL,
    listid int(11),
    email varchar(50)
    , PRIMARY KEY(`record`)
    ) TYPE=MyISAM;

    CREATE TABLE lists (
    record int(11) auto_increment NOT NULL,
    name varchar(50)
    , PRIMARY KEY(`record`)
    ) TYPE=MyISAM;

    CREATE TABLE newsletteritems (
    record int(11) auto_increment NOT NULL,
    newsletterid int(11),
    heading varchar(100),
    bgcolor int(11),
    item text,
    image varchar(60),
    columnno int(11),
    rowno int(11),
    pos int(11)
    , PRIMARY KEY(`record`)
    ) TYPE=MyISAM;

    CREATE TABLE newsletters (
    record int(11) auto_increment NOT NULL,
    date bigint,
    heading varchar(30)
    , PRIMARY KEY(`record`)
    ) TYPE=MyISAM;

    CREATE TABLE medialogon (
    record int(11) auto_increment NOT NULL,
    username varchar(50),
    `password` varchar(50),
    publication_nam e varchar(50),
    city varchar(50),
    country varchar(50),
    firstname varchar(50),
    surname varchar(50),
    email varchar(50),
    active varchar(1),
    confirmhash varchar(100)
    , PRIMARY KEY(`record`)
    ) TYPE=MyISAM;

    CREATE TABLE calendars (
    record int(11) auto_increment NOT NULL,
    title varchar(100),
    image varchar(100),
    `position` int(11),
    price double precision,
    thumbnail varchar(100)
    , PRIMARY KEY(`record`)
    ) TYPE=MyISAM;

    CREATE TABLE calendarimages (
    record int(11) auto_increment NOT NULL,
    title varchar(100),
    calendarid int(11),
    image varchar(100),
    `position` int(11),
    thumbnail varchar(100)
    , PRIMARY KEY(`record`)
    ) TYPE=MyISAM;

    CREATE TABLE whatsnew (
    record int(11) auto_increment NOT NULL,
    title varchar(100),
    description text,
    date bigint,
    link text
    , PRIMARY KEY(`record`)
    ) TYPE=MyISAM;

    CREATE TABLE capitalsound (
    record int(11) auto_increment NOT NULL,
    mpic varchar(100),
    subpic1 varchar(100),
    subpic2 varchar(100),
    subpic3 varchar(100),
    capsound varchar(100),
    brianemm varchar(100),
    lshow varchar(100),
    tpic1 varchar(100),
    tpic2 varchar(100),
    tpic3 varchar(100),
    tpic4 varchar(100),
    tpic5 varchar(100)
    , PRIMARY KEY(`record`)
    ) TYPE=MyISAM;

    CREATE TABLE capitalsub (
    record int(11) auto_increment NOT NULL,
    category varchar(100),
    pic varchar(100)
    , PRIMARY KEY(`record`)
    ) TYPE=MyISAM;

    CREATE TABLE shopcats (
    record int(11) auto_increment NOT NULL,
    name varchar(50),
    description text,
    parent int(11)
    , PRIMARY KEY(`record`)
    ) TYPE=MyISAM;

    CREATE TABLE shopimages (
    record int(11) auto_increment NOT NULL,
    title varchar(100),
    description text,
    catid int(11),
    picture varchar(100),
    `position` int(11),
    thumbnail varchar(100),
    price double precision
    , PRIMARY KEY(`record`)
    ) TYPE=MyISAM;

    CREATE TABLE article (
    record int(11) auto_increment NOT NULL,
    date bigint,
    title text,
    article text,
    thumbnail text
    , PRIMARY KEY(`record`)
    ) TYPE=MyISAM;

    CREATE TABLE newsletter (
    record int(11) auto_increment NOT NULL,
    date bigint,
    title varchar(100),
    article text
    , PRIMARY KEY(`record`)
    ) TYPE=MyISAM;

    CREATE TABLE classcats (
    record int(11) auto_increment NOT NULL,
    parent int(11),
    description text,
    name varchar(50)
    , PRIMARY KEY(`record`)
    ) TYPE=MyISAM;

    CREATE TABLE classmodel (
    record int(11) auto_increment NOT NULL,
    title varchar(100),
    description text,
    catid int(11),
    picture varchar(100),
    `position` int(11),
    thumbnail varchar(100),
    price double precision,
    contactperson varchar(50),
    email varchar(50)
    , PRIMARY KEY(`record`)
    ) TYPE=MyISAM;

    CREATE TABLE orderitems (
    record int(11) auto_increment NOT NULL,
    price double precision,
    product varchar(10),
    size varchar(20),
    frame varchar(20),
    pic int(11),
    qty int(11),
    orderid varchar(6)
    , PRIMARY KEY(`record`)
    ) TYPE=MyISAM;

    CREATE TABLE phpbb_auth_acce ss (
    group_id int(11) DEFAULT 0 NOT NULL,
    forum_id smallint DEFAULT 0,
    auth_view smallint DEFAULT 0,
    auth_read smallint DEFAULT 0,
    auth_post smallint DEFAULT 0,
    auth_reply smallint DEFAULT 0,
    auth_edit smallint DEFAULT 0,
    auth_delete smallint DEFAULT 0,
    auth_sticky smallint DEFAULT 0,
    auth_announce smallint DEFAULT 0,
    auth_vote smallint DEFAULT 0,
    auth_pollcreate smallint DEFAULT 0,
    auth_attachment s smallint DEFAULT 0,
    auth_mod smallint DEFAULT 0
    ) TYPE=MyISAM;
  • webandwe
    New Member
    • Oct 2006
    • 142

    #2
    Hi

    The coding for the mysql was to long, i put it on a html page and uploaded to this link:

    http://www.websitedesi gnlab.co.za/msql.html

    Kind Regards
    Wevbandwe

    Comment

    Working...