How to Compare two layer’s object: Get AOT objects both modified in USR & SL1 layer
2010-12-08 13:30
507 查看
[code]static void CompareJob(Args _args)
{
UtilElements utilElements;
UtilElements_Job utilElementsJob;
UtilElements_Job utilElementsJob_usr;
UtilElements_Job utilElementsJob_sl1;
;
delete_from utilElementsJob;
Insert_Recordset utilElementsJob(utilLevel, recordType, parentId, name)
select utilLevel, recordType, parentId, name from utilElements
where utilElements.utilLevel == UtilEntryLevel::usr || utilElements.utilLevel == UtilEntryLevel::sl1;
info("Imported completed!");
while select utilElementsJob_usr join utilElementsJob_sl1
where utilElementsJob_usr.utilLevel == UtilEntryLevel::usr
&& utilElementsJob_sl1.utilLevel == UtilEntryLevel::sl1
&& utilElementsJob_usr.name == utilElementsJob_sl1.name
// && utilElementsJob_usr.parentId == 0 && utilElementsJob_sl1.parentId == 0
&&
(
(utilelementsJob_usr.recordType == UtilElementType::Class && utilelementsJob_sl1.recordType == UtilElementType::Class)
||
(utilelementsJob_usr.recordType == UtilElementType::Form && utilelementsJob_sl1.recordType == UtilElementType::Form)
||
(utilelementsJob_usr.recordType == UtilElementType::Table && utilelementsJob_sl1.recordType == UtilElementType::Table)
)
{
info(utilElementsJob_usr.name);
}
}
[/code]
How it works:
1. There is one special table in AOT\System Documentation\Tables\UtilElements, firstly, create a similar table UtilElements_Job with those fields: utilLevel(Enum: UtilEntryLevel), recordType(Enum: UtilElementType), parentId(int), name(EDT: Name)
2. import data from UtilElements table into new table UtilElements_Job
Bcs it’s very slow when querying the UtilElements table. (I cannot find the UtilElements table in AOT Data Dictionary tables folder, Maybe it is a system table, a file-based table, or a queried table…)
3. while select…
相关文章推荐
- [RxJS] How To get the results of two HTTP requests made in sequence
- How to get details about patch applied in Oracle Applications by OAM & SQL?
- How to get the mapping relationship between two columns in a table
- prjGetWriteINIFile - How to Read-Write INI file using VB & API - 读取/写入INI文件 - VB6 + API - SourceCode - HackerJLY
- How to get an icon of an object in Windchill
- How to get the object type in javascript:
- How to compare two worksheets in a workoo
- Get "Server Down" when retrieve the channel list in sopcast, how to solve it?
- How to get multiple select value both in javascript and php
- [eZ publish] When a ezxml embed an video, how to get the ezxml object in the video embed template?
- How to get the object type in javascript:
- How to get rid of `deprecated conversion from string constant to 'char*'` warnings in GCC?
- How to get Time Separator in Jav…
- How to compare two cells value in Grid via Compare Validator?
- How to make two <div>…</div> in the same row?
- From an inner class, "this" points to the inner object. How do I get a "this" pointer to the enclosing object?
- How to get objects from Info*Engine Group in Wi...
- How to get the content of the 'identity' section in web.config
- How to attach to Browser Helper Object (BHO) with C# in two minutes
- how&nbsp;to&nbsp;setup&nbsp;dns&nbsp;in&nbsp;android