Skip to content

Category: 未分类

为什么ID使用Int而不是unsigned int

最近公司把某些业务实体的ID从int32迁移到了int64。这些ID的合法数据都是大于1的,为什么不选择unsigned int64 而要选择 int64 呢? unsigned 类型相对来说可用的合法id可是大了一倍呀。 有两个原因: 1, 对齐数据类型,避免溢出或其他兼容性问题 某些数据存储,如postgress是不支持unsigned integer 类型的。比如postgresSql。 PostgresSQL Type Go Type smallint, smallserial int16(-32768 ~ 32767) int, serial int32…

nextcloud使用的问题

1,使用nextcloud的android app同步数据,报错”upload failed Payload Too Large” 修改nginx 中的配置,设置上传文件的大小 2,login非常慢 ? 3,ios设备无法登录 在config/config.php 中添加配置