apache / apache/incubator-seata

PG作为业务数据库,不支持数组下标更新sql

Open
#3,992 1 comment 0 reactions 0 assignees View on GitHub
task: help-wanted
Dominant language
Java
Stars
26k
Forks
8.8k
Avg merge
1d 8h
Merged PRs (30d)
4

Description

- [ ] I have searched the [issues](https://github.com/seata/seata/issues) of this repository and believe that this is not a duplicate.

### Ⅰ. Issue Description
PG作为业务数据库,不支持数组下标更新sql

### Ⅱ. Describe what happened

update t_user set money[1]=100.0 where id=1

```
Cause: com.alibaba.druid.sql.parser.ParserException: syntax error, expect EQ, actual LBRACKET
```

### Ⅲ. Describe what you expected to happen

该语句应该合法,提示异常

Contributor guide

Open the contributing guide

Research direction

Start by reproducing the PostgreSQL statement `update t_user set money[1]=100.0 where id=1` and tracing the reported `com.alibaba.druid.sql.parser.ParserException` at the SQL parser. Done means the array-subscript assignment is accepted as valid SQL without the reported syntax error, with regression coverage for this statement.

Written by the indexing model from the issue text.

Assessment

Tech stack
java, postgresql, sql
Domain
backend, databases
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.