【问题标题】:Difference between Data Source and Server in connection String [duplicate]连接字符串中数据源和服务器之间的区别[重复]
【发布时间】:2023-03-10 21:17:01
【问题描述】:

为什么有些连接字符串是Data Source = address; Initial Catalog = dbname;.... 而有些是Server=address;database=dbname;...?使用“数据源”和“服务器”有什么区别?

【问题讨论】:

    标签: sql-server connection-string


    【解决方案1】:
    【解决方案2】:
    there is no difference between Server and Data Source as they represent 
    the same thing for SQL Server : the full name of the SQL Server instance with 
    the syntax "MyComputerName\MyShortInstanceName" , potentially including the 
    port used by the SQL Server instance to communicate.
    

    Data Source
    -or-
    Server
    -or-
    Address
    -or-
    Addr
    -or-
    Network Address
    

    是同义词

    what is the difference between using data source = and using server = in connection string

    “Server” vs “Data Source” in connection string

    SqlConnection.ConnectionString Property

    【讨论】:

    • Oracle 或 TeraData 等其他提供商怎么样。哪个是标准的,或者哪个适用于大多数数据库提供商?任何参考将不胜感激
    • @Nagraj:我知道 connectionStrings 网站。我特别想知道是否有一些定义的标准或定义了不同提供商之间常用的某种准则。
    猜你喜欢
    • 2018-11-10
    • 1970-01-01
    • 2014-06-12
    • 1970-01-01
    • 2013-02-08
    • 1970-01-01
    • 2015-07-11
    • 2023-03-15
    • 1970-01-01
    相关资源
    最近更新 更多