Skip to content

ERPConnect.Utils.ReadTable

Namespace: ERPConnect.Utils
Assembly: ERPConnectStandard20.dll

Reads SAP database tables via RFC

public sealed class ReadTable

Inheritance

objectReadTable

Inherited Members

object.GetType(), object.ToString(), object.Equals(object?), object.Equals(object?, object?), object.ReferenceEquals(object?, object?), object.GetHashCode()

Constructors

ReadTable()

public ReadTable()

ReadTable(IR3Connection)

public ReadTable(IR3Connection connection)

Parameters

connection IR3Connection

Properties

Connection

public IR3Connection Connection { get; set; }

Property Value

IR3Connection

Fields

Represents the fields that should be / have been retrieved. This collection will be filled and / or refreshed during Run().

public ReadTableFieldCollection Fields { get; }

Property Value

ReadTableFieldCollection

OrderBy

Defines the order of the result on SAP side. Works only with specialized custom function modules.

public string OrderBy { get; set; }

Property Value

string

PackageSize

Number of rows to retrieve per RFC call

public int PackageSize { get; set; }

Property Value

int

RaiseIncomingPackageEvent

Indicates whether the IncomingPackage event should be raised and results should be processed per package.

public bool RaiseIncomingPackageEvent { get; set; }

Property Value

bool

Result

Result of the query, if IncomingPackage event is not used.

public DataTable Result { get; }

Property Value

DataTable

RowCount

Upper limit for number of rows retrieved in total

public int RowCount { get; set; }

Property Value

int

RowSkip

Number of rows to be skipped at the start.

public int RowSkip { get; set; }

Property Value

int

TableName

public string TableName { get; set; }

Property Value

string

WhereClause

Selection criteria

public string WhereClause { get; set; }

Property Value

string

Methods

AddField(string)

Appends a field to the Fields collection

public void AddField(string fieldName)

Parameters

fieldName string

Name of DDIC table field

RetrieveAllFieldsOfTable()

Retrieves all fields of the given table from SAP and fills the Fields collection

public void RetrieveAllFieldsOfTable()

Run()

Retrieves table rows from SAP. This method will block until all data has been extracted.

public void Run()

SetCustomFunctionName(string)

Call this method to use a custom function module. This overrides ERPConnect.IR3Connection.ReadTableFunctionName.

public void SetCustomFunctionName(string name)

Parameters

name string

Name of the custom function module

IncomingPackage

IncomingPackage is fired, when addtional data packages are fetched from SAP.

public event ReadTable.OnIncomingPackage IncomingPackage

Event Type

ReadTable.OnIncomingPackage

PackageProgress

PackageProgress is fired, when addtional data packages are fetched from SAP.

public event ReadTable.OnPackageProgress PackageProgress

Event Type

ReadTable.OnPackageProgress


Last update: January 10, 2024