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

   ## Bug Report
   
   ### Which version of ShardingSphere did you use?
   
   shardingsphere-proxy 5.5.2
   postgres 17.6 as backend
   
   ### Expected behavior
   
   ```sql
   DROP TABLE IF EXISTS t1;
   CREATE TABLE t1 (c8 TIMESTAMP);
   
   INSERT INTO t1 VALUES ('1973-06-03 10:30:01'); -- no fractional seconds
   SELECT c8 FROM t1;
   ```
   should return (in native PG):
   ```
   1973-06-03 10:30:01
   ```
   
   ### Actual behavior
   ```sql
   testdb=> CREATE TABLE t100 (c8 TIMESTAMP);
   CREATE TABLE
   testdb=> INSERT INTO t100 VALUES ('1973-06-03 10:30:01');
   INSERT 0 1
   testdb=> SELECT c8 FROM t100 ;
             c8           
   -----------------------
    1973-06-03 10:30:01.0
   (1 row)
   ```
   
   The semantic value seems identical, but the textual representation differs 
and may break clients/tests relying on stable output formatting.
   
   We guess the bug is related to `Timestamp.toString()` in 
`java.sql.Timestamp`.
   
   ### Steps to reproduce the behavior, such as: SQL to execute, sharding rule 
configuration, when exception occur etc.
   
   
[ss_postgres.zip](https://github.com/user-attachments/files/24253131/ss_postgres.zip)
   
   run `docker compose up -d` in this file.
   
   SQL to execute are shown above
   


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