提交 696380c1 authored 作者: Evgenij Ryazanov's avatar Evgenij Ryazanov

Fix some copy-and-paste errors

上级 6dea75e3
...@@ -2654,7 +2654,7 @@ INTERVAL [-|+] '[-|+]dayInt hoursInt' DAY TO HOUR ...@@ -2654,7 +2654,7 @@ INTERVAL [-|+] '[-|+]dayInt hoursInt' DAY TO HOUR
"," ","
An INTERVAL DAY TO HOUR literal. An INTERVAL DAY TO HOUR literal.
"," ","
INTERVAL '10 11' DAY TO * INTERVAL '10 11' DAY TO HOUR
" "
"Other Grammar","INTERVAL DAY TO MINUTE"," "Other Grammar","INTERVAL DAY TO MINUTE","
......
...@@ -453,7 +453,7 @@ public class ValueDataType implements DataType { ...@@ -453,7 +453,7 @@ public class ValueDataType implements DataType {
ordinal = ~ordinal; ordinal = ~ordinal;
} }
buff.put((byte) Value.INTERVAL_YEAR). buff.put((byte) Value.INTERVAL_YEAR).
put((byte) (ordinal)). put((byte) ordinal).
putVarLong(interval.getLeading()); putVarLong(interval.getLeading());
break; break;
} }
......
...@@ -383,12 +383,12 @@ public class LocalDateTimeUtils { ...@@ -383,12 +383,12 @@ public class LocalDateTimeUtils {
} }
/** /**
* Converts a value to a OffsetDateTime. * Converts a value to a Duration.
* *
* <p>This method should only called from Java 8 or later.</p> * <p>This method should only called from Java 8 or later.</p>
* *
* @param value the value to convert * @param value the value to convert
* @return the OffsetDateTime * @return the Duration
*/ */
public static Object valueToDuration(Value value) { public static Object valueToDuration(Value value) {
if (!(value instanceof ValueInterval)) { if (!(value instanceof ValueInterval)) {
...@@ -572,7 +572,7 @@ public class LocalDateTimeUtils { ...@@ -572,7 +572,7 @@ public class LocalDateTimeUtils {
} catch (IllegalAccessException e) { } catch (IllegalAccessException e) {
throw DbException.convert(e); throw DbException.convert(e);
} catch (InvocationTargetException e) { } catch (InvocationTargetException e) {
throw DbException.convertInvocation(e, "time conversion failed"); throw DbException.convertInvocation(e, "interval conversion failed");
} }
} }
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论