hinsxd
11/09/2018, 7:42 AMrank
depends on the number of created Posts, some other numeral values also depends on the rank
. What is the best way to organize data? The best way I could think of, is to do all calculation on Query, so that the rank
values will not be written to database and thus reduce chance of error. But then there seems to be TONS of database calls. What do you think?yolen
11/09/2018, 12:37 PMEtel
prolink007
11/09/2018, 6:19 PMlawjolla
11/09/2018, 7:57 PMGorodov Maksim
11/10/2018, 10:22 AMmezie
11/10/2018, 4:00 PMcmckinstry
11/10/2018, 6:44 PMprisma generate
bug. I’m guessing it has to do with my schema, but can’t seem to figure out how to fix itcmckinstry
11/10/2018, 6:45 PMroberto.guerra
11/10/2018, 6:50 PMrelations
between the types?roberto.guerra
11/10/2018, 6:52 PMtype Link {
id: ID! @unique
createdAt: DateTime!
description: String!
url: String!
postedBy: User @relation(name: "User")
votes: [Vote!]!
}
type User {
id: ID! @unique
name: String!
email: String! @unique
password: String!
links: [Link!]!
votes: [Vote!]!
}
type Vote {
id: ID! @unique
link: Link! @relation(name: "Link")
user: User! @relation(name: "User")
}
cmckinstry
11/10/2018, 6:52 PMcmckinstry
11/10/2018, 6:58 PMcmckinstry
11/10/2018, 7:00 PMSyntax Error: Expected Name, found }
roberto.guerra
11/10/2018, 7:05 PMcmckinstry
11/10/2018, 7:17 PMcmckinstry
11/10/2018, 7:18 PMcmckinstry
11/10/2018, 7:18 PMGenerating schema... 20ms
▸ Syntax Error: Expected Name, found }
Get in touch if you need help: <https://www.prisma.io/forum/>
To get more detailed output, run $ export DEBUG="*"
error Command failed with exit code 1.
cmckinstry
11/10/2018, 7:19 PMcmckinstry
11/10/2018, 7:19 PMcmckinstry
11/10/2018, 7:21 PMroberto.guerra
11/10/2018, 8:17 PMroberto.guerra
11/10/2018, 8:17 PMroberto.guerra
11/10/2018, 8:18 PMtype Link {
id: ID! @unique
createdAt: DateTime!
description: String!
url: String!
postedBy: User @relation(name: "UserOnLink")
votes: [Vote!]! @relation(name: "LinkOnVote")
}
type User {
id: ID! @unique
name: String!
email: String! @unique
password: String!
links: [Link!]! @relation(name: "UserOnLink")
votes: [Vote!]! @relation(name: "UserOnVote")
}
type Vote {
id: ID! @unique
link: Link! @relation(name: "LinkOnVote")
user: User! @relation(name: "UserOnVote")
}
roberto.guerra
11/10/2018, 8:18 PMGorodov Maksim
11/11/2018, 2:44 AMKrisTemmerman
11/11/2018, 1:00 PMKrisTemmerman
11/11/2018, 1:00 PMMoazzam
11/11/2018, 1:07 PMrein
11/11/2018, 1:28 PM