INSERT INTO [dbo].[AgentMemories]
([MemoryId],
    [WorkspaceId],
    [AgentId],
    [Domain],
    [SourceTaskId],
    [SourceReviewId],
    [SourceType],
    [Content],
    [Summary],
    [TagsJson],
    [Confidence],
    [CreatedUtc],
    [CreatedBy],
    [CreatedByDisplayName],
    [UpdatedUtc],
    [ExpiresUtc],
[LastAccessedUtc])
VALUES (@MemoryId, @WorkspaceId, @AgentId, @Domain, @SourceTaskId, @SourceReviewId, @SourceType, @Content, @Summary, @TagsJson, @Confidence, @CreatedUtc, @CreatedBy, @CreatedByDisplayName, @UpdatedUtc, @ExpiresUtc, @LastAccessedUtc);

SELECT *
FROM [dbo].[AgentMemories]
WHERE [MemoryId] = @MemoryId;
