Skip to Content
Presto实战
book

Presto实战

by Matt Fuller, Manfred Moser, Martin Traverso
March 2021
Intermediate to advanced
265 pages
6h 50m
Chinese
Posts & Telecom Press
Content preview from Presto实战
高级
SQL
特性
171
•
ST_Contains(Geometry, Geometry) -> boolean
•
ST_Touches(Geometry, Geometry) -> boolean
•
ST_Within(Geometry, Geometry) -> boolean
•
ST_Length(Geometry) -> double
•
ST_Distance(Geometry, Geometry) -> double
•
ST_Area(SphericalGeography) -> double
Presto
文档(参见
1.4.2
节)详细介绍了
Presto
中对地理空间的支持。如果你在使用
Presto
时需要处理地理空间数据,我们强烈建议你看一下该文档。
9.22
 
Prepared Statement
Prepared Statement
是一种非常有用的方法,它可以使用不同的输入参数值运行相同的
SQL
语句。它允许重复使用
SQL
语句,
这简化了用户反复调用的麻烦,也让代码更干净、更易
于维护。
PreparedStatement
是保存在
Presto
用户会话中的查询。
Prepared Statement
的使用和创建分为两个步骤
PREPARE
语句用于创建语句,从而使其在
会话中可重复使用:
PREPARE example
FROM SELECT count(*) FROM hive.ontime.flights_orc;
EXECUTE
命令可用于运行一次或多次查询:
EXECUTE example; ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Start your free trial

You might also like

大数据项目管理:从规划到实现

大数据项目管理:从规划到实现

Ted Malaska, Jonathan Seidman
Google系统架构解密: 构建安全可靠的系统

Google系统架构解密: 构建安全可靠的系统

Heather Adkins, Betsy Beyer, Paul Blankinship, Piotr Lewandowski, Ana Oprea, Adam Stubblefield

Publisher Resources

ISBN: 9787115560056