R/F4111.R

Defines functions F4111

Documented in F4111

#' Item Ledger File
#' 
#' F4111 - Item Ledger File 
#' 
#' @param db2_connection JDE Database Connection
#' @param friendly_names Flag to return human-readable column names.  Default TRUE.
#' @export
F4111 <- function(db2_connection, friendly_names = TRUE) {
    F4111 <- dplyr::tbl(db2_connection, dbplyr::in_schema('PRODDTA', 'F4111'))
        if (friendly_names) {
            F4111 <- F4111 %>% dplyr::select(
                `Number of Lines` = `ILNLIN`,
                `Item Number - Short` = `ILITM`,
                `2nd Item Number` = `ILLITM`,
                `3rd Item Number` = `ILAITM`,
                `Business Unit` = `ILMCU`,
                `Location` = `ILLOCN`,
                `Lot/Serial Number` = `ILLOTN`,
                `Parent Lot` = `ILPLOT`,
                `Storage Unit Number` = `ILSTUN`,
                `Sequence Number - Location Detail` = `ILLDSQ`,
                `Transaction Line Number` = `ILTRNO`,
                `From/To` = `ILFRTO`,
                `Lot Master Cardex (Y/N)` = `ILLMCX`,
                `Lot Status Code` = `ILLOTS`,
                `Lot Potency` = `ILLOTP`,
                `Lot Grade` = `ILLOTG`,
                `Parent (short) Item Number` = `ILKIT`,
                `Branch` = `ILMMCU`,
                `Agreement Number - Distribution` = `ILDMCT`,
                `Agreement Supplement - Distribution` = `ILDMCS`,
                `Document Company` = `ILKCO`,
                `Document (Voucher Invoice etc.)` = `ILDOC`,
                `Document Type` = `ILDCT`,
                `Document Pay Item` = `ILSFX`,
                `Journal Entry Line Number` = `ILJELN`,
                `Batch Number` = `ILICU`,
                `Date - For G/L (and Voucher)` = `ILDGL`,
                `Category - G/L` = `ILGLPT`,
                `Order Type` = `ILDCTO`,
                `Document (Order No Invoice etc.)` = `ILDOCO`,
                `Order Company (Order Number)` = `ILKCOO`,
                `Line Number` = `ILLNID`,
                `As Of Posted Code` = `ILIPCD`,
                `Date - Order/Transaction` = `ILTRDJ`,
                `Unit of Measure - Transaction` = `ILTRUM`,
                `Address Number` = `ILAN8`,
                `Explanation - Transaction` = `ILTREX`,
                `Transaction Reference` = `ILTREF`,
                `Reason Code` = `ILRCD`,
                `Quantity Available` = `ILTRQT`,
                `Amount - Unit Cost` = `ILUNCS`,
                `Amount - Extended Cost/Price` = `ILPAID`,
                `terminal identification` = `ILTERM`,
                `Unique Key ID (Internal)` = `ILUKID`,
                `Time of Day` = `ILTDAY`,
                `User ID` = `ILUSER`,
                `Program ID` = `ILPID`,
                `Date - Created (Julian)` = `ILCRDJ`,
                `Account ID` = `ILAID`,
                `Serial Number` = `ILASID`,
                `Business Unit - Alt` = `ILMCUZ`,
                `Object Account` = `ILOBJ`,
                `Subledger - G/L` = `ILSBL`,
                `Subsidiary` = `ILSUB`,
                `Unit of Measure - Secondary` = `ILUOM2`,
                `Commingled Other Owner` = `ILCMOO`,
                `Reverse or Void (R/V)` = `ILRE`,
                `Subledger Type` = `ILSBLT`,
                `Units - Secondary Quantity Ordered` = `ILSQOR`,
                `Valuation Period Ending Date` = `ILVPEJ`,
                `Historical Date - Julian` = `ILHDGJ`,
                `Address Number - Ship To` = `ILSHAN`,
                `Sequence Number - Operations` = `ILOPSQ`,
                `Related From Line Number` = `ILRFLN`,
                `Transaction Group Number` = `ILTGN`,
                `Lot Status Code Expanded` = `ILLOTC`,
                `Reconciliation Date` = `ILSVDT`,
                `Lot Status Reason Code` = `ILLRCD`,
                `Supplier Lot Number` = `ILRLOT`,
                `License Plate Number` = `ILLPNU`,
                `Production Number` = `ILPMPN`,
                `Production Number Short` = `ILPNS`
            )
        }
    return(F4111)
}
ejneer/camdata documentation built on May 5, 2020, 12:08 a.m.