Skip to content

Commit

Permalink
Merge pull request #27 from geoadmin/dev_fix_for_deploy
Browse files Browse the repository at this point in the history
Dev fix for deploy
  • Loading branch information
loicgasser committed Oct 29, 2013
2 parents b420580 + dd604a8 commit fa136ad
Showing 1 changed file with 10 additions and 2 deletions.
12 changes: 10 additions & 2 deletions conf/sphinx.conf.in
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ source src_swisssearch : def_pqsql
sql_db = search
sql_attr_uint = num
sql_attr_bigint = id
sql_attr_bigint = len
sql_attr_uint = rank
sql_attr_string = label
sql_attr_string = origin
Expand All @@ -27,9 +28,10 @@ source src_address : src_swisssearch
gid as id \
, search_name as detail \
, coalesce(strname1,'')||' '||coalesce(deinr,'')||' <b>'||coalesce(plz,'')||' '||coalesce(ort_27,'')||'</b>' as label \
, textlen(search_name) as len \
, origin as origin \
, st_box2d(the_geom) as geom_st_box2d \
, 6 as rank \
, rank as rank \
, gid as id \
, NULLIF(regexp_replace(deinr::text, '[^0-9]'::text, ''::text, 'g'::text), ''::text)::integer as num \
from swiss_search \
Expand All @@ -43,9 +45,10 @@ source src_parcel : src_swisssearch
gid as id \
, search_name as detail \
, coalesce(gemname,'')||' '||coalesce(name,'') as label \
, textlen(search_name) as len \
, origin as origin \
, st_box2d(the_geom) as geom_st_box2d \
, 7 as rank \
, rank as rank \
, gid as id \
, SUBSTRING(name FROM '([0-9]+)')::int as num \
from swiss_search \
Expand All @@ -59,6 +62,7 @@ source src_sn25 : src_swisssearch
gid as id \
, search_name as detail \
, '<b>'||coalesce(name,'')||'</b> ('||coalesce(kanton,'')||') - '||coalesce(gemname,'') as label \
, textlen(search_name) as len \
, origin as origin \
, st_box2d(the_geom) as geom_st_box2d \
, rank as rank \
Expand All @@ -75,6 +79,7 @@ source src_gg25 : src_swisssearch
gid as id \
, search_name as detail \
, '<b>'||coalesce(gemname,'')||' ('||coalesce(kanton,'')||')</b>' as label \
, textlen(search_name) as len \
, origin as origin \
, st_box2d(the_geom) as geom_st_box2d \
, rank as rank \
Expand All @@ -90,6 +95,7 @@ source src_kantone : src_swisssearch
SELECT \
gid as id \
, remove_accents(search_name) as detail \
, textlen(search_name) as len \
, '<b>'||name||'</b>' as label \
, origin as origin \
, st_box2d(the_geom) as geom_st_box2d \
Expand All @@ -106,6 +112,7 @@ source src_district : src_swisssearch
SELECT \
gid as id \
, search_name as detail \
, textlen(search_name) as len \
, '<b>'||name||'</b>' as label \
, origin as origin \
, st_box2d(the_geom) as geom_st_box2d \
Expand All @@ -123,6 +130,7 @@ source src_zipcode : src_swisssearch
gid as id \
, search_name as detail \
, '<b>'||coalesce(plz,'')||' - '||coalesce(ort_27,'')||' ('||coalesce(kanton,'')||')</b>' as label \
, textlen(search_name) as len \
, origin as origin \
, st_box2d(the_geom) as geom_st_box2d \
, rank as rank \
Expand Down

0 comments on commit fa136ad

Please sign in to comment.