====== REG Matching ====== Changes made to the Windows registry happen immediately, and no backup is automatically made. Do not edit the Windows registry unless you are qualified and confident about doing so. \\ \\ Microsoft have issued the following warning with respect to the Registry Editor: \\ //"Using Registry Editor incorrectly can cause serious, system-wide problems that may require you to re-install Windows to correct them. Microsoft cannot guarantee that any problems resulting from the use of Registry Editor can be solved. Use this tool at your own risk."// TapeTrack supports matching against a list of patterns stored in the Windows Registry using the special filter prefix: ''*REG:registry_value_name'' * Registry key name This allows a filter field to be compared against multiple patterns defined centrally in the Windows Registry. REG filtering is functionally similar to [[technote:list|LIST]] filtering, however the patterns are stored in a registry value instead of a file. ===== How REG Matching Works ===== When a filter begins with: *REG: TapeTrack will: * open the Windows Registry * locate the specified value name * read its contents * treat the contents as a semicolon-separated list of patterns * stop as soon as a match is found ===== Registry Backup ===== Backup the registry before any making any modifications Open regedit and create registry backup by right-clicking the top of the registry tree and selecting Export and saving to an appropriate location. {{:master:tapemaster_registry_backup.png}} ===== Registry Location ===== Registry location: HKEY_CURRENT_USER\Software\GazillaByte\TapeTrack\Lists Each registry value under this key represents a reusable filter list. If the Key Lists does not exist, it will need to be added in the location HKEY_CURRENT_USER\Software\GazillaByte\TapeTrack\Lists ===== Example ===== Example set of Description values for Volumes in TapeMaster: Production database weekly backup \\ Prod DB full backup \\ Prod data backup set \\ Production export dump \\ Development database backup \\ Weekly archive - finance system \\ ==== Example Registry Value ==== Registry Key: HKEY_CURRENT_USER\Software\GazillaByte\TapeTrack\Lists Create a new String Value named: ProdFilters With the following data (semicolon-separated, no spaces): *prod*;*PRD*;*production* {{reg_filter_keys.png}} ==== Using the REG Filter in TapeMaster ==== To filter the Description field using the registry list: *REG:ProdFilter {{reg_filter_prod.png}} This will match any Description containing: * prod * PRD * production ===== Expected Matching Results ===== Using the filter: *REG:ProdFilter The following descriptions would typically match: Production database weekly backup \\ Prod DB full backup \\ Production export dump \\ PRD database BKP \\ Prod data backup set \\ The following descriptions would typically not match: Development database backup \\ Weekly archive - finance system \\ ===== Using Wildcards in REG Values ===== Each entry in the registry value supports standard TapeTrack wildcard matching. Example registry value data: *backup*;*archive*;*dump* This allows a single REG filter to match multiple categories of Description text. ===== When to Use REG vs LIST ===== ^ Method ^ Storage Location ^ Best Used For ^ | LIST | External text file | Shared configuration files | | REG | Windows Registry | Centralised per-user configuration | REG filtering is especially useful in environments where: * administrators want centrally managed filter sets * users should not modify external files * reusable filter definitions are required across multiple tools REG filtering provides a centralized, reusable method of matching a field against multiple wildcard patterns stored in the Windows Registry. It behaves the same as LIST filtering, but stores the pattern list inside: HKEY_CURRENT_USER\Software\GazillaByte\TapeTrack\Lists This makes it ideal for controlled environments where filter rules need to be maintained per user or workstation. =====See Also===== [[general:pattern_matching|pattern matching]] \\ [[technote:list|LIST Matching \\ [[technote:FUZZY|FUZZY Matching]] \\ {{tag> technote pattern string}}