From 36676c61dc84a7b7b16254a353d4b0ae8b089d01 Mon Sep 17 00:00:00 2001 From: Karson Date: Wed, 17 Mar 2021 17:41:19 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8DPHP7.4=E4=B8=8B=E6=95=B0?= =?UTF-8?q?=E7=BB=84=E6=88=96=E5=AD=97=E7=AC=A6=E4=B8=B2=E8=AF=BB=E5=8F=96?= =?UTF-8?q?=E6=97=B6=E7=9A=84=E5=85=BC=E5=AE=B9=E6=80=A7BUG?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Karson --- library/think/db/Query.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/library/think/db/Query.php b/library/think/db/Query.php index bb16a1f5..37310f5c 100644 --- a/library/think/db/Query.php +++ b/library/think/db/Query.php @@ -397,7 +397,7 @@ class Query $seq = (ord(substr($type($value), 0, 1)) % $rule['num']) + 1; } else { // 按照字段的首字母的值分表 - $seq = (ord($value{0}) % $rule['num']) + 1; + $seq = (ord($value[0]) % $rule['num']) + 1; } } return $this->getTable() . '_' . $seq;