Type datetime2 is not a defined system type - Entity Framework 摘自网络

"Type datetime2 is not a defined system type"

Solution:

 

把edmx 改为 ProviderManifestToken="2005" 即可.

<?xml version="1.0" encoding="utf-8"?>
   2: <edmx:Edmx Version="1.0" xmlns:edmx="http://schemas.microsoft.com/ado/2007/06/edmx">
   3:   <!-- EF Runtime content -->
   4:   <edmx:Runtime>
   5:     <!-- SSDL content -->
   6:     <edmx:StorageModels>
   7:     <Schema Namespace="TcwsModel.Store" Alias="Self" Provider="System.Data.SqlClient" ProviderManifestToken="2005" xmlns:store="http://schemas.microsoft.com/ado/2007/12/edm/EntityStoreSchemaGenerator" xmlns="http://schemas.microsoft.com/ado/2006/04/edm/ssdl">

  

posted @ 2015-05-14 17:47  iDEAAM  阅读(458)  评论(0编辑  收藏  举报