PrismaP
Prisma15mo ago
2 replies
David

Argument "columnName" is missing (v5.21.1)

Attempting to run a create query with an unchecked input, but getting a "argument is missing" error. This is the query:
return await transactionClient.tableName.create({
  data: {
    createdById: 28506,
    editedById: 28506,
    statusId: 1,
    companyProductId: 74,
    runPeriodType: "meta",
    audienceType: "meta",
    destinationType: null,
    audienceLocationType: "zipcode",
    metaAdSetId: "---",
    name: "---",
    channelMetaCampaignId: 23,
+   channelMetaCampaign: {
+     create: CampaignChannelMetaCampaignCreateWithoutAdSetsInput | CampaignChannelMetaCampaignUncheckedCreateWithoutAdSetsInput,
+     connectOrCreate: CampaignChannelMetaCampaignCreateOrConnectWithoutAdSetsInput,
+     connect: CampaignChannelMetaCampaignWhereUniqueInput
+   }
  },

So channelMetaCampaignId is defined, yet it is complaining that I should define the checked variant. TypeScript doesn't complain about this, only runtime
Was this page helpful?