jsforce
    Preparing search index...

    Class SObject<S, N, FieldNames, RetrieveRecord, InputRecord, UpdateRecord>

    A class for organizing all SObject access

    Type Parameters

    Index
    _conn: Connection<S>
    _logger: Logger
    approvalLayouts$: CachedFunction<() => Promise<DescribeApprovalLayoutsResult>>
    compactLayouts$: CachedFunction<() => Promise<DescribeCompactLayoutsResult>>
    del: {
        (ids: string[], options?: DmlOptions): Promise<SaveResult[]>;
        (ids: string, options?: DmlOptions): Promise<SaveResult>;
        (
            ids: string | string[],
            options?: DmlOptions,
        ): Promise<SaveResult | SaveResult[]>;
    } = ...

    Synonym of SObject#destroy()

    Type Declaration

    delete: {
        (ids: string[], options?: DmlOptions): Promise<SaveResult[]>;
        (ids: string, options?: DmlOptions): Promise<SaveResult>;
        (
            ids: string | string[],
            options?: DmlOptions,
        ): Promise<SaveResult | SaveResult[]>;
    } = ...

    Synonym of SObject#destroy()

    Type Declaration

    deleteBulk: (
        input?: string | Readable | Record[],
    ) => Batch<S, "insert" | "update" | "upsert" | "delete" | "hardDelete"> = ...

    Synonym of SObject#destroyBulk()

    Type Declaration

      • (
            input?: string | Readable | Record[],
        ): Batch<S, "insert" | "update" | "upsert" | "delete" | "hardDelete">
      • Bulkly delete records specified by input data using bulk API

        Parameters

        • Optionalinput: string | Readable | Record[]

        Returns Batch<S, "insert" | "update" | "upsert" | "delete" | "hardDelete">

    deleteHardBulk: (
        input: Readable | Record[],
    ) => Batch<S, "insert" | "update" | "upsert" | "delete" | "hardDelete"> = ...

    Synonym of SObject#destroyHardBulk()

    Type Declaration

      • (
            input: Readable | Record[],
        ): Batch<S, "insert" | "update" | "upsert" | "delete" | "hardDelete">
      • Bulkly hard delete records specified in input data using bulk API

        Parameters

        Returns Batch<S, "insert" | "update" | "upsert" | "delete" | "hardDelete">

    insert: {
        (records: InputRecord[], options?: DmlOptions): Promise<SaveResult[]>;
        (records: InputRecord, options?: DmlOptions): Promise<SaveResult>;
        (
            records: InputRecord | InputRecord[],
            options?: DmlOptions,
        ): Promise<SaveResult | SaveResult[]>;
    } = ...

    Synonym of SObject#create()

    Type Declaration

    insertBulk: (
        input?: string | Readable | Record[],
    ) => Batch<S, "insert" | "update" | "upsert" | "delete" | "hardDelete"> = ...

    Synonym of SObject#createBulk()

    Type Declaration

      • (
            input?: string | Readable | Record[],
        ): Batch<S, "insert" | "update" | "upsert" | "delete" | "hardDelete">
      • Bulkly insert input data using bulk API

        Parameters

        • Optionalinput: string | Readable | Record[]

        Returns Batch<S, "insert" | "update" | "upsert" | "delete" | "hardDelete">

    layouts$: CachedFunction<(ln?: string) => Promise<DescribeLayoutResult>>
    layouts$$: CachedFunction<(ln?: string) => DescribeLayoutResult>
    type: N
    _logger: Logger = ...
    • Call Bulk#load() to execute bulkload, returning batch object

      Parameters

      • operation: "insert" | "update" | "upsert" | "delete" | "hardDelete"
      • OptionaloptionsOrInput: string | Object | Readable | Record[]
      • Optionalinput: string | Readable | Record[]

      Returns Batch<S, "insert" | "update" | "upsert" | "delete" | "hardDelete">

    • Count num of records which matches given conditions

      Parameters

      Returns Query<
          S,
          N,
          SObjectRecord<
              S,
              N,
              | "*"
              | FieldPathScopedProjection<
                  S,
                  N,
                  Extract<keyof S["SObjects"][N]["Fields"], string>,
              >
              | FieldPathScopedProjection<
                  S,
                  N,
                  {
                      [K in string]?: | "*"
                      | FieldPath_1<
                          Extract<(...)[(...)][K], SObjectDefinition>,
                          Extract<(...)[(...)], SObjectDefinition>["ParentReferences"],
                      >[]
                  },
              >,
              Record,
              {},
          >,
          "Count",
      >

    • Bulkly insert input data using bulk API

      Parameters

      • Optionalinput: string | Readable | Record[]

      Returns Batch<S, "insert" | "update" | "upsert" | "delete" | "hardDelete">

    • Bulkly delete records specified by input data using bulk API

      Parameters

      • Optionalinput: string | Readable | Record[]

      Returns Batch<S, "insert" | "update" | "upsert" | "delete" | "hardDelete">

    • Bulkly hard delete records specified in input data using bulk API

      Parameters

      Returns Batch<S, "insert" | "update" | "upsert" | "delete" | "hardDelete">

    • Returns the list view info in specifed view id

      Parameters

      • id: string

        List view ID

      Returns ListView

    • Get reference for specified quick aciton in the SObject

      Parameters

      • actionName: string

        Name of the quick action

      Returns QuickAction<S>

    • Bulkly update records by input data using bulk API

      Parameters

      • Optionalinput: string | Readable | Record[]

      Returns Batch<S, "insert" | "update" | "upsert" | "delete" | "hardDelete">

    • Bulkly upsert records by input data using bulk API

      Parameters

      • Optionalinput: string | Readable | Record[]
      • OptionalextIdField: string

      Returns Batch<S, "insert" | "update" | "upsert" | "delete" | "hardDelete">