protected override void OnConfiguring(DbContextOptionsBuilder optionsBuilder)
{
optionsBuilder.UseSqlServer(LMCSettingHelper.GetLMCSQLCon(), opt => opt.UseRowNumberForPaging());
base.OnConfiguring(optionsBuilder);
}

没有从onfiguring就在oncreateing,都可以,

添加上允许使用

UseRowNumberForPaging即可

EFCore DbContext 报SqlException: Incorrect syntax near 'OFFSET'.的更多相关文章

  1. System.Data.SqlClient.SqlException: 'Incorrect syntax near 'OFFSET'.

    https://www.nopcommerce.com/boards/t/54586/410-not-running-on-local-system.aspx#209684 Hello, I was ...

  2. .Net EF Core数据库使用SQL server 2008 R2分页报错How to avoid the “Incorrect syntax near 'OFFSET'. Invalid usage of the option NEXT in the FETCH statement.”

    一.  问题说明 最近.Net EF core 程序部署到服务器,服务器数据库安装的是SQL server 2008 R2,我本地用的的是SQL server 2014,在用到分页查询时报错如下: H ...

  3. .NET Core EF框架使用SQL server 2008数据库分页问题:Incorrect syntax near 'OFFSET'. Invalid usage of the option NEXT in the FETCH statement

    一. 问题 最近.Net Core程序部署到服务器,采用EF6.本地数据库是SQL server 2016,服务器数据库安装的是SQL server 2008 R2,在用到分页查询时报错如下: { & ...

  4. 升级 nop 4.1 Incorrect syntax near 'OFFSET'. Invalid usage of the option NEXT in the FETCH statement.

    Incorrect syntax near 'OFFSET'.  Invalid usage of the option NEXT in the FETCH statement. nop.web 项目 ...

  5. mysql报错:java.sql.SQLException: Incorrect string value: '\xE4\xB8\x80\xE6\xAC\xA1...' for column 'excelName' at row 1

    一.问题 用Eclipse做项目时候报错 java.sql.SQLException: Incorrect string value: '\xE4\xB8\x80\xE6\xAC\xA1...' fo ...

  6. mysql插入报错:java.sql.SQLException: Incorrect string value: '\xE6\x9D\xAD\xE5\xB7\x9E...' for column 'address' at row 1

    界面报错: 日志报错: java.sql.SQLException: Incorrect at com.mysql.cj.jdbc.exceptions.SQLError.createSQLExcep ...

  7. MySQL报错:Cause: java.sql.SQLException: Incorrect string value: '\xE6\x9D\xA8","...' for column 'obj_value' at row 1

    1.插入MySQL表时,报错:Cause: java.sql.SQLException: Incorrect string value: '\xE6\x9D\xA8","...' ...

  8. java.sql.SQLException: Incorrect key file for table 'C:\Windows\TEMP\#sql578_6e2_68d.MYI'; try to repair it

    java.sql.SQLException: Incorrect key file for table 'C:\Windows\TEMP\#sql578_6e2_68d.MYI'; try to re ...

  9. MySQL添加中文字符集问题 --- java.sql.SQLException: Incorrect string value

    今天在做开关记录的时候,数据库表中description字段用于记录当前版本的描述(需要存储中文),在测试程序的时候发现如果用户输入中文,那么后台会报错.错误信息如下: java.sql.SQLExc ...

随机推荐

  1. CoreGraphic

    public func UIGraphicsBeginImageContextWithOptions( size: CGSize, opaque: Bool, _ scale: CGFloat) si ...

  2. windows7 64位系统下无法运行ipython

    windows7 64位系统下无法运行ipython | Creator 导航 导航 博客 分类 标签 友链 关于 大专栏  windows7 64位系统下无法运行ipythontent-post L ...

  3. 如何安装及使用honmaple社区程序 · honmaple's blog · 风落花语风落天,花落风雨花落田.

    Table of Contents 1. 如何安装及使用 1.1. 安装需要的package 1.2. 配置config 1.3. 注释下面代码 1.4. 初始化数据库 1.5. 创建管理员账户 2. ...

  4. Spring的工作原理

    一.什么是Spring (1).Spring真正的精华是它的Ioc模式实现的BeanFactory和AOP,它自己在这个基础上延伸的功能有些画蛇添足. (2). Spring它是一个开源的项目,而且目 ...

  5. jspdf + html2canvas 实现html转pdf (提高分辨率版本)

    刚解决了html中某div块生成pdf的问题,热乎乎的,赶紧记录下 引入的js传送门: https://cdnjs.cloudflare.com/ajax/libs/jspdf/1.0.272/jsp ...

  6. 使用MySQL练习增删改查时因为版本问题出现连接错误

    使用MySQL练习增删改查时出现连接错误,错误提示如下: 2020-02-19 19:53:51.088 ERROR 16328 --- [reate-249798694] com.alibaba.d ...

  7. Vue+axios(interceptors) 实现http拦截 + router路由拦截 (双拦截)+ 请求自带loading效果

    axios interceptors 拦截器 //interceptors.js // vue axios配置 发起请求加载loading请求结束关闭loading // http request 请 ...

  8. HTTP/1.1 与 HTTP/2.0

    HTTP/1.1 与 HTTP/2.0 HTTP/1.1 持久连接 非持久连接

  9. Redis使用指南

    原文链接 能坚持别人不能坚持的,才能拥有别人未曾拥有的.关注编程大道公众号,让我们一同坚持心中所想,一起成长!! 设置过期时间.释放资源 使用Redis做K-V存储,一定要注意过期时间的把控,任何K- ...

  10. Simulink仿真入门到精通(十一) 模块的封装

    当用户编写了自定义的S函数或者使用Simulink标准库中的模块搭建子系统后,可以通过封装为其设计显示外观,追加参数对话框. 封装是构建一个以对话框为接口的交互界面的过程,它将复杂的模块逻辑关系隐藏起 ...