I tried to loop the validation to test more data in the table but it opens new data doc every run.
for test in range(0, 2):
provSource = source.columns
for provTable in provSource:
print(provTable)
if provTable in SourceFilters:
filteredIf = source.get(provTable).iloc[test].upper()
sourceEmpty[provTable] = filteredIf
if SOURCEADDRESS in sourceEmpty:
filteredAddress = source.get(provTable).iloc[test].upper()[:4]
sourceEmpty[SOURCEADDRESS] = filteredAddress
#contains the new value from line 43
provSourceData = source.get(provTable).iloc[test].upper()
provAllDict[provTable] = provSourceData
if provTable in config.get(‘Formatter’):
provAllDict[provTable] = format.convert_Str_To_Int(provSourceData)
print(type(provAllDict.get(‘ProviderZip’)))
print(sourceEmpty.get('TaxIdentificationNumber'))
# Extract relevant data from destination
tax = destination['TaxID']
totid = destination[
(tax == sourceEmpty.get('TaxIdentificationNumber')) &
(destination['Hospital_N'] == sourceEmpty.get('GroupName')) &
(destination['Last'] == sourceEmpty.get('ProviderLastName')) &
(destination['Address'].str.startswith(sourceEmpty.get('ProviderAddress1')))
]