Navigacija
Lista poslednjih: 16, 32, 64, 128 poruka.

ConnectionString problem

[es] :: .NET :: ConnectionString problem

[ Pregleda: 1485 | Odgovora: 5 ]

Postavi temu Odgovori

Autor

Pretraga teme: Traži
Markiranje Štampanje RSS

Radudzoni
Radoslav Jovanovic
Beograd

Član broj: 8384
Poruke: 126
*.InfoSky.Net



Profil

icon ConnectionString problem11.07.2003. u 22:27

Kada stavim sledeci kod:

SqlConnection conn = new SqlConnection("Initial Catalog=Nortwind;
Server=RADE-JOVANOVIC7\\NetSDK;UID=sa;PWD=;");
.
.
.
conn.Open();

i pokrenem asp.net aplikaciju u breuzeru mi se javi sledeca greska:

Exception Details: System.Data.SqlClient.SqlException:
Login failed for user 'sa'. Reason: Not associated with a trusted SQL Server connection.

a ako u ConnectionStringu stavim Trusted_Connection=true
tada dobijam sledecu gresku:

Exception Details: System.Data.SqlClient.SqlException:
Cannot open database requested in login 'Nortwind'.
Login fails. Login failed for user 'RADE-JOVANOVIC7\ASPNET'

pa se pitam zasto!
11.07.2003. u 22:27 

degojs

Član broj: 4716
Poruke: 5096
*.cpe.net.cable.rogers.com

Sajt: www.novetehnologije.com


Profil

icon Re: ConnectionString problem11.07.2003. u 23:58
Pokušaj da vidiš ovo:

http://support.microsoft.com/d...69/5/87.ASP&NoWebContent=1

Ne zaboravi da restartuješ MSSQL servis.
Commercial-Free !!!
11.07.2003. u 23:58 

degojs

Član broj: 4716
Poruke: 5096
*.cpe.net.cable.rogers.com

Sajt: www.novetehnologije.com


Profil

icon Re: ConnectionString problem12.07.2003. u 00:03
If the web server and SQL Server are on the same machine...

1. If SQL Server is using Windows Authentication, you have to add
MACHINENAME\ASPNET to SQL Server logins.

2. If IIS is using Integrated Windows authentication and SQL Server is
using Windows Authentication and you are using impersonation in web.config,
you have to add the current user (MACHINENAME\USERNAME) who logged on
Windows to SQL Server logins.


If the web server and SQL Server are on the seperated machines...

1. If IIS is using Integrated Windows authentication and SQL Server is
using Windows Authentication, you have to use impersionation in web.config
and also configure NT Kerberos and Delegation. Delegation is only supported
by Win2k.

2. If IIS is using Integrated Windows authentication, a much simply
solution is to use SQL Server Authentication in SQL Server and specify the
username and password in the connection string.
Commercial-Free !!!
12.07.2003. u 00:03 

Radudzoni
Radoslav Jovanovic
Beograd

Član broj: 8384
Poruke: 126
*.InfoSky.Net



Profil

icon Re: ConnectionString problem12.07.2003. u 01:38
Hvala za trud!

U medjuvremenu sam pokusao isto samo sa drugom bazom,
takodje jednom od onih sto se instaliraju sa sql serverom
i radi, a nemam pojma u cemu je problem.
No, nije ni bitno vazno mi je da proradi sa bilo kojom.

pozdrav!
12.07.2003. u 01:38 

veljaradenkovic
Velja Radenkovic
Beograd

Član broj: 2977
Poruke: 281
*.ptt.yu

ICQ: 147120023


Profil

icon Re: ConnectionString problem12.07.2003. u 15:05
He he...

Ako je ovo sto kazes onda si pravilno napisao ime ove druge baze...

jer od ove prve nisi nije NORT nego NORTH ko SEVER...
12.07.2003. u 15:05 

byTer

Član broj: 10936
Poruke: 1221
*.041net.co.yu

ICQ: 47761626


Profil

icon Re: ConnectionString problem12.07.2003. u 17:23
Dodaj u conn stringu "Integrated Security = SSPI;"
12.07.2003. u 17:23 

[es] :: .NET :: ConnectionString problem

[ Pregleda: 1485 | Odgovora: 5 ]

Postavi temu Odgovori

Navigacija
Lista poslednjih: 16, 32, 64, 128 poruka.