自2014年6月24日起,Google已将reference
和id
字段标记为已弃用,并将其替换为一个place_id
。
到目前为止,我只看到place_id
的长度恰好是27个字符,但是想知道是否有任何文档说明该长度吗? 我在任何地方都找不到此文档。
显然,知道place_id
的长度对于选择最佳数据库字段很重要,因此我想知道一些信息。
从Google Places API docs网站:
The id and reference fields are deprecated as of June 24, 2014. They are replaced by the new place ID, a unique identifier that can be used to compare places and to retrieve information about a place. The Places API currently returns a place_id in all responses, and accepts a placeid in the Place Details and Place Delete requests. Soon after June 24, 2015, the API will stop returning the id and reference fields in responses. Some time later, the API will no longer accept the reference in requests. We recommend that you update your code to use the new place ID instead of id and reference as soon as possible.
最佳答案
没有关于特定长度的文档,但是我看到的最大长度是 255 。这对应于地址10,曼谷Suan Luang的488 Srinagarindra Rd.。您可以检查地点ID here。
仅供引用,地点编号为:ErwBNDg4IOC4luC4meC4mSDguKjguKPguLXguJnguITguKPguLTguJnguJfguKPguYwg4LmB4LiC4Lin4LiHIOC4quC4p-C4meC4q-C4peC4p-C4hyDguYDguILguJUg4Liq4Lin4LiZ4Lir4Lil4Lin4LiHIOC4geC4o-C4uOC4h-C5gOC4l-C4nuC4oeC4q-C4suC4meC4hOC4oyAxMDI1MCDguJvguKPguLDguYDguJfguKjguYTguJfguKI
关于google-places-api - Google Places API place_id字段长度,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/24430241/