GetAll(Nullable<Int32>,String,String,Nullable<Int32>,Nullable<Double>,Nullable<Int32>,Nullable<Int32>,Nullable<Int32>,Nullable<Int32>,Nullable<Int32>,Nullable<Int32>,Nullable<Int32>,Nullable<Int32>,Nullable<Int32>,Nullable<Boolean>,Nullable<Int32>,Nullable<Int32>,Nullable<Int32>,Nullable<Int32>,String,String,String,String,String,Nullable<DateTime>) Method
- Last UpdatedNov 06, 2025
- 8 minute read
The GetAll() method retrieves one or more sample frequency records from the Sample_Freq table, as specified by the filter parameters. Passing no filter parameters will retrieve all sample freq records from the table.
This overload of the method includes the startDelay input parameter.
'Declaration
Public Overloads Shared Function GetAll( _
ByVal freqId As Nullable(Of Integer), _
ByVal freqName As String, _
ByVal freqDesc As String, _
ByVal freqType As Nullable(Of Integer), _
ByVal interval As Nullable(Of Double), _
ByVal intervalUnit As Nullable(Of Integer), _
ByVal prodResetOption As Nullable(Of Integer), _
ByVal startDelay As Nullable(Of Integer), _
ByVal offsetStart As Nullable(Of Integer), _
ByVal offsetStartUnit As Nullable(Of Integer), _
ByVal offsetEnd As Nullable(Of Integer), _
ByVal offsetEndUnit As Nullable(Of Integer), _
ByVal samplesPerShift As Nullable(Of Integer), _
ByVal multiplier As Nullable(Of Integer), _
ByVal enabled As Nullable(Of Boolean), _
ByVal expiryTime As Nullable(Of Integer), _
ByVal expiryUnit As Nullable(Of Integer), _
ByVal warningTime As Nullable(Of Integer), _
ByVal warningUnit As Nullable(Of Integer), _
ByVal spare1 As String, _
ByVal spare2 As String, _
ByVal spare3 As String, _
ByVal spare4 As String, _
ByVal lastEditBy As String, _
ByVal lastEditAt As Nullable(Of Date) _
) As DataSet
'Usage
Dim freqId As Nullable(Of Integer)
Dim freqName As String
Dim freqDesc As String
Dim freqType As Nullable(Of Integer)
Dim interval As Nullable(Of Double)
Dim intervalUnit As Nullable(Of Integer)
Dim prodResetOption As Nullable(Of Integer)
Dim startDelay As Nullable(Of Integer)
Dim offsetStart As Nullable(Of Integer)
Dim offsetStartUnit As Nullable(Of Integer)
Dim offsetEnd As Nullable(Of Integer)
Dim offsetEndUnit As Nullable(Of Integer)
Dim samplesPerShift As Nullable(Of Integer)
Dim multiplier As Nullable(Of Integer)
Dim enabled As Nullable(Of Boolean)
Dim expiryTime As Nullable(Of Integer)
Dim expiryUnit As Nullable(Of Integer)
Dim warningTime As Nullable(Of Integer)
Dim warningUnit As Nullable(Of Integer)
Dim spare1 As String
Dim spare2 As String
Dim spare3 As String
Dim spare4 As String
Dim lastEditBy As String
Dim lastEditAt As Nullable(Of Date)
Dim value As DataSet
value = SampleFreq.GetAll(freqId, freqName, freqDesc, freqType, interval, intervalUnit, prodResetOption, startDelay, offsetStart, offsetStartUnit, offsetEnd, offsetEndUnit, samplesPerShift, multiplier, enabled, expiryTime, expiryUnit, warningTime, warningUnit, spare1, spare2, spare3, spare4, lastEditBy, lastEditAt)
public static DataSet GetAll(
Nullable<int> freqId,
string freqName,
string freqDesc,
Nullable<int> freqType,
Nullable<double> interval,
Nullable<int> intervalUnit,
Nullable<int> prodResetOption,
Nullable<int> startDelay,
Nullable<int> offsetStart,
Nullable<int> offsetStartUnit,
Nullable<int> offsetEnd,
Nullable<int> offsetEndUnit,
Nullable<int> samplesPerShift,
Nullable<int> multiplier,
Nullable<bool> enabled,
Nullable<int> expiryTime,
Nullable<int> expiryUnit,
Nullable<int> warningTime,
Nullable<int> warningUnit,
string spare1,
string spare2,
string spare3,
string spare4,
string lastEditBy,
Nullable<DateTime> lastEditAt
)
Parameters
- freqId
- Optional filter parameter. Holds an integer value to filter the dataset by sample frequency identifier.
- freqName
- Optional filter parameter. Holds a string value to filter the dataset by the name of sample plan frequency.
- freqDesc
- Optional filter parameter. Holds a string value to filter the dataset by the description of the sample plan frequency.
- freqType
Optional filter parameter. Holds an integer value to filter the dataset by the type of the sample plan frequency.
0 = shift
1 (default) = calendar time
2 = run time
3 = production
4 = main item produced changes (job_bom.current_subst for bom_pos = 0)
5 = item consumed at any BOM position changes
6 = the lot number of the main item produced changes (job_bom.def_lot_no for bom_pos = 0)
7 = the lot number of an item consumed at any BOM position changes
8 = the job changes
9 = utilization changes from runtime to downtime
10 = utilization changes from runtime to idle time
11 = utilization changes from downtime to runtime
12 = utilization changes from downtime to idle time
13 = utilization changes from idle time to runtime
14 = utilization changes from idle time to downtime
15 = inventory is received
16 = a new specification value is downloaded for the job running on a job position
17 = a step with action_type 6 starts
18 = a step with action_type 6 finishes
- interval
- Optional filter parameter. Holds a float value to filter the dataset by interval. If freq_type = 0, 1, or 2 (shift, calendar time, run time), the amount of time between samples (integers only). If freq_type = 3 (production), the amount of production between samples.
- intervalUnit
Optional filter parameter. Holds an enumeration that indicates the units for the amount of time or production between samples:
0 = seconds
1= minutes
2 = hours
3 = days
4 = weeks
5 = units of product
6 = number of lots
7 = number of jobs
8 = number of segment responses: 0 – 4 are used when freq_type = 0, 1, or 2 (shift, calendar time, run time); 5 – 8 when freq_type = 3 (production)
- prodResetOption
Optional filter parameter. Holds an enumeration that indicates what causes the count of production between samples to be reset. Used only if freq_type = 3 (production).
0 = nothing (no reset ever)
1 = job changes on job_exec (disallowed if interval_unit = 7)
2 = main item produced changes
3 = shift changes on entity
4 = entity utilization changes from runtime or downtime to idle time
- startDelay
- Optional filter parameter. Holds the amount of time, in seconds, to delay the generation of the first sample after a job has started on an entity. Used only if freqType = 1 (calendar time). This parameter is only applicable when the offsetStart parameter is not being used to specify a time-of-day trigger.
- offsetStart
- Optional filter parameter. Holds an integer value to filter the dataset by the offset from the start of the shift. Used only if freq_type = 0 (shift).
- offsetStartUnit
Optional filter parameter. Holds an enumeration that indicates the units for the offset value from the start of the shift:
1= minutes
2 = hours
3 = days
- offsetEnd
- Optional filter parameter. Holds an integer value to filter the dataset by the offset from the end of the shift. Used only if freq_type = 0 (shift).
- offsetEndUnit
Optional filter parameter. Holds an enumeration that indicates the units for the end of the shift:
1= minutes
2 = hours
3 = days
- samplesPerShift
- Optional filter parameter. Holds an integer value to filter the dataset by the number of times to ready an event between the offsets from the ends of a shift. Used only if freq_type = 0 (shift).
- multiplier
- Optional filter parameter. Holds an integer value to filter the dataset by the sample size multiplier. Minimum value = 1 (also the default).
- enabled
- Optional filter parameter. Holds a flag that indicates whether the sample frequency can be used at runtime.
- expiryTime
- Optional filter parameter. Holds an integer value to filter the dataset by the amount of time to wait for the sample to be pulled before changing its status to MISSING. The default is null (no expiration).
- expiryUnit
Optional filter parameter. Holds an enumeration that indicates the units for the expiryTime parameter:
1= minutes
2 = hours
3 = days
- warningTime
- Optional filter parameter. Holds an integer value to filter the dataset by the amount of time to wait for a sample to be pulled before changing its status to READY WARNING. The default is 5. Null = no warning.
- warningUnit
Optional filter parameter. Holds an enumeration that indicates the units for the warningTime parameter:
1= minutes (default)
2 = hours
3 = days
- spare1
- Optional filter parameter. Holds a string value to filter the dataset by a value defined by language term 5157.
- spare2
- Optional filter parameter. Holds a string value to filter the dataset by a value defined by language term 5158.
- spare3
- Optional filter parameter. Holds a string value to filter the dataset by a value defined by language term 5159.
- spare4
- Optional filter parameter. Holds a string value to filter the dataset by a value defined by language term 5160.
- lastEditBy
- Optional filter parameter. Holds a string value to filter the dataset by ID of the user who created or last modified this record.
- lastEditAt
- Optional filter parameter. Holds a datetime value to filter the dataset by the time that the row was last edited to retrieve information about.
Return Value
Returns a DataSet that contains all the records in the Sample_Freq table that satisfy the specified filters. If no matching records are found, an empty DataSet is returned.
The columns of the returned DataSet are described below.
| Column Name | Description |
|---|---|
| freq_id | An integer is the ID of the sample frequency. |
| freq_name | A string that identifies the name of the sample plan frequency. |
| freq_desc | A string that contains the description of the sample plan frequency |
| freq_type | An integer that is an enumeration that indicates the sample plan frequency type. |
| interval | A double that is the amount of time or production between samples. |
| interval_unit | An integer that is an enumeration that indicates the units for the amount of time or production between samples. |
| prod_reset_option | An integer that is an enumeration that indicates what causes the count of production between samples to be reset. |
| start_delay | An integer that is the amount of time, in seconds, to delay the generation of the first sample after a job has started on an entity. Used only if freq_type = 1 (calendar time). This parameter is only applicable when offset_start is not being used to specify a time-of-day trigger. |
| offset_start | An integer that is the offset value from the start of the shift. |
| offset_start_unit | An integer that is an enumeration that indicates the units of the offset value from the start of the shift. |
| offset_end | An integer that is the offset value from the end of the shift. |
| offset_end_unit | An integer that is an enumeration that indicates the units of the offset value from the end of the shift. |
| samples_per_shift | An integer that is the number of times to ready an event between the offsets from the ends of a shift. |
| multiplier | An integer that is the sample size multiplier. |
| enabled | A Boolean that is a flag that indicates whether the sample frequency can be used at runtime. |
| expiry_time | An integer that is the amount of time to wait for the sample to be pulled before changing its status to READY WARNING. |
| expiry_unit | An integer that is an enumeration that indicates the units of expiry_time. |
| warning_time | An integer that is the amount of time to wait for a sample to be pulled before changing its status to READY WARNING. |
| warning_unit | An integer that is an enumeration that indicates the units of warning_time. |
| spare1 | A string that is user-defined content for the spare1 field, defined by language term 5157. |
| spare2 | A string that is user-defined content for the spare2 field, defined by language term 5158. |
| spare3 | A string that is user-defined content for the spare3 field, defined by language term 5159. |
| spare4 | A string that is user-defined content for the spare4 field, defined by language term 5160. |
| last_edit_comment | A string that describes why the record was added or changed. |
| last_edit_by | A string that is the ID of the user who created or last modified this record. |
| last_edit_at | A datetime that indicates when the record was added or last modified. |