Co-Authored-By: Claude Sonnet 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_017ic4b4XrpfdpsacrvqnrBM
19 lines
423 B
Java
19 lines
423 B
Java
package com.ankurm.data;
|
|
|
|
import jakarta.data.repository.Find;
|
|
import jakarta.data.repository.OrderBy;
|
|
import jakarta.data.repository.Repository;
|
|
import org.hibernate.StatelessSession;
|
|
|
|
import java.util.List;
|
|
|
|
/** "year" is not an attribute of Book (it is publishedYear). */
|
|
@Repository
|
|
public interface BadOrderBy {
|
|
StatelessSession session();
|
|
|
|
@Find
|
|
@OrderBy("year")
|
|
List<Book> byAuthor(String author);
|
|
}
|