RE_SLSRPTLST_VW(SQL View) |
Index Back |
---|---|
View for List of Sales ReportsView for List of Sales Reports in a Billing Calendarr |
SELECT A.SLSRPT_ID , E.REVISION_NBR , D.BI_SCHED_ID , A.SLSRPT_STATUS , A.LS_KEY , C.LS_NBR , A.FISCAL_YEAR , A.ACCOUNTING_PERIOD , B.BEGIN_DT , B.END_DT FROM PS_RE_SLSRPT A , PS_CAL_DETP_TBL B , PS_RE_LS C , PS_RE_PCT_BI_SCHED D , PS_RE_SLSREV E WHERE A.LS_KEY = C.LS_KEY AND B.SETID = ( SELECT SETID FROM PS_SET_CNTRL_REC H WHERE H.SETCNTRLVALUE = C.BUSINESS_UNIT AND H.RECNAME = 'CAL_DETP_TBL') AND B.CALENDAR_ID = A.CALENDAR_ID AND A.LS_KEY = D.LS_KEY AND ((B.BEGIN_DT >= D.START_DT) OR (D.START_DT BETWEEN B.BEGIN_DT AND B.END_DT)) AND ((B.END_DT <= D.END_DT) OR (B.END_DT > C.LEASE_END_DT AND D.END_DT BETWEEN B.BEGIN_DT AND B.END_DT)) AND D.LS_PCT_SCHD_STATUS = '1' AND A.ACCOUNTING_PERIOD = B.ACCOUNTING_PERIOD AND A.FISCAL_YEAR = B.FISCAL_YEAR AND A.SLSRPT_ID = E.SLSRPT_ID AND E.REVISION_NBR = ( SELECT MAX(F.REVISION_NBR) FROM PS_RE_SLSREV F WHERE F.SLSRPT_ID = E.SLSRPT_ID) AND A.SLSRPT_STATUS = '1' |
# | PeopleSoft Field Name | PeopleSoft Field Type | Database Column Type | Description |
---|---|---|---|---|
1 | SLSRPT_ID | Number(15,0) | DECIMAL(15) NOT NULL | Sales Report ID - Number (15) |
2 | REVISION_NBR | Number(3,0) | SMALLINT NOT NULL | Sales Report Revision Number - Number (3) |
3 | BI_SCHED_ID | Number(30,0) | DECIMAL(30) NOT NULL | Bill Schedule ID |
4 | SLSRPT_STATUS | Character(1) | VARCHAR2(1) NOT NULL |
Sales Report Status - Character (1) - XLAT
1=Pending 2=Processed 3=Pending Approval |
5 | LS_KEY | Number(15,0) | DECIMAL(15) NOT NULL | Lease Key, Unique Key |
6 | LS_NBR | Character(10) | VARCHAR2(10) NOT NULL | Lease Number, User Enterable or Generated Sequence Number |
7 | FISCAL_YEAR | Number(4,0) | SMALLINT NOT NULL | Fiscal Year |
8 | ACCOUNTING_PERIOD | Number(3,0) | SMALLINT NOT NULL | Identifies a time period to which you post transactions. Typically, an accounting period represents a month, but it can also represent a week, a day, or any user-defined interval. An accounting period has a beginning date and an ending date, and is defined in the calendar table. |
9 | FROM_DATE | Date(10) | DATE | From Date |
10 | TO_DATE | Date(10) | DATE | To Date |