package com.gurkensalat.osm.repository;

import com.gurkensalat.osm.entity.LinkedPlace;
import org.springframework.data.repository.PagingAndSortingRepository;
import org.springframework.data.repository.query.Param;
import org.springframework.data.rest.core.annotation.RepositoryRestResource;

@RepositoryRestResource(collectionResourceRel = "linkedPlace", path = "linkedPlace")
public interface LinkedPlaceRepository extends PagingAndSortingRepository<LinkedPlace, Long>
{
    LinkedPlace findByOsmId(@Param("osm_id") String osmId);

    LinkedPlace findByDitibCode(@Param("D_CODE") String ditibCode);
}

@@ -506,14 +506,14 @@
 am(%22
-osm_id
+OSM_ID
 %22) S
@@ -568,16 +568,20 @@
 Param(%22D
+ITIB
 _CODE%22) 

Clean up schema a bit