You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@dolphinscheduler.apache.org by GitBox <gi...@apache.org> on 2019/12/11 02:27:05 UTC

[GitHub] [incubator-dolphinscheduler] nauu opened a new pull request #1439: Improve ParameterUtils.setInParameter, Use Datetype instead of String.

nauu opened a new pull request #1439: Improve ParameterUtils.setInParameter, Use Datetype instead of String.
URL: https://github.com/apache/incubator-dolphinscheduler/pull/1439
 
 
    ## What is the purpose of the pull request
   
   For bug #1379.
   
   Now all datatype use same method ` stmt.setString(index,value);` even DATE and TIMESTAMP.
   
   So i had improved it. If datatype is DATE use `stmt.setDate(index, java.sql.Date.valueOf(value));` ,
    if datatype is TIMESTAMP use `stmt.setTimestamp(index, java.sql.Timestamp.valueOf(value));`.i
   
   When use DATE the param format must use `$[yyyy-MM-dd] `, 
   When use TIMESTAMP the param format must use `$[yyyy-MM-dd hh:mm:ss]`.
   
   ## Brief change log
   
     - *Edit ParameterUtils.java*
     - *Fix wrong spell in SqlTask.java*
   
   ## Verify this pull request
   
     - *Manually verified the change by testing locally.*
   

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services