[MINOR] Fix the wrong usage of timestamp length variable bug (#4179)
Signed-off-by: zzzhy <candle_1667@163.com>
This commit is contained in:
@@ -299,7 +299,7 @@ object HoodieSqlUtils extends SparkAdapterSupport {
|
|||||||
val instantLength = queryInstant.length
|
val instantLength = queryInstant.length
|
||||||
if (instantLength == 19 || instantLength == 23) { // for yyyy-MM-dd HH:mm:ss[.SSS]
|
if (instantLength == 19 || instantLength == 23) { // for yyyy-MM-dd HH:mm:ss[.SSS]
|
||||||
HoodieInstantTimeGenerator.getInstantForDateString(queryInstant)
|
HoodieInstantTimeGenerator.getInstantForDateString(queryInstant)
|
||||||
} else if (instantLength == HoodieInstantTimeGenerator.SECS_INSTANT_TIMESTAMP_FORMAT
|
} else if (instantLength == HoodieInstantTimeGenerator.SECS_INSTANT_ID_LENGTH
|
||||||
|| instantLength == HoodieInstantTimeGenerator.MILLIS_INSTANT_ID_LENGTH) { // for yyyyMMddHHmmss[SSS]
|
|| instantLength == HoodieInstantTimeGenerator.MILLIS_INSTANT_ID_LENGTH) { // for yyyyMMddHHmmss[SSS]
|
||||||
HoodieActiveTimeline.parseDateFromInstantTime(queryInstant) // validate the format
|
HoodieActiveTimeline.parseDateFromInstantTime(queryInstant) // validate the format
|
||||||
queryInstant
|
queryInstant
|
||||||
|
|||||||
Reference in New Issue
Block a user