PRODUCTION

DEMO

DEVELOPMENT

select b.broker_id as pkId, b.broker_name as companyName from tblBrokers b where exists ( select * from tbl_LIB_Companies where companyPKeyId = broker_id and companyPType = 'BRO' ) and b.broker_id <> 1665 order by broker_name select c.cho_id as pkId, c.cho_name as companyName from tbl_CHO_Operators c where exists ( select * from tbl_LIB_Companies where companyPKeyId = cho_id and companyPType = 'CHO' ) order by cho_name select d.dstId as pkId, d.dstName as companyName from tbl_DST_Distributors d where exists ( select * from tbl_LIB_Companies where companyPKeyId = dstId and companyPType = 'DST' ) order by dstName select m.mfr_id as pkId, m.mfr_name as companyName from tblManufacturers m where exists ( select * from tbl_LIB_Companies where companyPKeyId = mfr_id and companyPType = 'MFR ' ) and m.mfr_id <> 1984 order by mfr_name
select cho_id, cho_name, cho_address, cho_address2, cho_city, cho_state, cho_zipcode, cho_countryId, cho_type, opr.operatorId, opr.companyName, opr.address, opr.address2, opr.city, opr.state, opr.zipcode, opr.countryId, opr.oprCompanyType, ter.name territoryName, m.firstName, m.lastName, m.fspro_userid from tbl_CHO_Operators cho left outer join tbl_OPR_ClientOperators opr on opr.fsl_choId = cho.cho_Id and opr.ownerId = and opr.fsltablecode = left outer join tbl_TER_Territories ter on ter.territoryId = opr.territoryId and ter.ownerId = opr.ownerId and ter.fsl_tablecode = opr.fsltablecode left outer join tbl_FSpro_members m on m.fspro_userid = opr.mfr_bsr_id and m.ownerId > 0 where 1 = 2 or coalesce( cho_type, 'O' ) not in ( 'C', 'G', 'I', 'U' ) or coalesce( cho_type, 'O' ) in ( 'G' ) or coalesce( cho_type, 'O' ) in ( 'C' ) order by cho_name select broker_name as companyName from tblbrokers where broker_id = select cho_name as companyName from tbl_CHO_Operators where cho_id = select dstName as companyName from tbl_DST_Distributors where dstId = select mfr_name as companyName from tblManufacturers where mfr_id =

Invalid #_ownerType#



select ter.territoryId, ter.name territoryName, ter.internalSalesId from tbl_TER_Territories ter inner join tbl_TER_TerritoryLevels lvl on lvl.levelId = ter.levelId and lvl.hidden = 'N' and lvl.brokerLevel = 0 where ter.ownerId = and ter.fsl_tablecode = order by territoryName select distinct m.fspro_userid, m.firstName, m.lastName from tbl_Fspro_Members m inner join tbl_TER_TeamMembers tm on tm.teamMemberUserId = m.fspro_userId and tm.territoryId in ( ) where m.ownerId = and m.fsl_tablecode = and m.staffMember = 1 and m.loginEnabled = 1 order by lastName, firstName
  Chain Operator #htmleditformat( qmd_company.companyName )# Operator
#htmleditformat( cho_name )# CMCGPOOther(#cho_type#) #cho_id#
#htmleditformat( cho_address )#
#htmleditformat( cho_address2 )#

#htmleditformat( cho_city )#, #htmleditformat( cho_state )# #htmleditformat( cho_zipcode )#
INTERNATIONAL

#htmleditformat( companyName )# CMCGPOOther(#oprCompanyType#) #operatorId#
#htmleditformat( address )#
#htmleditformat( address2 )#

#htmleditformat( city )#, #htmleditformat( state )# #htmleditformat( zipCode )#
INTERNATIONAL

Territory: #htmleditformat( territoryName )#

Account Owner: #htmleditformat( lastName )#, #htmleditformat( firstName )#

&##160;