1
tj
2025-02-27 416c1940daf1150d72b653c0ccf6fbd50155024f
app/src/main/java/com/example/firstapp/database/dao/CodeDao.kt
@@ -41,4 +41,11 @@
    @Query("SELECT * FROM Code order by time desc")
    abstract fun getAllCodesDesc():  List<Code>
    @Query("""
        SELECT * FROM Code
        WHERE type LIKE '%' || :keyword || '%'
        ORDER BY time DESC
    """)
    fun getByKeyword(keyword: String): List<Code>
}