Describe the bug
Having problems only with the create a table using RunSqlCmdScripts in Synapse.
2021-06-22T20:17:32.2933212Z ##[section]Starting: Run SQLCMD Scripts in folder D:\a\r1\a/_Synapse-test-CI/drop
2021-06-22T20:17:32.3144629Z ==============================================================================
2021-06-22T20:17:32.3145030Z Task : Run all SQL Scripts in a folder in SqlCmd mode
2021-06-22T20:17:32.3145996Z Description : Run multiple SQL Scripts in a folder in SqlCmd mode and passing in parameters via a SqlCmdVariables array
2021-06-22T20:17:32.3146429Z Version : 1.1.8
2021-06-22T20:17:32.3146664Z Author : Dr. John Tunnicliffe
2021-06-22T20:17:32.3147823Z Help : More Information
2021-06-22T20:17:32.3148290Z ==============================================================================
2021-06-22T20:17:34.9141988Z ==============================================================================
2021-06-22T20:17:34.9164922Z Calling Invoke-SqlCmd with the following parameters:
2021-06-22T20:17:34.9239687Z Server: xxxxxxxxsynapse.database.windows.net
2021-06-22T20:17:34.9317290Z Database: synapse-sqlpool
2021-06-22T20:17:34.9353190Z SqlCmdSciptFolderPath: D:\a\r1\a_Synapse-test-CI\drop
2021-06-22T20:17:34.9374536Z Recursive: false
2021-06-22T20:17:34.9406743Z SqlCmdVariableType: none
2021-06-22T20:17:34.9429054Z AuthenticationUser: xxxx_test
2021-06-22T20:17:39.4673403Z SQLCMD folder: D:\a\r1\a_Synapse-test-CI\drop
2021-06-22T20:17:39.4769914Z Running SQLCMD file: 4-Create-Table-Sailing.sql
2021-06-22T20:17:39.5376742Z Invoke-Sqlcmd -ServerInstance 'devsynapse.database.windows.net' -Database dev-synapse-sqlpool -InputFile 'D:\a\r1\a_Synapse-test-CI\drop\4-Create-Table-Sailing.sql' -ErrorAction Stop -QueryTimeout 6000 -Credential $Credential
2021-06-22T20:17:43.1486666Z ##[error]There are no batches in the input script.
Msg 104309, Level 16, State 1, Procedure , Line 1.
2021-06-22T20:17:43.2156622Z ##[section]Finishing: Run SQLCMD Scripts in folder D:\a\r1\a/_Synapse-test-CI/drop
To Reproduce
SQL Statement to create table that is giving error
/** Object: Table [dbo].[sailing_flags_test] Script Date: 5/14/2021 1:17:49 PM **/
SET NOCOUNT OFF;
GO
Component
Describe the bug Having problems only with the create a table using RunSqlCmdScripts in Synapse.
2021-06-22T20:17:32.2933212Z ##[section]Starting: Run SQLCMD Scripts in folder D:\a\r1\a/_Synapse-test-CI/drop 2021-06-22T20:17:32.3144629Z ============================================================================== 2021-06-22T20:17:32.3145030Z Task : Run all SQL Scripts in a folder in SqlCmd mode 2021-06-22T20:17:32.3145996Z Description : Run multiple SQL Scripts in a folder in SqlCmd mode and passing in parameters via a SqlCmdVariables array 2021-06-22T20:17:32.3146429Z Version : 1.1.8 2021-06-22T20:17:32.3146664Z Author : Dr. John Tunnicliffe 2021-06-22T20:17:32.3147823Z Help : More Information 2021-06-22T20:17:32.3148290Z ============================================================================== 2021-06-22T20:17:34.9141988Z ============================================================================== 2021-06-22T20:17:34.9164922Z Calling Invoke-SqlCmd with the following parameters: 2021-06-22T20:17:34.9239687Z Server: xxxxxxxxsynapse.database.windows.net 2021-06-22T20:17:34.9317290Z Database: synapse-sqlpool 2021-06-22T20:17:34.9353190Z SqlCmdSciptFolderPath: D:\a\r1\a_Synapse-test-CI\drop 2021-06-22T20:17:34.9374536Z Recursive: false 2021-06-22T20:17:34.9406743Z SqlCmdVariableType: none 2021-06-22T20:17:34.9429054Z AuthenticationUser: xxxx_test 2021-06-22T20:17:39.4673403Z SQLCMD folder: D:\a\r1\a_Synapse-test-CI\drop 2021-06-22T20:17:39.4769914Z Running SQLCMD file: 4-Create-Table-Sailing.sql 2021-06-22T20:17:39.5376742Z Invoke-Sqlcmd -ServerInstance 'devsynapse.database.windows.net' -Database dev-synapse-sqlpool -InputFile 'D:\a\r1\a_Synapse-test-CI\drop\4-Create-Table-Sailing.sql' -ErrorAction Stop -QueryTimeout 6000 -Credential $Credential 2021-06-22T20:17:43.1486666Z ##[error]There are no batches in the input script. Msg 104309, Level 16, State 1, Procedure , Line 1. 2021-06-22T20:17:43.2156622Z ##[section]Finishing: Run SQLCMD Scripts in folder D:\a\r1\a/_Synapse-test-CI/drop
To Reproduce SQL Statement to create table that is giving error
/** Object: Table [dbo].[sailing_flags_test] Script Date: 5/14/2021 1:17:49 PM **/ SET NOCOUNT OFF;
GO
SET ANSI_NULLS ON GO
SET QUOTED_IDENTIFIER ON GO
CREATE TABLE [dbo].[sailing_flags_test] ( [SHIP_CODE] varchar NULL, [SAILING_DATE] [datetime] NULL, [META_PRODUCT_CODE] varchar NULL, [RDSS_PRODUCT_CODE] varchar NULL, [CHARTER] varchar NULL, [ITINERARY_NIGHTS] [float] NULL, [ORIGINATING_PORT] varchar NULL, [HOLIDAY] varchar NULL, [SAILING_BUCKET] varchar NULL, [BUCKET_GROUP] varchar NULL ) WITH ( DISTRIBUTION = REPLICATE, CLUSTERED COLUMNSTORE INDEX ) GO
Expected behavior A clear and concise description of what you expected to happen.
Screenshots If applicable, add screenshots to help explain your problem.
Azure DevOps Agent
Additional context I am able to run other scripts Create Schema, Drop Schema, but just create table is giving error.