sp_xml_preparedocument를 실행하면 구문 분석된 XML 문서가 SQL Server 2000의 내부 캐시에 저장됩니다. MSXML 파서는 SQL Server에서 사용할 수 있는 전체 메모리의 최대 1/8까지 사용합니다. MSXML에 할당된 캐시 부분의 메모리가 부족하여 sp_xml_preparedocument 문에 지정된 문서를 열 수 없습니다. 이는 지정한 문서가 너무 크거나 해당 메모리 공간에 이미 있는 문서로 인해 새 문서에 필요한 공간이 부족하기 때문일 수 있습니다.
XML 문서 구문 분석에 대한 자세한 내용은 온라인 설명서의 "sp_xml_preparedocument" 및 "sp_xml_removedocument"를 참조하십시오.
sp_xml_removedocument를 실행하여 메모리에서 문서를 제거하십시오. 문서 처리를 완료하면 코드가 항상 sp_xml_removedocument를 호출하는지 확인합니다. 코드에서는 sp_xml_preparedocument 및 sp_xml_removedocument 호출 간의 연결이나 트랜잭션이 중단될 가능성을 고려해야 합니다. 이렇게 하려면 일괄 처리가 중단된 경우 열린 문서 핸들을 참조할 수 있는 테이블에 이 열린 문서 핸들을 저장해야 합니다.
이름 | 설명 | 기본값 |
사용 | 워크플로를 사용하거나 사용하지 않도록 설정합니다. | 예 |
우선 순위 | 알림 우선 순위를 정의합니다. | 1 |
심각도 | 알림 심각도를 정의합니다. | 1 |
Target | Microsoft.SQLServer.2012.DBEngine | ||
Category | EventCollection | ||
Enabled | True | ||
Event_ID | 6624 | ||
Event Source | $Target/Property[Type="SQL!Microsoft.SQLServer.DBEngine"]/ServiceName$ | ||
Alert Generate | True | ||
Alert Severity | Warning | ||
Alert Priority | Normal | ||
Remotable | True | ||
Alert Message |
| ||
Event Log | Application | ||
Comment | Mom2012ID='{136A2E5E-A460-4FAE-8587-D72C945E89EB}';MOM2012GroupID={467ECC75-C5DA-42BD-955C-A73BBB51AF74} |
ID | Module Type | TypeId | RunAs |
---|---|---|---|
_F6DA1507_12AF_11D3_AB21_00A0C98620CE_ | DataSource | Microsoft.Windows.EventProvider | Microsoft.SQLServer.SQLDefaultAccount |
GenerateAlert | WriteAction | System.Health.GenerateAlert | Default |
<Rule ID="Microsoft.SQLServer.2012.XML___XML_document_could_not_be_created_because_server_memory_is_low._Use_sp_xml_removedocument_to_release_XML_documents_1_5_Rule" Target="SQL2012Core!Microsoft.SQLServer.2012.DBEngine" Enabled="true" ConfirmDelivery="true" Remotable="true" Comment="Mom2012ID='{136A2E5E-A460-4FAE-8587-D72C945E89EB}';MOM2012GroupID={467ECC75-C5DA-42BD-955C-A73BBB51AF74}">
<Category>EventCollection</Category>
<DataSources>
<DataSource ID="_F6DA1507_12AF_11D3_AB21_00A0C98620CE_" Comment="{F6DA1507-12AF-11D3-AB21-00A0C98620CE}" TypeID="Windows!Microsoft.Windows.EventProvider" RunAs="SQL!Microsoft.SQLServer.SQLDefaultAccount">
<ComputerName>$Target/Host/Property[Type="Windows!Microsoft.Windows.Computer"]/NetworkName$</ComputerName>
<LogName>Application</LogName>
<Expression>
<And>
<Expression>
<SimpleExpression>
<ValueExpression>
<XPathQuery>PublisherName</XPathQuery>
</ValueExpression>
<Operator>Equal</Operator>
<ValueExpression>
<Value>$Target/Property[Type="SQL!Microsoft.SQLServer.DBEngine"]/ServiceName$</Value>
</ValueExpression>
</SimpleExpression>
</Expression>
<Expression>
<SimpleExpression>
<ValueExpression>
<XPathQuery>EventDisplayNumber</XPathQuery>
</ValueExpression>
<Operator>Equal</Operator>
<ValueExpression>
<Value>6624</Value>
</ValueExpression>
</SimpleExpression>
</Expression>
</And>
</Expression>
</DataSource>
</DataSources>
<WriteActions>
<WriteAction ID="GenerateAlert" TypeID="SystemHealth!System.Health.GenerateAlert">
<Priority>1</Priority>
<Severity>1</Severity>
<AlertMessageId>$MPElement[Name="Microsoft.SQLServer.2012.XML___XML_document_could_not_be_created_because_server_memory_is_low._Use_sp_xml_removedocument_to_release_XML_documents_1_5_Rule.AlertMessage"]$</AlertMessageId>
<AlertParameters>
<AlertParameter1>Event ID: $Data/EventDisplayNumber$. $Data/EventDescription$</AlertParameter1>
</AlertParameters>
<Suppression>
<SuppressionValue/>
</Suppression>
</WriteAction>
</WriteActions>
</Rule>