Browse Source

Merge branch 'master' of git.reinkober-it.de:crunch/FoxBaseChallenge into master

master
crunch 3 weeks ago
parent
commit
586cd04b0b
1 changed files with 0 additions and 23 deletions
  1. +0
    -23
      prisma/prisma.ts

+ 0
- 23
prisma/prisma.ts View File

@@ -1,23 +0,0 @@
import{ PrismaClient } from "@prisma/client";
const prisma = new PrismaClient();


async function addTopic() {

const topicCreated = await prisma.topic.create({
data: {
title: "Test Topic Title",
description: "Test Topic Description",
}
})
};

async function main() {
console.log("executed!");
const allTopics = await prisma.topic.findMany();
const createdTopic = await addTopic();
console.log("Topics: " + allTopics)
console.log("Created: " + createdTopic)
};

main().finally(async () => await prisma.$disconnect())

Loading…
Cancel
Save