sqoop-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "ASF subversion and git services (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (SQOOP-2356) Sqoop2: Derby upgrade should automatically rename jobs that have conflicting names
Date Fri, 15 May 2015 08:21:00 GMT

    [ https://issues.apache.org/jira/browse/SQOOP-2356?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14545136#comment-14545136
] 

ASF subversion and git services commented on SQOOP-2356:
--------------------------------------------------------

Commit 9ee44d4f0a5a4601cd2fd81885b44ba08e6debfd in sqoop's branch refs/heads/sqoop2 from [~gwenshap]
[ https://git-wip-us.apache.org/repos/asf?p=sqoop.git;h=9ee44d4 ]

SQOOP-2356: Sqoop2: Derby upgrade should automatically rename jobs that have conflicting names

(Abraham Elmahrek via Gwen Shapira)


> Sqoop2: Derby upgrade should automatically rename jobs that have conflicting names
> ----------------------------------------------------------------------------------
>
>                 Key: SQOOP-2356
>                 URL: https://issues.apache.org/jira/browse/SQOOP-2356
>             Project: Sqoop
>          Issue Type: Bug
>            Reporter: Abraham Elmahrek
>            Assignee: Abraham Elmahrek
>             Fix For: 1.99.7
>
>         Attachments: SQOOP-2356.patch, SQOOP-2356.patch, SQOOP-2356.patch, SQOOP-2356.patch,
SQOOP-2356.patch
>
>
> The following should work:
> {code}
> CREATE SEQUENCE job_renamer AS BIGINT START WITH 0;
> UPDATE SQOOP.SQ_JOB set SQB_NAME = SQB_NAME || '_' || CAST(NEXT VALUE FOR job_renamer
AS CHAR(100)) where SQB_ID IN (
> SELECT j1.SQB_ID FROM SQOOP.SQ_JOB AS j1 INNER JOIN ( SELECT SQB_NAME FROM SQOOP.SQ_JOB
GROUP BY (SQB_NAME) HAVING COUNT > 1 ) AS j2 ON j1.SQB_NAME = j2.SQB_NAME
> );
> drop SEQUENCE job_renamer RESTRICT;
> {code}



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Mime
View raw message