Chapter 23 · SQL Server 2025 Features: Vector Data, AI-Oriented Workloads, and Modern Development

JSON/REST/Developer Improvements and How Modern App Patterns Interact with the Engine

Evaluate SQL Server 2025 JSON, regular-expression, REST, and developer additions according to their storage, compatibility, transaction, security, and deployment boundaries.

Advanced180–260 minutesDeveloper feature-boundary labSQL Server 2025 CU7 · 17.0.4065.4Compatibility 170 · Developer labSSMS 22.8.2 · Last reviewed August 2026

Learning outcomes

SQL Server 2025's developer story is broader than vectors. Native JSON storage, regular expressions, external REST invocation and smaller T-SQL improvements can reduce application glue—but each feature changes a different boundary. Native JSON changes storage and update semantics; regex changes text processing; REST invocation introduces outbound network and credential behavior; Data API Builder is an application-layer component rather than a new database transaction protocol. Good design asks what belongs inside the database transaction and what should remain in the application/integration tier.

01

Distinguish long-standing JSON functions from the preview native JSON data type in boxed SQL Server 2025.

02

Use SQL Server 2025 regular-expression functions at the correct compatibility level without replacing relational constraints blindly.

03

Explain sp_invoke_external_rest_endpoint enablement, permission, HTTPS and failure semantics.

04

Classify modern developer features by storage, transaction, security, driver and deployment boundary.

05

Avoid turning convenient in-engine HTTP or JSON support into tightly coupled application architecture.

Lab baseline. SQL Server 2025 (17.x), CU7 build 17.0.4065.4; compatibility level 170. SSMS 22.8.2 is the checked Windows administration tool; current VS Code + MSSQL extension and current sqlcmd are valid free alternatives. Azure Data Studio is retired. Mandatory labs use a free non-production SQL Server 2025 Developer edition and a disposable database named ServiceHubAILab. They use deterministic mock vectors, so no paid model API, API key, cloud account, or outbound network access is required. The native json type is still preview in boxed SQL Server 2025. Existing JSON functions over nvarchar remain mature. Regular expressions are SQL Server 2025 features; REGEXP_LIKE requires compatibility level 170. External REST invocation is available but disabled by default.

1. JSON functions and native JSON storage are not the same feature

SQL Server has supported JSON text functions since SQL Server 2016. SQL Server 2025 adds a native binary json data type, but the boxed SQL Server implementation is still preview. That means an existing production system does not need to convert every nvarchar(max) JSON column merely because 2025 exists. The migration decision should be driven by measured parse/update behavior, feature status, indexing requirements, driver/tool compatibility and rollback.

sql · use mature JSON text functions without enabling preview features
USE ServiceHubAILab;GODECLARE @payload nvarchar(max) = N'{"ticket":1001,"tags":["vpn","mfa"],"priority":2}';SELECT    ISJSON(@payload) AS is_valid_json,    JSON_VALUE(@payload, '$.ticket') AS ticket_id,    JSON_QUERY(@payload, '$.tags') AS tags;SELECT [value] AS tagFROM OPENJSON(@payload, '$.tags');
sql · inspect preview status before experimenting with native JSON
SELECT name, valueFROM sys.database_scoped_configurationsWHERE name = N'PREVIEW_FEATURES';GO-- Development/test only after current-release review:-- ALTER DATABASE SCOPED CONFIGURATION SET PREVIEW_FEATURES = ON;-- DECLARE @j json = '{"ticket":1001,"status":"open"}';-- SELECT @j;

Preview native JSON can offer parsed binary storage and its own modification capabilities, but preview is a lifecycle constraint, not just syntax. Keep production migration reversible until the feature you depend on is GA for your target platform.

SQL Server 2025 also includes fuzzy string matching functions such as edit-distance helpers, but the current release notes still classify fuzzy matching as preview behind PREVIEW_FEATURES. Do not confuse the GA regular-expression family with the preview fuzzy-matching family merely because both operate on strings.

2. Regular expressions add expressive text validation—at a cost

Regex is useful for validation and extraction where a relational predicate or simple LIKE is insufficient. It is not a replacement for typed columns, keys, check constraints or normalized data. A complex regex over every row can still consume CPU and may be less index-friendly than storing the parsed attribute explicitly.

sql · validate ServiceHub ticket references with REGEXP_LIKE
USE ServiceHubAILab;GODECLARE @samples TABLE(raw_value nvarchar(100));INSERT @samples VALUES(N'WO-2026-000123'),(N'wo-2026-000123'),(N'WO-26-123'),(N'WO-2026-ABC123');SELECT raw_value,       REGEXP_LIKE(raw_value, N'^WO-[0-9]{4}-[0-9]{6}$', 'c') AS is_validFROM @samples;

Here compatibility 170 is part of the feature contract. If the application already validates an identifier and the database stores the parsed year/id in typed columns, repeating an expensive regex in every query may add little value.

3. Calling REST from T-SQL introduces a distributed failure boundary

sys.sp_invoke_external_rest_endpoint can invoke HTTPS endpoints from SQL Server 2025. It requires the database permission EXECUTE ANY EXTERNAL ENDPOINT and server configuration external rest endpoint enabled, which is disabled by default. A 2xx response yields success; non-2xx HTTP status can be returned, and inability to make the call raises an exception. The database transaction is now coupled to DNS, TLS, network, endpoint throttling and remote service behavior.

sql · inspect REST invocation readiness without enabling or calling anything
SELECT name, value, value_in_useFROM sys.configurationsWHERE name = N'external rest endpoint enabled';GOUSE ServiceHubAILab;GOSELECT    HAS_PERMS_BY_NAME(DB_NAME(), 'DATABASE', 'EXECUTE ANY EXTERNAL ENDPOINT')      AS can_execute_external_endpoint;SELECT name, credential_identityFROM sys.database_scoped_credentials;
Avoid synchronous remote calls inside long OLTP transactions. A remote HTTP timeout can extend lock duration, consume worker time and couple database availability to a third party. For non-transactional side effects, an outbox/message pattern is usually easier to retry, rate-limit and observe.

4. “Modern development” still needs deployment boundaries

Use a small decision table mentally: native JSON affects storage; regex affects query expression semantics; REST invocation affects outbound integration; vectors affect data type/search; external models bind AI endpoints; Data API Builder exposes REST/GraphQL from an application component. These are not one feature family just because they are new in 2025.

sql · record a deployment feature inventory in the lab
USE ServiceHubAILab;GOIF OBJECT_ID(N'lab23.FeatureInventory', N'U') IS NULLBEGIN    CREATE TABLE lab23.FeatureInventory    (        feature_name nvarchar(100) PRIMARY KEY,        status_label varchar(20) NOT NULL,        required_scope varchar(40) NOT NULL,        production_default bit NOT NULL,        review_note nvarchar(400) NOT NULL    );END;DELETE lab23.FeatureInventory;INSERT lab23.FeatureInventory VALUES(N'VECTOR + core vector functions','GA','database',1,N'Use exact scans; benchmark candidate-set size.'),(N'CREATE VECTOR INDEX / VECTOR_SEARCH','Preview','database',0,N'Requires PREVIEW_FEATURES; dev/test only by default.'),(N'native json type','Preview','database',0,N'Boxed SQL Server 2025 preview.'),(N'regular expressions','GA','compatibility',1,N'REGEXP_LIKE requires compatibility 170.'),(N'external REST invocation','GA opt-in','instance+database',0,N'Disabled by default; outbound security and latency boundary.');SELECT * FROM lab23.FeatureInventory ORDER BY feature_name;

Maintaining this kind of deployment inventory prevents “engine version = feature availability” mistakes and gives operations a review checklist for upgrade/rollback.

5. Production judgment

Choose the smallest feature that solves the problem. Keep data typing and integrity in SQL Server; keep long-running orchestration, secret distribution, user-facing retries and third-party workflow in a layer designed for those concerns unless a measured reason justifies moving it into the engine. When a preview feature is involved, add a removal/upgrade test to the deployment plan.

Check your understanding

  1. Is the native JSON type GA in boxed SQL Server 2025?
  2. What compatibility level does REGEXP_LIKE require?
  3. What server configuration gates external REST invocation?
  4. Why can an in-transaction REST call be dangerous?
  5. Why is Data API Builder conceptually different from a native SQL data type?
Review the answers

1. No. It is currently preview in SQL Server 2025, even though JSON functions have existed for years.

2. Compatibility level 170 or higher.

3. external rest endpoint enabled, which is disabled by default.

4. It extends the transaction across DNS/TLS/network/remote-service failure and latency, potentially prolonging locks and worker use.

5. It is an application/API component that exposes REST/GraphQL; it does not change the database transaction/storage model in the same way.

Authoritative references

Keep knowledge open

Help the academy stay free and grow.

If these tutorials save you time, a small donation supports new lessons, technical review, diagrams, examples, and long-term maintenance.

ETHEthereum / ERC-20 only
0x716c4Ab160C4B66F31a28AE2448BfF68fc3a2ef0

Send only Ethereum or ERC-20 compatible assets to this address.