connection strings for all databases

Upload: michel-isamuna

Post on 05-Apr-2018

234 views

Category:

Documents


0 download

TRANSCRIPT

  • 8/2/2019 Connection Strings for All Databases

    1/8

    Resources

    Our Ne twork

    Sponsored by

    Become a Sponsor

    Similar Articles Most Read Top Rate

    How to: Generate or find Connectio

    Studio

    Storing and Retrieving Connection S

    2.0/3.5

    Connection String in LINQ

    Configuring connection string using

    Windows Azure - Connect to SQL Az

    C# Corner sur Facebook

    Jaime 2,348

    Tag Cloud

    client result cacheData Warehouseodp.netora

    provider for .netoracle vs sql servervisual.stud

    object database windoweloquera SQLConnection

    WarehouseDatabasesDe

    Denali CTP3 i

    Server 2008and implementing a Dat

    Download Denali CTP3e

    application performance

    sql serverhow to install s

    2005in Win Server 2008 R

    Denali CTP3Installation

    Installation of SQL Serv

    oracle 11gPostgr

    Total Online Users: 1 3 1 8 2 Silverlight Hosting Providers

    H om e | Fo ru m s | V id eo s | Adve r t i se | Cer t i f i ca t i ons| D ow n l oa ds | B lo gs | I n t er v ie w s | Jo bs | B eg in n er s | Tr ai ni ng | Consu l t i ng Submit an A r t ic le Submit a B log

    Login

    Enter UserID or Email

    Remember Me

    Sign In Register

    Fo rgo t Passwor d

    Forgo t Use rname

    Why Reg i ste r

    Jump to

    Technology

    Webs i t e

    Sponsored by

    Become a Sponsor

    Abou t Us

    ASP.NET Host ing

    A u t h o r s

    Book Chap te rs

    Book Rev iews

    C# Consu l t i ng

    C# T ra in i ng

    Down loads

    Media Ki t

    News & Even ts

    Pr izes

    Produc t Rev iews

    Resources

    Tips

    Tools

    User Groups

    Search : Go Advanced Search

    H o m e Databases & DBA Connect i on S t r i ngs f o r A l l Da tabases

    Connect ion St r ing s for A l l Databases

    By a b d u r r e h m a n Feb rua ry 17 , 2011This article shows step by step different ways to get connection strings for all types of databases. The article is written for

    all type of users, beginners, intermediate, experienced

    Page V iews : 3284

    Down loads : 60

    Rat i ng : Rate it

    Level : Beginner

    Print Post a comment Similar Articles Share

    Email to a friend Bookmark Author's other articles

    Dow n load F i l es: UDL conec t i on -s t r i ng f i l e . ra r Tweet 0 0

    I n t r o d u c t i o n

    Databases are widely used in applications to keep records. A large variaty of Database Management Systems are

    available in the market and in use. Every DBMS needs a different format of connection string. It's not possible to

    remember all those formats, so knowing how to get a Connection String for any database makes life easy.

    UDL f i le Method

    UDL Files are an easy way to get the desired connection string by simply filling in property pages. The following

    steps show how to make and use a UDL file for that.

    1. Make a New Text Document

    2. Open the Text Document, Click on Save As.

    ShareShare

    nection Strings for All Databases http://www.c-sharpcorner.com/uploadfile/2a62a4/connection-strings-fo...

    r 8 3/31/2012 1:38 AM

  • 8/2/2019 Connection Strings for All Databases

    2/8

    Latest Jobs

    Split Testing Designer

    .NET Developer

    Web Developer

    Application Engineer Expert

    .NET Developer

    Application Developer

    dot net developer

    MCA

    .NET Developer Needed

    .NET Developer Needed

    La tes t I n te r v i ew Ques t i ons

    Application_Start in ASP.NET

    How to pass dynamically created into S

    through SQL parameters in C#.NET?

    How can we convert.Intofloat like conv

    Difference between Access specifiers a

    Hi everyone, How to scan a document

    forms in .net framework and i am usin

    OS ......... Please help me

    Can we declare a variable const and vo

    What exactly the term cookies refer to

    How to display Alert in JavaScript on A

    What is the difference between a Web

    Browser?

    How to open Child window in parent wiApplication

    .NET Heaven

    C# Corne r

    DbTa l ks

    In te r v i ew Corne r

    Longhorn Corne r

    M indc racke r

    VB.NET Heaven

    3. Write filename as something.udl, file type All files, click Save.

    4. Now run something.udl

    5. Click on Provider tab. Select the provider and click Next.

    6. Give the DataBase Path.

    nection Strings for All Databases http://www.c-sharpcorner.com/uploadfile/2a62a4/connection-strings-fo...

    r 8 3/31/2012 1:38 AM

  • 8/2/2019 Connection Strings for All Databases

    3/8

    7. Write Username, Password if any

    7. Click on Test Connection.

    8. If it's OK, then close it now.

    nection Strings for All Databases http://www.c-sharpcorner.com/uploadfile/2a62a4/connection-strings-fo...

    r 8 3/31/2012 1:38 AM

  • 8/2/2019 Connection Strings for All Databases

    4/8

    9. Now open udl file as Text File with Notepad

    11. The Last line will have the Connection String

    Visua l S tud io DataSource Method

    1. Add DatagridView to your Form.

    2. Click on Arrow in Top Right Corner of DataGridView, Click Choose DataSource, Select Add New DataSource

    3. Select Database, Click on Next.

    nection Strings for All Databases http://www.c-sharpcorner.com/uploadfile/2a62a4/connection-strings-fo...

    r 8 3/31/2012 1:38 AM

  • 8/2/2019 Connection Strings for All Databases

    5/8

    4. Click on New Connection

    5. Now Choose DataSource, Click on Continue

    database connection string - dontumindit (10).jpg

    6. Browse For Database, Provide Username, Password, if any

    nection Strings for All Databases http://www.c-sharpcorner.com/uploadfile/2a62a4/connection-strings-fo...

    r 8 3/31/2012 1:38 AM

  • 8/2/2019 Connection Strings for All Databases

    6/8

    7. Click On Test Connection

    8. If all is Ok, Click Previous, Copy the Connection String, and Click Cancel, Delete DataGridView if you don't need it.

    Oracle Connect ion Str ing

    Following is the Correct Format of Oracle Database Connection

    private static string CONNECTION_STRING ="User Id=myUserID;Password=myPassword;Data Source=(DESCRIPTION=" +

    "(ADDRESS=(PROTOCOL=TCP)(HOST=myserver.server.com)(PORT=yourPort#))" +

    "(CONNECT_DATA=(SID=yourSID)));"

    (For Detailed Study of Connection Strings)

    Onl ine Connect ion str ings

    SQL Connect ion Str in gs

    Do suggest/Comment, Help Others

    Comm ent R eques t !Thank you for reading this post. Please post your feedback, question, or comments about this post Here.

    Log into add your contents and source code to this article

    [ Top ] Rat e t h is ar t ic le 1 2 3

    Abou t t he au tho r

    Look ing f o r C# Consu l t i ng?

    C# Consulting is founded in 2002 by the founders of C# Corner. Unlike a tradit

    company, our consultants are well-known experts in .NET and many of them ar

    trainers. We specialize in Microsoft .NET development and utilize Agile Develop

    Programming practices to provide fast pace quick turnaround results. Our softw

    model is a mix of Agile Development, traditional SDLC, and Waterfall models.

    nection Strings for All Databases http://www.c-sharpcorner.com/uploadfile/2a62a4/connection-strings-fo...

    r 8 3/31/2012 1:38 AM

  • 8/2/2019 Connection Strings for All Databases

    7/8

    Current Version: 5.2011.8.6

    abdur rehman

    My Programming BlogClick here to learn mo

    Post a Feedback , Comm en t , o r Ques t i on abou t th i s a r t i c l e

    Sub jec t :

    Comment :

    Submi t

    Sponsored by

    Become a Spons

    Co m m e n t s

    Good Work by Manish On February 17, 2011Abdur, Nice work. Keep it up!

    R

    Re: Good Work by abdur On February 18, 2011lets keep helping each other

    R

    Nice Article.. by Manish On February 1 7, 2011

    Very helpfull article...

    R

    Re: Nice Article.. by abdur On February 1 8, 2011lets keep helping each other

    R

    Thank you by Sam On February 1 8, 2011I knew about UDL files but I forgot what the extension was. They are not something new but not enough people know about them. They can be very useful

    R

    Another option by knights On February 1 8, 2011Hi, Repeating the comments from one of the article by Suthish on the same subject. -----------------------------------------------------------------------------------

    would like to mention the following link by Microsoft.It guides to create connection string in a more generic way, incase if multiple server connections a

    available on internet and intranet.Thanks https://blogs.msdn.com/b/sqlforum/archive/2010/12/20/faq-how-do-i-find-the-correct-quot-server-quot-or-quot-da

    for-an-sql-server-instance-in-a-connection-string.aspx

    R

    Re: Another option by Sam On February 1 8, 2011I thought that the purpose of this article is to make it unnecessary to do the extra work that the instructions in that blog describes.

    R

    Hosted by MaximumASP | Found a broken link? | Contact Us | Terms & conditions | Privacy Policy | Site Map | Suggest an Idea | Advertise With Us

    Nevron Char t f o r .NET 2010 .1 Now Ava i l ab le

    The leading .NET charting control now features PDF, Flash and Silverlight export, visualization of large datasets and more. Deliver true charting functionality to your BI, Scorecard, Pr

    apps. Download evaluation now.

    nection Strings for All Databases http://www.c-sharpcorner.com/uploadfile/2a62a4/connection-strings-fo...

    r 8 3/31/2012 1:38 AM

  • 8/2/2019 Connection Strings for All Databases

    8/8

    Channels: Jobs | Interviews | Consulting | Training | Photos | Authors | Tips | Forums | Blogs

    P r o g r a m m i n g: C# | Visual Basic | ASP.NET & Web Development | C++ | Other .NET Languages | Windows Vista | XAML | Tutorials

    Sponsors : ASP.NET Hosting | Cbeyond Cloud Services | DynamicPDF | Nevron | RedGate Software | Team Foundation Hosting

    2012 contents copyright of their authors. Rest everything copyright Mindcracker. All rights reserved.

    nection Strings for All Databases http://www.c-sharpcorner.com/uploadfile/2a62a4/connection-strings-fo...