| View previous topic :: View next topic | 
	
	
		| Author | Message | 
	
		| nesquick -
 
 
 Joined: 19 May 2004
 Posts: 5
 
 
 | 
			
				|  Posted: Wed May 19, 2004 2:02 pm    Post subject: connect to local db |   |  
				| 
 |  
				| what are the things to indicate to connect to a local db ? my local db is sqlserver, here is my code :
 
 set oconne = server.CreateObject ("ADODB.CONNECTION")
 oconne.Open ("DSN=localhost;database=bepecaser;uid=;pwd=")
 
 what must i put in dns ? i do not know what to put for iud and pwd (i connect with local obdc)
 
 i have a 500 error
 
 thx
 |  | 
	
		| Back to top |     | 
	
		|  | 
	
		| iNaNimAtE -
 
 
 Joined: 05 Nov 2003
 Posts: 2381
 Location: Everywhere you're not.
 
 | 
			
				|  Posted: Thu May 20, 2004 12:00 am    Post subject: |   |  
				| 
 |  
				| May I suggest using MySQL if you have the option. If you do, and problems arise, there will be a lot more support for it [here] than ODBC. 
 All I can say for ODBC is checking the documentation (I believe it is available here) to see how to test your server.
 _________________
 Bienvenidos!
 |  | 
	
		| Back to top |                | 
	
		|  | 
	
		| aprelium -
 
 
 Joined: 22 Mar 2002
 Posts: 6800
 
 
 | 
			
				|  Posted: Fri May 21, 2004 2:19 pm    Post subject: Re: connect to local db |   |  
				| 
 |  
				| nesquick, 
 Do you get error 500 with all your ASP scripts or with that one only?
 _________________
 Support Team
 Aprelium - http://www.aprelium.com
 |  | 
	
		| Back to top |       | 
	
		|  | 
	
		| nesquick -
 
 
 Joined: 19 May 2004
 Posts: 5
 
 
 | 
			
				|  Posted: Mon May 24, 2004 8:36 am    Post subject: Re: connect to local db |   |  
				| 
 |  
				| >> iNaNimAtE 
 I must use SQL Server (if I could I would use MySQL and PHP...), but thx for the doc
 
 >> aprelium
 
 I only have a 500 error for the connection script. Any other script works well.
 |  | 
	
		| Back to top |     | 
	
		|  | 
	
		| nesquick -
 
 
 Joined: 19 May 2004
 Posts: 5
 
 
 | 
			
				|  Posted: Mon May 24, 2004 10:53 am    Post subject: |   |  
				| 
 |  
				| ok, i found the prob : i don't have to set a iud and a password, and i put the driver : 
 set oconne = server.CreateObject ("ADODB.CONNECTION")
 connStr = "DRIVER={SQL Server}; SERVER=myLocalServer; DATABASE=myDB"
 oconne.open connStr
 |  | 
	
		| Back to top |     | 
	
		|  | 
	
		|  |