Login failed. The login is from an untrusted domain and cannot be used with Integrated authenticati

Tried to connect to Aliyun RDS SQLServer with SQLServer authentication, used the below method to register the target SQLServer database.
public void RegisterForDataCompare(ConnectionProperties connectionProperties, Options options);
The exception occurred as below:
public void RegisterForDataCompare(ConnectionProperties connectionProperties, Options options);
The exception occurred as below:
Server stack trace:
at System.Data.SqlClient.SqlInternalConnectionTds..ctor(DbConnectionPoolIdentity identity, SqlConnectionString connectionOptions, SqlCredential credential, Object providerInfo, String newPassword, SecureString newSecurePassword, Boolean redirectedUserInstance, SqlConnectionString userConnectionOptions, SessionData reconnectSessionData, DbConnectionPool pool, String accessToken, Boolean applyTransientFaultHandling, SqlAuthenticationProviderManager sqlAuthProviderManager)
at System.Data.SqlClient.SqlConnectionFactory.CreateConnection(DbConnectionOptions options, DbConnectionPoolKey poolKey, Object poolGroupProviderInfo, DbConnectionPool pool, DbConnection owningConnection, DbConnectionOptions userOptions)
at System.Data.ProviderBase.DbConnectionFactory.CreateNonPooledConnection(DbConnection owningConnection, DbConnectionPoolGroup poolGroup, DbConnectionOptions userOptions)
at System.Data.ProviderBase.DbConnectionFactory.TryGetConnection(DbConnection owningConnection, TaskCompletionSource`1 retry, DbConnectionOptions userOptions, DbConnectionInternal oldConnection, DbConnectionInternal& connection)
at System.Data.ProviderBase.DbConnectionInternal.TryOpenConnectionInternal(DbConnection outerConnection, DbConnectionFactory connectionFactory, TaskCompletionSource`1 retry, DbConnectionOptions userOptions)
at System.Data.ProviderBase.DbConnectionClosed.TryOpenConnection(DbConnection outerConnection, DbConnectionFactory connectionFactory, TaskCompletionSource`1 retry, DbConnectionOptions userOptions)
at System.Data.SqlClient.SqlConnection.TryOpenInner(TaskCompletionSource`1 retry)
at System.Data.SqlClient.SqlConnection.TryOpen(TaskCompletionSource`1 retry)
at System.Data.SqlClient.SqlConnection.Open()
at #56Od.#msLd.#N9f(SqlConnection #I2O)
at System.Runtime.Remoting.Messaging.StackBuilderSink._PrivateProcessMessage(IntPtr md, Object[] args, Object server, Object[]& outArgs)
at System.Runtime.Remoting.Messaging.StackBuilderSink.AsyncProcessMessage(IMessage msg, IMessageSink replySink)
Tagged:
Answers
Sorry to hear you're experiencing this issue!
I would advise taking a look at the following document: https://documentation.red-gate.com/sdc/troubleshooting/unexpected-behavior-technical-questions/using-windows-authentication-logons-between-domains
Alternatively, if you're able to use SQL Server Authentication that will work.
Kind regards
Dan Calver | Redgate Software
Have you visited our Help Center?
Yes, I can use SQL Server Authentication on Aliyun RDS SQLServer2017, the question here is: how to use it in the code with Redgate .Net SDK? Would you like to share a sample of .Net SDK of Redgate SQL Compare?
Unfortunately, we're unable to support the SQL Comparison SDK as this has been retired, please see: https://www.red-gate.com/products/sql-development/sql-comparison-sdk/
We now advise taking a look at the SQL Change Automation product.
Kind regards
Dan Calver | Redgate Software
Have you visited our Help Center?