Aurora 2 to 3 Pre-checks Failure due to Reserved Keywords in mysql routine function

0

I've been attempting to do an Aurora 2 to 3 in place upgrade on our database cluster and it refuses because of a routinesSyntaxCheck failure on some of our custom routines in our DB. There are indeed reserved keywords in our routines but never by themselves and the functions themselves don't have any reserved keywords. I've attempted to put the routine declarations in the schema in backticks but that doesn't seem to work either.

I'm able to create my DB schema on a fresh Aurora 3 cluster without any complaints and I can use the routines just fine. Its just when I attempt the 2 to 3 upgrade that it complains about those routines. The strange part is that the line it complains about is always line 0,38 or 0,37 which doesn't make sense to me either as that line shouldn't exist afaik. I've attached an example of the routine below (the company name doesn't contain a reserved keyword either)

{
    "serverAddress": "/tmp%2Fmysql.sock",
    "serverVersion": "5.7.12-log - MySQL Community Server (GPL)",
    "targetVersion": "8.0.28",
    "auroraServerVersion": "2.11.1",
    "auroraTargetVersion": "3.04.2",
    "outfilePath": "/rdsdbdata/tmp/PreChecker.log",
    "checksPerformed": [
        {
            "id": "oldTemporalCheck",
            "title": "Usage of old temporal type",
            "status": "OK",
            "detectedProblems": []
        },
        {
            "id": "routinesSyntaxCheck",
            "title": "MySQL 8.0 syntax check for routine-like objects",
            "status": "OK",
            "description": "The following objects did not pass a syntax check with the latest MySQL 8.0 grammar. A common reason is that they reference names that conflict with new reserved keywords. You must update these routine definitions and `quote` any such references before upgrading.",
            "documentationLink": "https://dev.mysql.com/doc/refman/en/keywords.html",
            "detectedProblems": [
                {
                    "level": "Error",
                    "dbObject": "companyname.CLEAR_CHANNEL",
                    "description": "at line 0,38: unexpected token '\"CLEAR_CHANNEL\"'"
                },
Gsalam7
질문됨 한 달 전460회 조회
1개 답변
0

Hi,

This previous answer on re:Post has a solution for your case: https://repost.aws/questions/QU_jfgd2gURk6TzL8JcQCO9Q/error-upgrading-mysql-5-7-to-8-0

Best,

Didier

profile pictureAWS
전문가
답변함 한 달 전

로그인하지 않았습니다. 로그인해야 답변을 게시할 수 있습니다.

좋은 답변은 질문에 명확하게 답하고 건설적인 피드백을 제공하며 질문자의 전문적인 성장을 장려합니다.

질문 답변하기에 대한 가이드라인

관련 콘텐츠