I've been handed a project at work and I don't know if this can be done using only sql - some tell me that you have to use an SQR to do this.
The project is an electronic file feed for one of our vendors. The problem is that the file layout has a header record, 3 detail records per employee and a trailor record. I can't get around the problem of each row having different data elements. The output would look something like this:
row1: RECORD_TYPE, PROCESS_DATE, CUST_NUM, CUST_NAME
row2: RECORD_TYPE, EMPLOYEE_ID, EMPLOYEE_NAME, COUNTRY_CODE
row3: RECORD_TYPE, EMPLOYEE_ID, PRODUCT, POLICY
row4: RECORD_TYPE, EMPLOYEE_ID, DEDUCTION_TYPE, DEDUCTION
row5: RECORD_TYPE, CUSTOMER_NUM, TOTAL_COVERAGE_RECORDS
Is this possible using only sql? I'm a novice, so if there is any simple examples that you can give would be greatly appreciated.
The project is an electronic file feed for one of our vendors. The problem is that the file layout has a header record, 3 detail records per employee and a trailor record. I can't get around the problem of each row having different data elements. The output would look something like this:
row1: RECORD_TYPE, PROCESS_DATE, CUST_NUM, CUST_NAME
row2: RECORD_TYPE, EMPLOYEE_ID, EMPLOYEE_NAME, COUNTRY_CODE
row3: RECORD_TYPE, EMPLOYEE_ID, PRODUCT, POLICY
row4: RECORD_TYPE, EMPLOYEE_ID, DEDUCTION_TYPE, DEDUCTION
row5: RECORD_TYPE, CUSTOMER_NUM, TOTAL_COVERAGE_RECORDS
Is this possible using only sql? I'm a novice, so if there is any simple examples that you can give would be greatly appreciated.