ALLInterview.com :: Home Page KalAajKal.com
 Advertise your Business Here     
Browse  |   Placement Papers  |   Company  |   Code Snippets  |   Certifications  |   Visa Questions
Post Question  |   Post Answer  |   My Panel  |   Search  |   Articles  |   Topics  |   ERRORS new
   Refer this Site  Refer This Site to Your Friends  Site Map  Bookmark this Site  Set it as your HomePage  Contact Us     Login  |  Sign Up                      
Do you have a collection of Interview Questions and interested to share with us!!
Please send that collection to along with your userid / name. ThanQ
Google
 
Categories  >>  Software  >>  Microsoft Related  >>  Dot Net  >>  Dot Net General
 
 


 

 
 Dot Net Framework interview questions  Dot Net Framework Interview Questions
 Dot Net Remoting interview questions  Dot Net Remoting Interview Questions
 Dot Net WindowsForms interview questions  Dot Net WindowsForms Interview Questions
 Dot Net General interview questions  Dot Net General Interview Questions
 Dot Net AllOther interview questions  Dot Net AllOther Interview Questions
Question
how to connect database connectivity in dotNET? if suppose 
SQL server?and also MS access?
 Question Submitted By :: Amar
I also faced this Question!!     Rank Answer Posted By  
 
  Re: how to connect database connectivity in dotNET? if suppose SQL server?and also MS access?
Answer
# 1
in code behind give namespace
using System.data.sqlclient;
and write connections string in web.config to which 
database to connect
 
Is This Answer Correct ?    19 Yes 2 No
Aravind
 
  Re: how to connect database connectivity in dotNET? if suppose SQL server?and also MS access?
Answer
# 2
in web.config file
<configuration>

    <appSettings>
		<add key="SqlCon" value="Data 
Source=winserver;initial 
Catalog=cieflnew;uid=cieflnew;pwd=cieflnew; Connection 
Lifetime=0;Max Pool Size=10000;Min Pool Size=0;Connection 
Reset=false;Pooling=true;Persist Security Info=False"/>
	</appSettings>
  <system.web>
and in code behind
Sql cmd= new Sql command(Query here,con);
cmd.executenonquery();
 
Is This Answer Correct ?    10 Yes 3 No
Guest
 
 
 
  Re: how to connect database connectivity in dotNET? if suppose SQL server?and also MS access?
Answer
# 3
hi,

  I have MySQL so how to connect to dotnet
 
Is This Answer Correct ?    2 Yes 8 No
Prabha
 
  Re: how to connect database connectivity in dotNET? if suppose SQL server?and also MS access?
Answer
# 4
MySQLConnection myConn;
myConn = new MySQLConnection(new
MySQLConnectionString("localhost", "databse", "User",
"password").AsString);
For More Info Visit www.funnydotnet.co.cc
 
Is This Answer Correct ?    4 Yes 0 No
Rajesh Chekuri
 
  Re: how to connect database connectivity in dotNET? if suppose SQL server?and also MS access?
Answer
# 5
SQl Server
namespace->Using System .data.Sqlclient;

SqlConnectin con=new SqlConnection
("Servername="";uid="";pwd="";database="")

Ms-Access:

Namespace->using system.data.oledb;

oledbconnection con=new oledb connection
("Servername="";uid="";pwd="";database="")

 
Is This Answer Correct ?    3 Yes 1 No
Raju
 

 
 
 
Other Dot Net General Interview Questions
 
  Question Asked @ Answers
 
What are the contents of assembly?  3
What is the raise event used for? Wipro4
What is the Difference between directcast and ctype? Wipro3
What is prerender event of a page? C-Squared-Systems3
What does SCM do?  1
Can you configure a .NET Remoting object via XML file?  1
What is Garbage Collection in .Net? Garbage collection process?  3
What are Generics? Where do we use them. Value-Labs2
Can u any body send the DotNet Interview questions and answers to my mail please....... mindukuru@yahoo.com  1
i have an array of 10 objects whose values are from 1-10 randomly inserted. i have deleted one array object. tell me what is that value? write the logic of it. Deloitte1
When developing a Windows service for .NET, which namespace do you typically look in for required classes?  1
What base class do all Web Forms inherit from?  1
How to find methods of a assembly file (not using ILDASM) Reflection  1
create a keypair?  1
What is MSIL code ? TCS2
What distributed process frameworks outside .NET do you know?  1
How do you give a Windows service specific permissions?  1
what is AGILE SCRUM methodoly....?  1
How can you see which services are running on a Windows box?  1
Can we Classic ASP,.Net 1.0, .Net 1.x and .Net 2.0 installed on the same system? Value-Labs1
 
For more Dot Net General Interview Questions Click Here 
 
 
 
 
 
   
Copyright Policy  |  Terms of Service  |  Help  |  Site Map 1  |  Articles  |  Site Map  |   Site Map  |  Contact Us interview questions urls   External Links 
   
Copyright © 2007  ALLInterview.com.  All Rights Reserved.

ALLInterview.com   ::  Forum9.com   ::  KalAajKal.com