https://www.prisma.io/ logo
Join Slack
Powered by
# orm-help
  • f

    Francisco Herrera

    10/18/2019, 8:15 PM
    hello
  • f

    Francisco Herrera

    10/18/2019, 8:19 PM
    I have a question: this is my
    datamodel.prisma
    Copy code
    type User {
      id: ID! @id
      name: String!
      email: String! @unique
      password: String
      resetToken: String
      resetTokenExpiry: Float
      permissions: [Permission] @scalarList(strategy: RELATION)
    }
    after I ran
    prisma deploy
    , my
    generated/prisma.graphql
    createad queries and mutations. I try to run the query
    user(where: UserWhereUniqueInput!): User
    the problem is that the
    UserWhereUniqueInput
    generated looks like this:
    Copy code
    input UserWhereUniqueInput {
      id: ID
      email: String
    }
    so when i try to query an user, i only have the id on my app, and the query is requesting both id and email is this behavior normal, i was expecting to be able to query by id or email, not both at the same time to be able to get a single user my other option would be to query
    users
    and return the first element of the array.
  • p

    Piotr

    10/18/2019, 10:43 PM
    Hi, this has probably been asked, but what is the future of prisma 1?
    d
    s
    • 3
    • 5
  • c

    Chad H

    10/19/2019, 3:39 AM
    I tried using postgres connection pooling in digitalocean managed database. I kept getting search_path error (https://github.com/prisma/prisma/issues/4321). I'm a rookie when it comes to PG but I read somewhere that it can improve the performance because of how PG manages new connections coming in. For anyone hosting PG in production, would you go without this feature? Or should I be looking for other hosting provider?
  • a

    aluminick

    10/19/2019, 5:20 PM
    Hello I have a question.
  • a

    aluminick

    10/19/2019, 5:21 PM
    Copy code
    return context.prisma.createVote({
        user: { connect: { id: userId } },
        link: { connect: { id: args.linkId } },
      })
  • a

    aluminick

    10/19/2019, 5:21 PM
    is the
    connect
    key predefined?
  • a

    aluminick

    10/19/2019, 5:21 PM
    what does it do?
  • a

    aluminick

    10/19/2019, 5:21 PM
    Thank you for those who will answer.
  • m

    Mohammad Javad Ebrahimzadeh

    10/19/2019, 6:30 PM
    hello when i run prisma delete i get this error ERROR: GraphQL Error (Code: 400) { "error": "<!DOCTYPE html>\n<html>\n <head>\n <meta charset=\"utf-8\">\n <title>Bad Request – 400</title>\n <style>\n html, body {\n margin: 0;\n width: 100%;\n height: 100%;\n display: flex;\n justify-content: center;\n align-items: center;\n }\n\n body {\n font-family: -apple-system, BlinkMacSystemFont, \"Segoe UI\", Roboto, Helvetica, Arial, sans-serif, \"Apple Color Emoji\", \"Segoe UI Emoji\", \"Segoe UI Symbol\";\n font-size: 15px;\n }\n\n .Error {\n font-size: 1.35em;\n \n color: #6061BE;\n \n }\n\n .Error .message {\n font-weight: 200;\n letter-spacing: 0.095em;\n }\n\n .Error .message a {\n text-decoration: none;\n color: inherit;\n \n border-bottom: 1px dotted #6061BE;\n \n }\n\n .Error .status {\n font-weight: 700;\n }\n\n .Error .code {\n display: none;\n }\n\n .Error .dot {\n font-weight: 100;\n }\n\n @media screen and (max-width: 800px) {\n body {\n font-size: 10px;\n }\n\n .Error {\n display: flex;\n flex-direction: column;\n }\n\n .Error .status {\n font-size: 1.1em;\n }\n\n .Error .dot {\n display: none\n }\n }\n </style>\n </head>\n <body>\n <div class=\"Error\">\n <span class=\"status\">Bad Request</span>\n <span class=\"code\">400</span>\n <span class=\"dot\">•</span>\n \n <span class=\"message\">Please try your request again or contact support.</span>\n \n </div>\n </body>\n</html>", "status": 400 }
    n
    • 2
    • 4
  • m

    Mohammad Javad Ebrahimzadeh

    10/19/2019, 6:30 PM
    anyone can help me?
  • o

    Oh Hyun Won

    10/20/2019, 3:05 PM
    This is my type and I get this error, can anyone help? Thanks
  • c

    cellograph

    10/21/2019, 3:42 AM
    Does prisma support replica set?
  • m

    Mohammad Javad Ebrahimzadeh

    10/21/2019, 2:19 PM
    hi guys
  • m

    Mohammad Javad Ebrahimzadeh

    10/21/2019, 2:19 PM
    i cant run prisma deploy
  • m

    Mohammad Javad Ebrahimzadeh

    10/21/2019, 2:20 PM
    it doesnt give any error
  • m

    Mohammad Javad Ebrahimzadeh

    10/21/2019, 2:20 PM
    like its freezing
  • f

    Foxinni

    10/21/2019, 2:21 PM
    Hi, I’m following this tutorial
    <https://www.codemochi.com/blog/2019-08-12-prisma-2-now>
  • f

    Foxinni

    10/21/2019, 2:23 PM
    I get quite far but then the
    /graphql
    endpoint give me a bizarre error.
    r
    • 2
    • 10
  • m

    Mohammad Javad Ebrahimzadeh

    10/21/2019, 2:26 PM
    anyone related?
  • r

    Ricco

    10/21/2019, 2:39 PM
    Hello. What is the purpose of lift?
  • r

    Ricco

    10/21/2019, 2:39 PM
    It says database migration, but migrate to what exactly? Thanks
    k
    • 2
    • 3
  • n

    Nikhil

    10/21/2019, 2:52 PM
    @Harshit how can I add queue_size config to prisma configuration. I am on Prisma 1.34.10( as you suggested updated to latest 😛 ). I don't see any documentation around it. I see your comment on one of issue in github to update queue_size but couldn't find any documentation around it on site. can you please help me with it?
    h
    • 2
    • 2
  • n

    Nelson Pecora

    10/21/2019, 4:04 PM
    hey, does anyone know the best pattern to do something like a batch upsert? I’m encountering errors trying to
    seed
    a bunch of data (~10k records) and I think I might be going about it wrong
    • 1
    • 1
  • r

    Ricco

    10/21/2019, 4:31 PM
    ooo this prisma 2 is quite easy to add to an existing project, even without specific docs on it 👍
  • n

    Nelson Pecora

    10/21/2019, 4:37 PM
    when seeding data, is there a way to avoid concurrency issues when we create relations? e.g. if I have records A and B, and I want to seed both and connect them, I need to make sure I do them in a particular order (e.g. create A, then create B with
    { relationship: { connect: A } }
    )
    • 1
    • 2
  • c

    cellograph

    10/21/2019, 7:22 PM
    Does prisma has replica set support for mongodb? If not, then is there a chance we will get it on Prisma 2?
    r
    • 2
    • 1
  • z

    Zane Helton

    10/22/2019, 12:51 AM
    I'm running into this after upgrading Prisma2 last week. Any ideas?
    • 1
    • 1
  • z

    Zane Helton

    10/22/2019, 12:54 AM
    And I get this if I try running it in Docker. But I'm 99% I'm not missing any types
  • d

    danlannz

    10/22/2019, 12:58 AM
    @Zane Helton did you run
    prisma generate
    like it suggests
1...323324325...637Latest