Closed piroinno closed 3 years ago
I cannot reproduce on my end, could you please share more details?
Get-Module dbops -ListAvailable
)$variable$
syntax, which DBOps does not implement, using `#{variable} by default)I'm closing this one for now. Feel free to re-open it if the issue persists.
We have observed that when we inject '$' into the SQL text and execute deploy.ps1 it fails with the following error:
[12:15:16][deploy.ps1] System.Data.SqlClient.SqlException (0x80131904): Incorrect syntax near 'master'. Incorrect syntax near 'master'. Incorrect syntax near ') BEGIN RAISERROR ('. Incorrect syntax near '?'. Incorrect syntax near 'master'. Incorrect syntax near ') BEGIN RAISERROR ('. Incorrect syntax near '?'. Incorrect syntax near ') BEGIN RAISERROR ('. Incorrect syntax near 'master'. Incorrect syntax near ') BEGIN RAISERROR ('. Incorrect syntax near '?'. Incorrect syntax near 'master'. Incorrect syntax near ') BEGIN RAISERROR ('. Incorrect syntax near '?'. Incorrect syntax near 'END'. at System.Data.SqlClient.SqlConnection.OnError(SqlException exception, Boolean breakConnection, Action
1 wrapCloseInAction) at System.Data.SqlClient.TdsParser.ThrowExceptionAndWarning(TdsParserStateObject stateObj, Boolean callerHasConnectionLock, Boolean asyncClose) at System.Data.SqlClient.TdsParser.TryRun(RunBehavior runBehavior, SqlCommand cmdHandler, SqlDataReader dataStream, BulkCopySimpleResultSet bulkCopyHandler, TdsParserStateObject stateObj, Boolean& dataReady) at System.Data.SqlClient.SqlDataReader.TryConsumeMetaData() at System.Data.SqlClient.SqlDataReader.get_MetaData() at System.Data.SqlClient.SqlCommand.FinishExecuteReader(SqlDataReader ds, RunBehavior runBehavior, String resetOptionsString, Boolean isInternal, Boolean forDescribeParameterEncryption, Boolean shouldCacheForAlwaysEncrypted) at System.Data.SqlClient.SqlCommand.RunExecuteReaderTds(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, Boolean async, Int32 timeout, Task& task, Boolean asyncWrite, Boolean inRetry, SqlDataReader ds, Boolean describeParameterEncryptionRequest) at System.Data.SqlClient.SqlCommand.RunExecuteReader(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, String method, TaskCompletionSource
1 completion, Int32 timeout, Task& task, Boolean& usedCache, Boolean asyncWrite, Boolean inRetry) at System.Data.SqlClient.SqlCommand.RunExecuteReader(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, String method) at System.Data.SqlClient.SqlCommand.ExecuteReader(CommandBehavior behavior, String method) at DbUp.Support.ScriptExecutor.ExecuteAndLogOutput(IDbCommand command) at DbUp.SqlServer.SqlScriptExecutor.ExecuteCommandsWithinExceptionHandler(Int32 index, SqlScript script, Action excuteCommand) ClientConnectionId:3fc63250-120c-4dcf-9e82-a961206db174 Error Number:102,State:1,Class:15