A value is expected to be in well-known text format, but there is no validation on client side.
Polygons areoriented.
It means that, for example, valuePOLYGON((0 0, 1 0, 1 1, 0 1, 0 0))represents a (almost) square region,
andPOLYGON((0 0, 0 1, 1 1, 1 0, 0 0))represents the whole Earth surface except that square.
Example:
use Google\Cloud\BigQuery\BigQueryClient;
$bigQuery = new BigQueryClient();
$geography = $bigQuery->geography('POINT(30 60)');
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Hard to understand","hardToUnderstand","thumb-down"],["Incorrect information or sample code","incorrectInformationOrSampleCode","thumb-down"],["Missing the information/samples I need","missingTheInformationSamplesINeed","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-09-04 UTC."],[],[],null,["# BigQuery Client - Class Geography (1.34.0)\n\nVersion latestkeyboard_arrow_down\n\n- [1.34.0 (latest)](/php/docs/reference/cloud-bigquery/latest/Geography)\n- [1.33.1](/php/docs/reference/cloud-bigquery/1.33.1/Geography)\n- [1.32.0](/php/docs/reference/cloud-bigquery/1.32.0/Geography)\n- [1.31.1](/php/docs/reference/cloud-bigquery/1.31.1/Geography)\n- [1.30.3](/php/docs/reference/cloud-bigquery/1.30.3/Geography)\n- [1.29.0](/php/docs/reference/cloud-bigquery/1.29.0/Geography)\n- [1.28.3](/php/docs/reference/cloud-bigquery/1.28.3/Geography)\n- [1.27.0](/php/docs/reference/cloud-bigquery/1.27.0/Geography)\n- [1.26.1](/php/docs/reference/cloud-bigquery/1.26.1/Geography)\n- [1.25.1](/php/docs/reference/cloud-bigquery/1.25.1/Geography)\n- [1.24.2](/php/docs/reference/cloud-bigquery/1.24.2/Geography)\n- [1.23.10](/php/docs/reference/cloud-bigquery/1.23.10/Geography) \nReference documentation and code samples for the BigQuery Client class Geography.\n\nRepresents a value with a data type of\n[Geography](https://cloud.google.com/bigquery/docs/reference/standard-sql/data-types#geography_type).\n\nA value is expected to be in well-known text format, but there is no validation on client side.\nPolygons are [oriented](https://cloud.google.com/bigquery/docs/gis-data#polygon_orientation).\nIt means that, for example, value `POLYGON((0 0, 1 0, 1 1, 0 1, 0 0))` represents a (almost) square region,\nand `POLYGON((0 0, 0 1, 1 1, 1 0, 0 0))` represents the whole Earth surface except that square.\n\nExample: \n\n use Google\\Cloud\\BigQuery\\BigQueryClient;\n\n $bigQuery = new BigQueryClient();\n\n $geography = $bigQuery-\u003egeography('POINT(30 60)');\n\nNamespace\n---------\n\nGoogle \\\\ Cloud \\\\ BigQuery\n\nMethods\n-------\n\n### __construct\n\n### get\n\nGet the underlying value.\n\n### type\n\nGet the type.\n\n### formatAsString\n\nFormat the value as a string.\n\n### __toString\n\nFormat the value as a string."]]