Skip to content

Commit

Permalink
0001771: Add support for ansi literal default date values. Also suppo…
Browse files Browse the repository at this point in the history
…rt well known sql 92 function types for the default values
  • Loading branch information
chenson42 committed Jun 22, 2014
1 parent e45635b commit 6af92b4
Showing 1 changed file with 11 additions and 1 deletion.
Expand Up @@ -2001,7 +2001,17 @@ protected void printDefaultValue(String defaultValue, int typeCode, StringBuilde
|| defaultValueStr.toUpperCase().startsWith("SYSDATE")
|| defaultValueStr.toUpperCase().startsWith("SYSTIMESTAMP")
|| defaultValueStr.toUpperCase().startsWith("CURRENT_TIMESTAMP")
|| defaultValueStr.toUpperCase().startsWith("CURRENT_DATE")));
|| defaultValueStr.toUpperCase().startsWith("CURRENT_TIME")
|| defaultValueStr.toUpperCase().startsWith("CURRENT_DATE")
|| defaultValueStr.toUpperCase().startsWith("CURRENT_USER")
|| defaultValueStr.toUpperCase().startsWith("USER")
|| defaultValueStr.toUpperCase().startsWith("SYSTEM_USER")
|| defaultValueStr.toUpperCase().startsWith("SESSION_USER")
|| defaultValueStr.toUpperCase().startsWith("DATE '")
|| defaultValueStr.toUpperCase().startsWith("TIME '")
|| defaultValueStr.toUpperCase().startsWith("TIMESTAMP '")
|| defaultValueStr.toUpperCase().startsWith("INTERVAL '")
));

if (shouldUseQuotes) {
// characters are only escaped when within a string literal
Expand Down

0 comments on commit 6af92b4

Please sign in to comment.