SELECT *, CASE WHEN `locality` LIKE "nicasio%" AND `slide_location` = "" AND `logo_file_name` IS NOT NULL THEN 10 WHEN `slide_location` = "" AND `logo_file_name` IS NOT NULL THEN 5 END as `rank` FROM `wp_slides` WHERE st = "CA" AND (locality IN ("nicasio") OR locality IS NULL) AND (cat IS NULL) AND name NOT IN ("home-top", "home-bot") AND (slide_file_name IS NOT NULL AND slide_file_name != "") AND (slide_location IS NULL OR slide_location = "") AND name NOT IN ("agent") AND active = 1 ORDER BY `rank` DESC LIMIT 12
[0] matching rows / [0.00 msec]
Blog ID 2
Blah
SELECT *, "0" as `rank` FROM `wp_slides` WHERE st = "CA" AND (cat IS NULL) AND (slide_file_name IS NOT NULL AND slide_file_name != "") AND (slide_location IS NULL OR slide_location = "") AND active = 1 ORDER BY `rank` DESC LIMIT 12
[0] matching rows / [0.00 msec]
Blog ID 2
Blah
$6,475,00041 Cypress RdPoint Reyes Station CA 94956View Listing
$4,995,000165 Crescent RdSan Anselmo CA 94960View Listing
$4,900,0001401 Valley RdNicasio CA 94946View Listing
$3,495,00010 E Robert DrInverness CA 94937View Listing
$3,350,00025 Elizabeth PlInverness CA 94937View Listing
$2,998,00080 Palomino CirNovato CA 94947View Listing
$2,900,00011620 Point Reyes Petaluma RdNicasio CA 94946View Listing
$2,550,00015 Saddle Wood DrNovato CA 94945View Listing
$2,500,00010905 State Route 1 HwyPoint Reyes Station CA 94956View Listing
$2,420,00075 Oak Shade LnNovato CA 94945View Listing
$1,975,0001830 Marion AveNovato CA 94945View Listing
LIGHTBOX-IMAGES
LENDORS & TITLE COMPANIES
SELECT *, "0" as `rank` FROM `wp_slides` WHERE st = "CA" AND (cat = "lenders" OR cat IS NULL) AND (slide_file_name IS NOT NULL AND slide_file_name != "") AND (slide_location IS NULL OR slide_location = "") AND active = 1 ORDER BY `rank` DESC LIMIT 12
[0] matching rows / [0.00 msec]
Blog ID 2
Blah