### Error querying database. Cause: com.microsoft.sqlserver.jdbc.SQLServerException: Invalid object name 'WMS_Inventory_View'. ### The error may exist in file [E:workspacecloneoumengcrmoumeng-bizoumeng-biz-wmstargetclassesmappingProudctMapper.xml] ### The error may involve cn.com.oumeng.biz.wms.mapper.ProductMapper.queryInventoryKL-Inline ### The error occurred while setting parameters ### SQL: select * from WMS_Inventory_View where 1=1 and sku = ? ### Cause: com.microsoft.sqlserver.jdbc.SQLServerException: Invalid object name 'WMS_Inventory_View'. ; bad SQL grammar []; nested exception is com.microsoft.sqlserver.jdbc.SQLServerException: Invalid object name 'WMS_Inventory_View'.] with root cause com.microsoft.sqlserver.jdbc.SQLServerException: Invalid object name 'WMS_Inventory_View'.项目背景
通过苞米豆baomidou的@DS注解来实现配置动态数据源的
产生问题原因在方法上使用了 @Transactional 注解 ,导致了事务内数据源锁定 无法切换
解决使用 @DSTransactional 注解



