sandynz opened a new issue, #37801:
URL: https://github.com/apache/shardingsphere/issues/37801

   ## Feature Request
   
   ### Is your feature request related to a problem?
   Yes. Development problem, not running problem.
   
   In pipeline E2E, there might be long SQL and DistSQL. Currently, Java 8 
(source and target) is used, we need to split SQL to several String constants.
   
   ### Describe the feature you would like.
   
   Text blocks feature was introduced in Java 15.
   If we upgrade to Java 17 (LTS edition), then SQLs in E2E could be 
simplified. Just write SQLs in Java code and implement database dialects, for 
better re-use in different scenarios and branch databases.
   e.g.
   ```
   String sql1 = """
           CREATE SHARDING TABLE RULE t_order(
           STORAGE_UNITS(ds_2,ds_3,ds_4),
           SHARDING_COLUMN=user_id,
           TYPE(NAME="hash_mod",PROPERTIES("sharding-count"="6")),
           AUDIT_STRATEGY 
(TYPE(NAME="DML_SHARDING_CONDITIONS"),ALLOW_HINT_DISABLE=true)
           );
           """;
   
   String sql2 = """
           CREATE TABLE test.t_order_item (
           item_id int8 NOT NULL,
           order_id int8 NOT NULL,
           user_id int4 NOT NULL,
           status varchar(50),
           PRIMARY KEY (item_id)
           );
           """;
   ```
   


-- 
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.

To unsubscribe, e-mail: 
[email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to