tristaZero commented on issue #9129:
URL: https://github.com/apache/shardingsphere/issues/9129#issuecomment-768035100


   Hi @ThanoshanMV ,
   
   Since `merge` is a new SQL type, we plan to create a `merge.xml`, right? 
Correspondingly we still need to define which parts of this SQL need assertion, 
like `tableName`, `columnType` etc.
   
   Therefore, after creating `merge.xml`, it is necessary to define 
`@XmlElement(name = "merge")` in `SQLParserTestCases` to tell 
`SQLParserTestCasesRegistry` to load your new `sql-parser-test-cases`.
   
   The main work above is to operate `javax.xml` (A common file type for 
developers). I am not sure whether you ever tried it, but we can start with 
`imitation`.  :-)
   
   Here are some steps for your consideration,
   - Add `@XmlElement(name = "merge")` to `SQLParserTestCases`
   - Create `MergeStatementTestCase` referring to other `xxxStatementTestCase` 
in that file (`SelectStatementTestCase` is a good one)
   - No need to fill all the elements in `MergeStatementTestCase` once. Just 
enrich it little by little to cover your SQL cases. (Don't discourage ourselves 
at first sight, :-) )
   


----------------------------------------------------------------
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:
[email protected]


Reply via email to