22 lines
750 B
TypeScript
22 lines
750 B
TypeScript
import { DSQL_TableSchemaType, PostInsertReturn } from "../../../types";
|
|
import { DbContextsArray } from "./runQuery";
|
|
type Param<T extends {
|
|
[k: string]: any;
|
|
} = any, K extends string = string> = {
|
|
dbContext?: (typeof DbContextsArray)[number];
|
|
dbFullName?: string;
|
|
tableName: K;
|
|
tableSchema?: DSQL_TableSchemaType;
|
|
identifierColumnName: keyof T;
|
|
identifierValue: string | number;
|
|
forceLocal?: boolean;
|
|
};
|
|
/**
|
|
* # Delete DB Entry Function
|
|
* @description
|
|
*/
|
|
export default function deleteDbEntry<T extends {
|
|
[k: string]: any;
|
|
} = any, K extends string = string>({ dbContext, dbFullName, tableName, identifierColumnName, identifierValue, forceLocal, }: Param<T, K>): Promise<PostInsertReturn | null>;
|
|
export {};
|