AnatolyUss / nmig

NMIG is a database migration tool, written in Node.js and highly inspired by FromMySqlToPostgreSql.
GNU General Public License v3.0
451 stars 83 forks source link

ALTER COLUMN "default_value" SET DEFAULT 'b'0'' #89

Closed ScoobyMax closed 2 years ago

ScoobyMax commented 2 years ago

A lot of errors on my migration:


        --[DefaultProcessor::default] error: ошибка синтаксиса (примерное положение: "1")

        SQL: ALTER TABLE "public"."project_status" ALTER COLUMN "can_delete" SET DEFAULT 'b'1'';

        --[DefaultProcessor::default] error: ошибка синтаксиса (примерное положение: "0")

        SQL: ALTER TABLE "public"."project_status" ALTER COLUMN "show_in_status_history" SET DEFAULT 'b'0'';
ScoobyMax commented 2 years ago

Source mysql table columns like:

    deleted                   bit default b'0'              not null,
    completed              bit default b'0'              not null,
    readonly                 bit default b'0'              not null,
    warning                  bit default b'0'              not null,

I guess that the boolean type should turn out

AnatolyUss commented 2 years ago

Hello Maxim, I'll check it asap. (today-tomorrow)

On Tue, Feb 8, 2022 at 8:18 AM Maxim Petrishchev @.***> wrote:

Source mysql table columns like:

deleted                   bit default b'0'              not null,
completed              bit default b'0'              not null,
readonly                 bit default b'0'              not null,
warning                  bit default b'0'              not null,

I guess that the boolean type should turn out

— Reply to this email directly, view it on GitHub https://github.com/AnatolyUss/nmig/issues/89#issuecomment-1032251449, or unsubscribe https://github.com/notifications/unsubscribe-auth/ADHR7N3G7NGY57OU4KRFBWTU2CYTPANCNFSM5NZLM2MQ . Triage notifications on the go with GitHub Mobile for iOS https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675 or Android https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub.

You are receiving this because you are subscribed to this thread.Message ID: @.***>

AnatolyUss commented 2 years ago

Hello again, The issue is fixed in the latest release (Nmig v5.6.0) Please, pull latest changes from master, If still relevant. Sorry for the delay.