server database

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • little83
    New Member
    • Feb 2009
    • 26

    server database

    if I create username and password to the sql server through these statment

    [CODE]
    USE <database name> GO


    CREATE USER <new user name> FOR LOGIN <login name> ; GO
    [\CODE]



    what will be the connection string on that case..I mean the connection string u have to mention database...will it be the master datatbase..so the connection string will be

    [CODE]
    string conntemp = (@"Data Source=.\SQLEXP RESS;Database = master;Integrat ed Security=True;C onnect Timeout=30;User Instance=True;" );
    [\CODE]

    one other question...

    how display the avialabe database on the server on order to let the user choose between them ?

    and how to display the avialabe server in order to connect to any of them?
  • ck9663
    Recognized Expert Specialist
    • Jun 2007
    • 2878

    #2
    Here's the oen for database and one for servers


    -- CK

    Comment

    Working...