Java – Execute a Select query in SQL Server on Ubuntu No.8
How to run a select query in SQL Server on Ubuntu using Java is shown in this blog. ▼1. Prerequisites Creating a table “t1” in a database “TestDB” and inserting data intho this table are executed by sqlcmd utility. “sa” user is used in this sample. ▼2. Executing a query in SQL Server on Ubuntu by Java 2-1. Creating Java code to execute Select query 1-2. Results of this code Current Timestamps: 2020-05-26 06:52:10.564 [main] INFO ExecuteQSQLSvr – Connect to SQL Server successfully retrieve c1 c2 for t1 table 1 2 2 3 3 4 4 5 5 6 Current Timestamps: 2020-05-26 06:52:11.83 [main] INFO ExecuteQSQLSvr – The connection is … Continue reading “Java – Execute a Select query in SQL Server on Ubuntu No.8”