Send feedback
Class SpannerDate (7.5.0)
Stay organized with collections
Save and categorize content based on your preferences.
Version latest keyboard_arrow_down
Date-like object used to represent Cloud Spanner Dates. DATE types represent a logical calendar date, independent of time zone. DATE values do not represent a specific 24-hour period. Rather, a given DATE value represents a different 24-hour period when interpreted in a different time zone. Because of this, all values passed to will be interpreted as local time.
To represent an absolute point in time, use Spanner.timestamp() .
Inheritance
Date
>
SpannerDate
Package
@google-cloud/spanner
Example
Spanner.date('3-3-1933');
Constructors
(constructor)(dateString)
constructor ( dateString ? : string );
Constructs a new instance of the SpannerDate
class
Parameter Name Description dateString
string
(constructor)(year, month, date)
constructor ( year : number , month : number , date : number );
Constructs a new instance of the SpannerDate
class
Parameters Name Description year
number
month
number
date
number
Methods
toJSON()
Returns the date in ISO date format. YYYY-MM-DD
Returns Type Description string
{string}
Send feedback
Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License , and code samples are licensed under the Apache 2.0 License . For details, see the Google Developers Site Policies . Java is a registered trademark of Oracle and/or its affiliates.
Last updated 2024-10-01 UTC.
[{
"type": "thumb-down",
"id": "hardToUnderstand",
"label":"Hard to understand"
},{
"type": "thumb-down",
"id": "incorrectInformationOrSampleCode",
"label":"Incorrect information or sample code"
},{
"type": "thumb-down",
"id": "missingTheInformationSamplesINeed",
"label":"Missing the information/samples I need"
},{
"type": "thumb-down",
"id": "otherDown",
"label":"Other"
}]
[{
"type": "thumb-up",
"id": "easyToUnderstand",
"label":"Easy to understand"
},{
"type": "thumb-up",
"id": "solvedMyProblem",
"label":"Solved my problem"
},{
"type": "thumb-up",
"id": "otherUp",
"label":"Other"
}]
Need to tell us more?
{"lastModified": "Last updated 2024-10-01 UTC."}
[[["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 2024-10-01 UTC."]]