0

我正在执行 GRAND stack real-estate-app “https://www.youtube.com/watch?v=WB--CkjKJMQ&list=PL9Hl4pk2FsvUjfSsxLolVToO5t1hwEIKK&index=2”项目的代码

我已经安装了所有依赖项并配置了数据库并在文件v3.5.18中设置了配置。.env

之后我运行了inferschema:write脚本。

使用以下代码更新了 schema.graphql 文件

type Property {
   _id: Long!
   AddressL_1: String
   AddressLin: String
   Assessment: String
   COUNTYCD: Int!
   CareOfTaxp: String
   Certificat: String
   CityStateZ: String
   Continuous: Float!
   CountyAbbr: String!
   CountyName: String!
   DbaName: String
   FallowAcre: Float!
   FarmsiteAc: Float!
   ForestAcre: Float!
   GISAcres: Float!
   GrazingAcr: Float!
   IrrigatedA: Float!
   LegalDescr: String
   LevyDistri: String
   NonQualAcr: Float!
   OwnerAdd_1: String
   OwnerAdd_2: String
   OwnerAddre: String
   OwnerCity: String
   OwnerName: String
   OwnerState: String
   OwnerZipCo: String
   PropType: String
   PropertyID: Int!
   Range: String
   SHAPE_Area: Float!
   SHAPE_Leng: Float!
   Section: String
   Subdivisio: String
   TaxYear: Int!
   TotalAcres: Float!
   TotalBuild: Int!
   TotalLandV: Int!
   TotalValue: Int!
   Township: String
   WildHayAcr: Float!
   id: String!
}

然后当我运行服务器时,我给了我以下错误

C:\Users<路径到文件夹>\practice-GRAND->STACK\realEstateApp\api\node_modules\graphql-compose\lib\TypeStorage.js:44

 throw new Error(`Type with name ${(0, _misc.inspect)(typeName)} does not exists`);
 Error: Type with name "Long" does not exists
4

1 回答 1

0

将标量 Long 添加到 schema.graphql 应该可以解决问题,但是如果您限制性地遵循 youtube 使用数据库 v3.5.18,则会出现另一个问题

驱动连接的数据库不支持多数据库。请升级到 neo4j 4.0.0 或更高版本才能使用此功能

于 2021-10-04T04:47:27.357 回答