[Prisma] CreatedAt / UpdatedAt 필드 정의 되지 않은 오류

2019. 11. 17. 20:07Tutorial & Training

728x90

Reason: 'createdAt' Field 'createdAt' is not defined in the input type ''.

 

 

 

 

참고자료

https://stackoverflow.com/questions/52173791/correct-way-to-declare-fields-for-prisma-provided-by-graphql-yoga-but-not-requir

 

Correct way to declare fields for Prisma provided by GraphQL Yoga but not required in resolver

I've been trying to find some documentation on this on the Prisma websites but to be honest it's a bit difficult to find very detailed use cases there, especially when the problem is as difficult to

stackoverflow.com

 

(https://stackoverflow.com/questions/52173791/correct-way-to-declare-fields-for-prisma-provided-by-graphql-yoga-but-not-requir)

 

createdAtPlayground에서 order by쿼리를 요청할 때 사용되는 숨겨져서 보호되는 필드였고,

필드명에 At이 붙어서 오류가 난다는것을 확인할 수 있었다네요.

 

때문에 Fieldname에서 at를 붙이시면 안됩니다.

728x90