Error when connecting excel to SQL Server

%3CLINGO-SUB%20id%3D%22lingo-sub-756532%22%20slang%3D%22en-US%22%3EError%20when%20connecting%20excel%20to%20SQL%20Server%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-756532%22%20slang%3D%22en-US%22%3EHello%20all%2C%3CBR%20%2F%3E%3CBR%20%2F%3EI%20am%20getting%20an%20error%20when%20trying%20to%20connect%20excel%20to%20sql%20server.%20I%20have%20attached%20the%20image%20of%20the%20error.%20I%20need%20to%20fix%20this%20error.%20Any%20help%20is%20appreciated%3CBR%20%2F%3E%3CBR%20%2F%3EBarath%3C%2FLINGO-BODY%3E%3CLINGO-LABS%20id%3D%22lingo-labs-756532%22%20slang%3D%22en-US%22%3E%3CLINGO-LABEL%3EBusiness%20Intelligence%3C%2FLINGO-LABEL%3E%3CLINGO-LABEL%3EReporting%20Services%3C%2FLINGO-LABEL%3E%3C%2FLINGO-LABS%3E%3CLINGO-SUB%20id%3D%22lingo-sub-763604%22%20slang%3D%22en-US%22%3ERe%3A%20Error%20when%20connecting%20excel%20to%20SQL%20Server%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-763604%22%20slang%3D%22en-US%22%3E%3CP%3E%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F376958%22%20target%3D%22_blank%22%3E%40nynamyna%3C%2FA%3EMost%20of%20my%20experience%20between%20Excel%20and%20SQL%20is%20via%20Power%20Query%2C%20so%20sorry%20if%20this%20doesn't%20apply.%3C%2FP%3E%3CP%3ESQL%20by%20default%20uses%20a%20self%20generated%20certificate%20that%20would%20not%20be%20trusted%20by%20other%20machines.%20You%20have%20some%20options%20-%20loosely%20in%20order%20of%20easiest%20to%20more%20secure%3CBR%20%2F%3EDon't%20use%20an%20encrypted%20connection%20-%20I%20observed%20Power%20Query%20offer%20this%20option%20during%20a%20get%20data%20wizard%20recently%20-%20from%20the%20resulting%20.odc%20file%20%22Use%20Encryption%20for%20Data%3DFalse%22%3CBR%20%2F%3EConnect%20using%20an%20option%20to%20accept%20untrusted%20certificates%20-%20the%20strings%20vary%20-%20you%20might%20have%20a%20look%20here%3CBR%20%2F%3E%3CA%20href%3D%22https%3A%2F%2Fdocs.microsoft.com%2Fen-us%2Fsql%2Frelational-databases%2Fnative-client%2Ffeatures%2Fusing-encryption-without-validation%3Fview%3Dsql-server-2017%26nbsp%3B%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noreferrer%20noopener%20noreferrer%22%3Ehttps%3A%2F%2Fdocs.microsoft.com%2Fen-us%2Fsql%2Frelational-databases%2Fnative-client%2Ffeatures%2Fusing-encryption-without-validation%3Fview%3Dsql-server-2017%3C%2FA%3E%26nbsp%3B%3C%2FP%3E%3C%2FLINGO-BODY%3E
Highlighted
New Contributor
Hello all,

I am getting an error when trying to connect excel to sql server. I have attached the image of the error. I need to fix this error. Any help is appreciated

Barath
1 Reply
Highlighted

@nynamynaMost of my experience between Excel and SQL is via Power Query, so sorry if this doesn't apply.

SQL by default uses a self generated certificate that would not be trusted by other machines. You have some options - loosely in order of easiest to more secure
Don't use an encrypted connection - I observed Power Query offer this option during a get data wizard recently - from the resulting .odc file "Use Encryption for Data=False"
Connect using an option to accept untrusted certificates - the strings vary - you might have a look here
https://docs.microsoft.com/en-us/sql/relational-databases/native-client/features/using-encryption-wi...