gpt4 book ai didi

sql - 数据库项目 - 设置特定设置 ANSI_NULL_DEFAULT/sp_fulltext_database

转载 作者:行者123 更新时间:2023-12-03 21:00:45 26 4
gpt4 key购买 nike

我们目前正在将 .sqlproject 用于 Visual Studio 中的现有数据库。

在构建 dacpac 并运行命令 sqlpackage.exe/Action:script 时,我收到以下脚本化更改:

2019-09-11T15:28:56.5658868Z :setvar DatabaseName "MyDb"
2019-09-11T15:28:56.5658868Z GO
2019-09-11T15:28:56.5658868Z USE [$(DatabaseName)];
2019-09-11T15:28:56.5658868Z GO
2019-09-11T15:28:56.5658868Z IF EXISTS (SELECT 1
2019-09-11T15:28:56.5658868Z FROM [master].[dbo].[sysdatabases]
2019-09-11T15:28:56.5658868Z WHERE [name] = N'$(DatabaseName)')
2019-09-11T15:28:56.5658868Z BEGIN
2019-09-11T15:28:56.5658868Z ALTER DATABASE [$(DatabaseName)]
2019-09-11T15:28:56.5658868Z SET ANSI_NULLS ON,
2019-09-11T15:28:56.5658868Z ANSI_PADDING ON,
2019-09-11T15:28:56.5658868Z ANSI_WARNINGS ON,
2019-09-11T15:28:56.5658868Z ARITHABORT ON,
2019-09-11T15:28:56.5658868Z CONCAT_NULL_YIELDS_NULL ON,
2019-09-11T15:28:56.5658868Z QUOTED_IDENTIFIER ON,
2019-09-11T15:28:56.5658868Z ANSI_NULL_DEFAULT ON,
2019-09-11T15:28:56.5658868Z CURSOR_DEFAULT LOCAL
2019-09-11T15:28:56.5658868Z WITH ROLLBACK IMMEDIATE;
2019-09-11T15:28:56.5658868Z END
2019-09-11T15:28:56.5658868Z
2019-09-11T15:28:56.5658868Z
2019-09-11T15:28:56.5658868Z GO
2019-09-11T15:28:56.5658868Z IF EXISTS (SELECT 1
2019-09-11T15:28:56.5658868Z FROM [master].[dbo].[sysdatabases]
2019-09-11T15:28:56.5658868Z WHERE [name] = N'$(DatabaseName)')
2019-09-11T15:28:56.5658868Z BEGIN
2019-09-11T15:28:56.5658868Z ALTER DATABASE [$(DatabaseName)]
2019-09-11T15:28:56.5658868Z SET PAGE_VERIFY NONE
2019-09-11T15:28:56.5658868Z WITH ROLLBACK IMMEDIATE;
2019-09-11T15:28:56.5658868Z END
2019-09-11T15:28:56.5658868Z
2019-09-11T15:28:56.5658868Z
2019-09-11T15:28:56.5658868Z GO
2019-09-11T15:28:56.5658868Z IF fulltextserviceproperty(N'IsFulltextInstalled') = 1
2019-09-11T15:28:56.5658868Z EXECUTE sp_fulltext_database 'enable';
2019-09-11T15:28:56.5658868Z
2019-09-11T15:28:56.5658868Z
2019-09-11T15:28:56.5658868Z GO
2019-09-11T15:28:56.5658868Z PRINT N'Update complete.';
2019-09-11T15:28:56.5658868Z
2019-09-11T15:28:56.5658868Z
2019-09-11T15:28:56.5658868Z GO
2019-09-11T15:28:56.5658868Z ##[warning] END SQL SCRIPT TO DEPLOY
2019-09-11T15:28:56.5658868Z ##[section]Finishing: Confirm SQL Deploy Script

我设法找到设置并更改以匹配以下内容:
  • ANSI_NULLS
  • ANSI_PADDING
  • ANSI_警告
  • ARITHABORT
  • CONCAT_NULL_YEILDS_NULL
  • QUOTED_IDENTIFIER
  • CURSOR_DEFAULT
  • SET_PAGE_VERIFY

  • 但是我一生都无法找到最后几个属性在哪里更改它们以匹配实时数据库。
  • ANSI_NULL_DEFAULT
  • sp_fulltext_database

  • 关于在哪里可以找到最后两个以便我们所有的环境都与实时数据库匹配的任何想法?

    最佳答案

    我也在寻找 ANSI_NULL_DEFAULT 设置,但我认为在下的数据库项目设置中启用/禁用了“sp_fulltext_database”

    Project Settings->Database Settings...

    Under the "Miscellaneous" tab

    "Enable full text search"



    编辑:
    抱歉,没有看到您在 sqlpackage 下这样做了,而不是 Visual Studio。但希望这为您指明了正确的方向。

    关于sql - 数据库项目 - 设置特定设置 ANSI_NULL_DEFAULT/sp_fulltext_database,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/57908720/

    26 4 0
    Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
    广告合作:1813099741@qq.com 6ren.com