src/routers/kfjl.rs:67:10
|
67 | .first::<Kfjl>(&db_connection) {
| ^^^^^ the trait `LimitDsl` is not implemented for `diesel::query_builder::SelectStatement<schema::kfjl::table, diesel::query_builder::select_clause::DefaultSelectClause, diesel::query_builder::distinct_clause::NoDistinctClause, diesel::query_builder::where_clause::WhereClause<diesel::expression::operators::Eq<schema::kfjl::columns::kfjlname, diesel::expression::bound::Bound<diesel::sql_types::Text, &std::string::String>>>>`
|
= help: the following implementations were found:
<diesel::query_builder::SelectStatement<F, S, D, W, O, L, Of, G, LC> as LimitDsl>
非常奇怪的 问题当我的表字段在30个的时候 编译没有问题 当我增加到31个的时候就开始报错 开始我以为是我字段语法问题 结果我发现。只要把随意注释i个字段 然后前面加了就报错的字段可以正常边缘 也就是只要30个字段 你怎么加都不回报错。一旦超过30个 你加什么都错 ###我不知道这是我个人问提还是库的问题
1
共 6 条评论, 1 页
评论区
写评论谢谢 果然是feature的问题 谢谢
--
👇
Freddie Mercury: 看了下Github,似乎也有人遇到了类似的问题,但报错信息不一样。可能须要激活某个feature。有完整点的代码贴出来看看不?
https://github.com/diesel-rs/diesel/issues/2435
https://docs.rs/crate/diesel/1.4.5/source/Cargo.toml
成了 谢谢 开启128就好了
--
👇
苦瓜小仔: 【猜测】开启
huge-tables
或者64-column-tables
或者128-column-tables
feature 试试谢谢 我先试试别的方案。不行再发出来
--
👇
Freddie Mercury: 看了下Github,似乎也有人遇到了类似的问题,但报错信息不一样。可能须要激活某个feature。有完整点的代码贴出来看看不?
https://github.com/diesel-rs/diesel/issues/2435
https://docs.rs/crate/diesel/1.4.5/source/Cargo.toml
谢谢 我试试
--
👇
苦瓜小仔: 【猜测】开启
huge-tables
或者64-column-tables
或者128-column-tables
feature 试试【猜测】开启
huge-tables
或者64-column-tables
或者128-column-tables
feature 试试看了下Github,似乎也有人遇到了类似的问题,但报错信息不一样。可能须要激活某个feature。有完整点的代码贴出来看看不?
https://github.com/diesel-rs/diesel/issues/2435
https://docs.rs/crate/diesel/1.4.5/source/Cargo.toml