PHP mysql bigint issue

前端 未结 3 1055
我寻月下人不归
我寻月下人不归 2020-12-19 17:16

I have two tables with bigint:

table1
id bigint(20) PK autoincrement
name varchar(40),
text

table2
id bigint(20) PK autoincrement
created datetime
text_fiel         


        
3条回答
  •  無奈伤痛
    2020-12-19 17:54

    It's also the case that PHP under at least some 64-bit operating systems (eg FreeBSD AMD64) uses an 8-byte int, verifiable by testing with

    echo 'Size of int is '.PHP_INT_SIZE ;

    So if you're only going to be running a 64-bit operating system, you shouldn't need to manage the BIGINTs as strings in PHP.

提交回复
热议问题