title: prisma2: how to fetch nested fields?
body: <p>In prisma 1 I have used fragment to fetch the nested fields.</p>
  
  <p>For example:</p>
  
  <pre><code>const mutations = {
    async createPost(_, args, ctx) {
      const user = await loginChecker(ctx);
      const post = await prisma.post
        .create({
          data: {
            author: {
              connect: {
                id: user.id,
              },
            },
            title: args.title,
            body: args.body,
            published: args.published,
          },
        })
        .$fragment(fragment);
  
      return post;
    },
  };
  </code></pre>
  
  <p>but seems like in prisma2 it is not supported. because by running this on playground,</p>
  
  <pre><code>mutation CREATEPOST {
    createPost(
      title: "How to sleep?"
      body: "Eat, sleep, repaet"
      published: true
    ) {
      title
      body
      published
      author {
        id
      }
    }
  }
  
  </code></pre>
  
  <p>I am getting,</p>
  
  <pre><code>"prisma.post.create(...).$fragment is not a function",
  </code></pre>