#url.datasource#
select mfr_id, mfr_name from tblManufacturers m with (nolock) where exists ( select * from tbl_PRD_Skus s with (nolock) inner join tbl_OPR_ProductStatus ps with (nolock) on ps.skuId = s.skuId and ps.ownerId = s.ownerId and ps.ownerType = s.fsl_tablecode where s.mfrId = m.mfr_id and s.ownerId = and s.fsl_tablecode = ) order by mfr_name
select listId, listName from tbl_LST_PartnerLists where ownerId = and ownerType = and partnerType = 'OPR' order by listName
select distinct fsl_choId, companyName from tbl_OPR_ClientOperators with (nolock) where ownerId = and fsltablecode = and oprCompanyType in ( 'G', 'C' ) and fsl_choId > 0 order by companyName

Only for Broker Clients

select operatorId from tbl_OPR_CLientOperators opr where opr.ownerId = and opr.fsltablecode = and opr.fsl_choId =

The Member Group is mapped more than once in the target library account

select fileProcessor from tbl_EAI_inboundFileProcessors with (nolock) where ownerId = and ownertype = and fileFormat = 'COMPARE_OPERATORS_TXT' insert into tbl_EAI_inboundFileProcessors ( ownerId, ownerType, fileName, fileProcessor, fileFormat, clientProcessEmail, fseProcessEmail, allowUpload, processingWindowStartHr24, processingWindowLengthHr, defaultBatchClass ) values ( , , '^compare_operators\.txt$', '/mstrQueries/utilityQueries/DataImport/Compare/Compare.cfm', 'COMPARE_OPERATORS_TXT', 'gerry@fsenablers.com','brett@fsenablers.com','Y', 0, 24, 'Z' ) select distinct opr.companyName cho_name, opr.address cho_address, opr.address2 cho_address2, left( opr.city, 50 ) cho_city, left( opr.state, 5 ) cho_state, opr.zipcode cho_zipCode, opr.url cho_url, opr.comments cho_comments, opr.recordSource cho_recordSource, coalesce( opr.fsl_choid, 0 ) fsl_choId, opr.operatorId, coalesce( opr.oprSegment, 0 ) as cho_segmentId from tbl_OPR_ClientOperators opr with (nolock) inner join tbl_CRM_Affiliations a with (nolock) on a.partnerId = opr.operatorId and a.partnerType = 'OPR' and a.orgType = 'OPR' and a.orgId = and a.ownerId = opr.ownerId and a.ownerType = opr.fsltablecode inner join tbl_BID_Agencies a with (nolock) on a.partnerId = opr.operatorId and a.ownerId = opr.ownerId and a.ownerType = opr.fsltablecode and a.partnerType = 'OPR' inner join tbl_BID_Bids b with (nolock) on b.bidAgencyId = a.bidAgencyid and b.ownerId = a.ownerId and b.ownerType = a.ownerType inner join tbl_OPR_ClientSegments cseg with (nolock) on cseg.clientSegId = opr.oprsegment and cseg.ownerId = opr.ownerId and cseg.fsl_tablecode = opr.fsltablecode and cseg.clientSegId in ( ) inner join tbl_TPM_Contracts ct with (nolock) on ct.ownerId= opr.ownerId and ct.ownerType = opr.fsltablecode and ct.partnerType = 'OPR' and ct.partnerId = opr.operatorId inner join tbl_OPR_ProductStatus ps with (nolock) on ps.operatorId = opr.operatorId and ps.ownerType = opr.fsltablecode and ps.ownerId = opr.ownerId inner join tbl_PRD_Skus s with (nolock) on s.ownerId = ps.ownerId and s.fsl_tablecode = ps.ownerType and s.skuId = ps.skuId and s.mfrId in ( ) inner join tbl_Fspro_members bsr with (nolock) on bsr.fspro_userId = opr.mfr_bsr_id and bsr.ownerId = opr.ownerId and bsr.fsl_tablecode = opr.fsltablecode where nullif( opr.address, '' ) is not null and nullif( opr.city, '' ) is not null and nullif( opr.state, '' ) is not null and opr.ownerId = and opr.fsltablecode = and opr.lastInteractionDate > and opr.lastInteractionDate <= and exists ( select * from tbl_LST_PartnerListItems pli where pli.listId = and pli.partnerId = opr.operatorId ) and coalesce( opr.fsl_choId, 0 ) = 0 and opr.oprCompanyType = '0' -- units and independents only order by cho_name Found #qmd_compareSource.recordCount# Operators

Click GO to initiate the 1FS Compare processor for the #lsnumberformat( qmd_compareSource.recordCount )# target operators. Doing so will perform an Compare Batch which will auto link all exact matches and Queue all those that could not be matched. The end to end time might be quite long depending on the number of operators. Process can be monitored in Batch Manager for the library account.


For Dev Team use only!

#htmleditformat( _r.sql )#
insert into tbl_IMPORT_1FSOperators ( eai_batchId, eai_lineNumber, ownerId, ownerType , #_c# ) values ( , , , , ) update tbl_EAI_InboundBatches set loadedColumns = , lineCount = , batchTime = , statusTime = , loadedTime = , queueStatus = 0, status = 'PENDING', message = 'Waiting in line...', batchClass = 'A' where batchId = and ownerId = and ownertype =