string(1522) "SELECT * FROM
(
(
SELECT Zip,UpDateTime,True_statusid,PropertyTypeid ,ListPrice ,Beds ,Baths ,Sqft,LotSize,YearBuilt,Address ,ImageCity,ImageNames ,listdate ,HomeID,agentid ,"1" AS agent_house_sign ,"1" AS agent_top_sign ,titleDes, h.StatusID, '' as table1_name, '' as table1_id FROM home_agent as h JOIN status b on h.statusid=b.statusid JOIN county c ON b.idcounty=c.idcounty JOIN state d ON c.idstate=d.idstate WHERE 1 = 1 AND h.StatusID = 367 AND `ListPrice`> 100000 AND SUBSTRING(ImageCity,1,8)<'20250312' AND ( d.idstate =15 ) AND agentid = 3491 AND True_statusid>0 AND activate = 1 and ImageNames != '' order by top_house desc,UpDateTime desc limit 1000
)
Union all
(
SELECT h.Zip,h.UpDateTime,h.True_statusid,h.PropertyTypeid ,h.ListPrice,h.Beds,h.Baths,h.Sqft,h.LotSize,h.YearBuilt,h.Address,h.ImageCity,h.image_main as ImageNames,h.listdate,h.HomeID,"" as agentid,"0" AS agent_house_sign ,"0" AS agent_top_sign ,"" AS titleDes, h.StatusID, h.table1_name, h.table1_id FROM home as h FORCE INDEX (coveringindex1) JOIN status b on h.statusid=b.statusid JOIN county c ON b.idcounty=c.idcounty JOIN state d ON c.idstate=d.idstate WHERE 1 = 1 AND h.StatusID = 367 AND `UpDateTime`>=0 AND `True_statusid` > 0 AND SUBSTRING(ImageCity,1,8)<'20250312' AND ( d.idstate =15 ) order by h.UpDateTime desc limit 1000
)
) AS a
ORDER BY agent_house_sign desc, UpDateTime desc limit 0,20"