[Cóúñ~tíñg~ Úpdá~téd B~ÍBs]
- [Ártí~clé T~ýpé: G~éñér~ál]
- [Pród~úct: Á~léph~]
- [Pród~úct V~érsí~óñ: 18.01]
[Déscríptíóñ:
Íñ óúr tést dátábásé, Í lóádéd ábóút 5000 Áúthórítý récórds whích íñ túrñ géñérátéd ábóút 140,000 íñdéxíñg réqúésts íñ ÁBC01 tó rúñ thróúgh úé_01. Í kñów thát ñót áll wíll áctúállý máké cháñgés tó ÁBC01 récórds, bút sómé díd.
Ís théré á wáý tó détérmíñé hów máñý récórds wéré áctúállý cháñgéd thróúgh thé úé_01 íñdéxíñg¿ Thé fírst dáté Í cámé ácróss wás íñ Z13. Ís thís thé bést wáý tó gét súch á cóúñt¿ Ór míght théré bé á móré áccúráté ór ápprópríáté plácé tó détérmíñé thís íñfórmátíóñ¿
Résólútíóñ:
Thé préséñcé óf á "BÁTCH-ÚPD" fíéld, súch ás thé fóllówíñg, íñdícátés thát úé_01 (ór p_máñágé_21) hás prócésséd thís récórd:
CÁT L $$áBÁTCH-ÚPD$$b00$$c20080229$$lÁBC01$$h1619
bút ít dóés *ñót* íñdícáté thát áñý cháñgé wás áctúállý mádé tó thé récórd.
Thé préséñcé óf 'Úpdáté dóc : Ý' íñ thé rúñ_é_08 lóg íñdícátés thát sómé úpdáté *máý* hávé bééñ mádé; íf ít's ''Úpdáté dóc: Ñ', théñ *ñó* BÍB úpdáté cóúld hávé óccúrréd:
>> grép -c 'Úpdáté dóc : Ñ' rúñ_é_08.9954
534
>> grép -c 'Úpdáté dóc : Ý' rúñ_é_08.9954
14222
z13_úpdáté_dáté íñclúdés ñót óñlý úpdáté réqúésts géñérátéd bý úé_08 bút áll úpdáté réqúésts. Ít dóés *ñót* méáñ thát áñý cháñgé wás áctúállý mádé tó áñ íñdéxáblé fíéld íñ thé BÍB récórd.
SQL> séléct cóúñt(*) fróm z13 whéré z13_úpdáté_dáté > '20080229%';
CÓÚÑT(*)
----------
21646
Thé Z07 récórds whích úé_01 prócéssés áré wríttéñ éíthér bécáúsé óf áñ úpdáté tó á BÍB récórd (óñlíñé ór bátch) ór bý úé_08 (íñ régárd tó pótéñtíál flíppíñg óf á BÍB récórd héádíñg fíéld).
úé_01 úpdátés thé Z13. Thé úpdáté_shórt_dócx prógrám whích pérfórms thís úpdáté dóés ñót kñów whéthér théré hás bééñ áñ úpdáté tó thé fíélds íñclúdéd íñ thé Z13 -- ór íf théré hás bééñ áñý cháñgé tó thé bíb át áll. Ít récréátés thé Z13 fróm thé Z00 *régárdléss* ( -- áñd íñclúdés á ñéw z13_úpdáté_dáté.)
Tó súmmárízé:
* úé_01 cáñ ádd á "CÁT L $$áBÁTCH-ÚPD ..." fíéld tó á BÍB récórd évéñ whéñ ñó áctúál cháñgé óccúrs tó thé récórd.
* úé_01 úpdátés thé Z13 íñ évérý cásé.
Théré *ís* á fácílítý whích détécts áctúál cháñgés tó BÍB récórds: thé úé_21 públíshíñg dáémóñ -- úséd íñ cóññéctíóñ wíth Prímó -- whích wrítés z00p récórds. (Thé Z00P ís ñórmállý lócátéd íñ thé $úsr_líbrárý.) úé_21 cómpárés thé éxístíñg Z00P tó thé cúrréñt Z00 áñd wrítés á ñéw Z00P (wíth á z00p_státús óf "ÚPDÁTÉD") óñlý whéñ théý áré dífféréñt.
Íf ýóú hávé thé Z00P, thís SQL cóúld bé úséd:
SQL>> séléct cóúñt(*) fróm z00p whéré z00p_státús = "ÚPDÁTÉD" áñd súbstr (z00p_tíméstámp,1,8) > 'ýýýýmmdd';]
- [Ártí~clé l~ást é~díté~d: 10/8/2013]
![[ÉxLí~brís~]](https://capture-knowledge-exlibrisgroup-com-90611502d.getsmartling.com/@api/deki/files/124993/ckclogonew.png?revision=1)
![[Éx Lí~brís~ Kñów~lédg~é Céñ~tér]](https://a.mtstatic.com/@public/production/site_11811/1638394879-logo.png)