You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@shardingsphere.apache.org by "superhahastart (via GitHub)" <gi...@apache.org> on 2023/11/13 14:35:34 UTC
[I] Caused by: java.sql.SQLException: Unknown exception: Cannot invoke method div() on null object [shardingsphere]
superhahastart opened a new issue, #29029:
URL: https://github.com/apache/shardingsphere/issues/29029
maven config :
<dependency>
<groupId>org.apache.shardingsphere</groupId>
<artifactId>shardingsphere-jdbc-core</artifactId>
<version>5.4.1</version>
</dependency>
yaml config:
rules:
- !SHARDING
tables:
pay_order:
#给出一张存在的物理表,算法表达式会自动替换掉10000
actualDataNodes: ds_${0..1}.pay_order_10000_${0..32}
tableStrategy:
complex:
shardingColumns: owner_code,id
shardingAlgorithmName: pay_order_complex
keyGenerateStrategy:
column: id
keyGeneratorName: snowflake
defaultDatabaseStrategy:
standard:
shardingColumn: id
shardingAlgorithmName: database_inline
shardingAlgorithms:
database_inline:
type: INLINE
props:
algorithm-expression: ds_$->{id % 2}
pay_order_complex:
type: COMPLEX_INLINE
props:
# strategy: complex
sharding-columns: owner_code,id
# algorithmClassName: com.xskj.common.config.PayOrderComplexShardingAlgorithm
algorithm-expression: pay_order_${owner_code/1}_${id % 33}
keyGenerators:
snowflake:
type: SNOWFLAKE
sql xml:
<img width="667" alt="屏幕截图 2023-11-13 223216" src="https://github.com/apache/shardingsphere/assets/78898670/29a3f209-abc8-4d8c-9d12-bcd62470fd0f">
When a batch write is executed, the following error message is occasionally displayed:
<img width="957" alt="屏幕截图 2023-11-13 222954" src="https://github.com/apache/shardingsphere/assets/78898670/34658edb-0df9-4672-b5f9-8ecd278cc574">
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@shardingsphere.apache.org.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [I] Caused by: java.sql.SQLException: Unknown exception: Cannot invoke method div() on null object [shardingsphere]
Posted by "github-actions[bot] (via GitHub)" <gi...@apache.org>.
github-actions[bot] commented on issue #29029:
URL: https://github.com/apache/shardingsphere/issues/29029#issuecomment-1856506884
There hasn't been any activity on this issue recently, and in order to prioritize active issues, it will be marked as stale.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@shardingsphere.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [I] Caused by: java.sql.SQLException: Unknown exception: Cannot invoke method div() on null object [shardingsphere]
Posted by "terrymanu (via GitHub)" <gi...@apache.org>.
terrymanu closed issue #29029: Caused by: java.sql.SQLException: Unknown exception: Cannot invoke method div() on null object
URL: https://github.com/apache/shardingsphere/issues/29029
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@shardingsphere.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [I] Caused by: java.sql.SQLException: Unknown exception: Cannot invoke method div() on null object [shardingsphere]
Posted by "strongduanmu (via GitHub)" <gi...@apache.org>.
strongduanmu commented on issue #29029:
URL: https://github.com/apache/shardingsphere/issues/29029#issuecomment-1809358871
@superhahastart Please check the fields in groovy inline expression for null?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@shardingsphere.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org