public static class BigQueryDateTimeExtensions
Reference documentation and code samples for the Google BigQuery v2 API class BigQueryDateTimeExtensions.
Extension methods for System.DateTime
and System.DateTimeOffset
for use with BigQuery.
Namespace
GoogleGoogle.CloudGoogle.Cloud.BigQueryV2Assembly
Google.Cloud.BigQuery.V2.dll
Methods
AsBigQueryDate(DateTime)
public static string AsBigQueryDate(this DateTime value)
Returns the given date and time formatted as BigQuery expects date values to be formatted.
Parameter | |
---|---|
Name | Description |
value | DateTime The date/time value to extract the date from. |
Returns | |
---|---|
Type | Description |
string | The date in yyyy-MM-dd format. |
AsBigQueryDate(DateTimeOffset)
public static string AsBigQueryDate(this DateTimeOffset value)
Returns the given date and time formatted as BigQuery expects date values to be formatted.
The "local" value of the DateTimeOffset
is used; it is not converted to UTC.
Parameter | |
---|---|
Name | Description |
value | DateTimeOffset The date/time offset value to extract the date from. |
Returns | |
---|---|
Type | Description |
string | The date in yyyy-MM-dd format. |