Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Bo Petersen 28 posts 61 karma points
    Jul 27, 2011 @ 12:01
    Bo Petersen
    0

    MySQL support

    Hello friends i have a converted table structure for Umbraco websites running MySql.

    But somehow the code returns an error

    MySql.Data.MySqlClient.MySqlException: Unknown column 'PARENT' in 'where clause' ???

    please help

    for MySql use this script:

    USE `YourDatabase.Table`; 

    CREATE TABLE IF NOT EXISTS `CMSImportState` (
        `Id` int NOT NULL AUTO_INCREMENT,
        `UniqueIdentifier` char(36) NOT NULL,
        `Name` varchar(250) NOT NULL,
        `ImportType` varchar(250) NOT NULL,
        `ImportState` varchar(4000) NOT NULL,
        PRIMARY KEY (`Id`)
    );

    CREATE TABLE IF NOT EXISTS `CMSImportScheduledTask` (
        `ScheduleId` int NOT NULL AUTO_INCREMENT,
        `ScheduleGUID` char(36) NOT NULL,
        `ImportStateGUID` char(36) NOT NULL,
        `ScheduledTaskName` varchar(50) NOT NULL,
        `NotifyEmailAddress` varchar(250) NOT NULL,
        `ExecuteEvery` varchar(50) NOT NULL,
        `ExecuteDays` varchar(50) NOT NULL,
        `ExecuteHour` int NOT NULL,
        `ExecuteMinute` int NOT NULL,
       PRIMARY KEY (`ScheduleId`)
    );

    CREATE TABLE IF NOT EXISTS `CMSImportRelation` (
        `Id` int NOT NULL AUTO_INCREMENT,
        `UmbracoID` int NOT NULL,
        `UmbracoParentId` int NOT NULL,
        `DataSourceKey` varchar(250) NOT NULL,
        PRIMARY KEY (`Id`)
    );

    CREATE TABLE IF NOT EXISTS `CMSImportMediaRelation` (
        `Id` int NOT NULL AUTO_INCREMENT,
        `UmbracoMediaId` int NOT NULL,
        `SourceUrl` varchar(500) NOT NULL,
        PRIMARY KEY (`Id`)
    );

    CREATE TABLE IF NOT EXISTS `CMSImportScheduledItems` (
        `ScheduledItemId` int NOT NULL AUTO_INCREMENT,
        `ScheduleldTaskId` int NOT NULL,
        `ScheduledOn` timestamp NOT NULL,
        `ExecutedOn` timestamp NULL,
        PRIMARY KEY (`ScheduledItemId`)
    );

    CREATE TABLE IF NOT EXISTS `CMSImportCustomRelation` (
        `CustomRelationId` int NOT NULL AUTO_INCREMENT,
        `UmbracoId` int NOT NULL,
        `Alias` nvarchar(250) NOT NULL,
        `DataSourceKey` nvarchar(250) NOT NULL,
        `RelatedId` nvarchar(250) NOT NULL,
        PRIMARY KEY (`CustomRelationId`)
    );

  • Bo Petersen 28 posts 61 karma points
    Jul 27, 2011 @ 14:09
    Bo Petersen
    1

    Found out i was missing the 

    `Recursive` bit NULL,
    `Parent` char(36) NULL,

    on CMSImportState table

    AND

    `InProgress` bit NULL,

    on CMSImportScheduledItems table

     

  • Bo Petersen 28 posts 61 karma points
    Jul 27, 2011 @ 15:39
    Bo Petersen
    0

    Download CMSImport 2.0 Package with mysql support from here http://techhouse.dk/download/CMSImport-2.0-mysql.zip


  • Richard Soeteman 4049 posts 12922 karma points MVP 2x
    Jul 28, 2011 @ 09:01
    Richard Soeteman
    0

    Hi Bo,

    Great that you found a way to support MySql. I think I will update the execute sql packageaction to support install scripts for multiple datalayers and will include your fix in the next release if you don't mind?

    Thanks,

    Richard

  • Bo Petersen 28 posts 61 karma points
    Jul 28, 2011 @ 12:33
    Bo Petersen
    0

    No problem, This is your project, only wish i have - is to be credited within your package for MySql script :-)

Please Sign in or register to post replies

Write your reply to:

Draft