cancel
Showing results for 
Search instead for 
Did you mean: 

Leavers visible in Org chart

Former Member
0 Kudos
127


Hi All,

I am starting a new thread for this.

Leavers are still visible in Nakisa org chart under ESS.

From our previous discussion, I found that logic to extract online active employee was missing in extraction. So I added table PA0000 in downloadschema.xml.

I have attached downloadschema.xml

While extracting. I am getting error

----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------



Processing Function Read Table Function/BAPI Downloading Tables Actions
No Tables were downloaded for Read Table Function/BAPI . Function is flagged as critical.Terminating Extraction.

--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

When I checked error log

error log says

----------------------------------------------------------------------------------------------------------------------------------------------------------------------

27/05/2014 17:41: INFO: SAP Extractor : Processing Function RfcReadTable(Read Table Function/BAPI).Downloading Tables Actions

27/05/2014 17:41: ERROR: RfcReadTable.ExtractSAPTable() : [SAPConnector.GetTable]: FIELD_NOT_VALID

27/05/2014 17:41: ERROR: SAPExtractorProcessor.processFunctionSchema : Source {System.Data}: Message {'table' argument cannot be null.

Parameter name: table}

27/05/2014 17:41: INFO: SAP Extractor : <img src="../Images/Error.gif"> No Tables were downloaded for RfcReadTable(Read Table Function/BAPI).

27/05/2014 17:41: INFO: SAP Extractor : <br></b>Processing Stopped ! ! ! </b>

27/05/2014 17:41: INFO: SAP Extractor : <img src="../Images/Performance_Outstanding.gif"> Downloading from SAP completed.

27/05/2014 17:41: INFO: SAPExtractorStartExtractionBtnClick.aspx : Joins are not executed. Check 'Execute Joins' prior to importing.

----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

This is only place where I am making changes.

Can you please suggest what is wrong with my code that I have written to add that logic.

Thanks

Abhi

Accepted Solutions (0)

Answers (3)

Answers (3)

Former Member
0 Kudos

Hi Stephens!!

Thanks so much for your reply.

I have tried both mentod. I have copied once Mr. Burr's code, but somehow, unfortunately did not work, as ACTIVEPERSON table was not created in backend.

Secondly, Mr. Millard suggestion, worked without any error.

But issue still exists.

After extraction, I then publish the build. Then I went to Org chart and employee lsiting. When I search by Last name, I could see the leavers coming in dropdown. However when I click on that leaver nothing will come up (This is usual behaviour which was happening earlier also, just for your info.).

Are these leavers are still there in data base or do we need to modify any Join statement?

I am attaching both xmls as suggested by both of you.


Please suggest

Thanks

Abhi

StephenBurr
Active Contributor
0 Kudos

Stick with Stephen M's suggestion as that was the cause of your issue. Good spot from Stephen!

Now you have active employee data extracted into table EmpActions.

You need to amend the joinconfiguration section to ensure each employee is checked (via PERNR) that it exists in EmpActions (since you only extracted STAT2 = '3').

From a brief look, I think most of the joins for employees start from EmpOrgAssgn (PA0001 data) and hence if you include an additional join/check on your EmpActions table you should be able to only include active employees.

Stephen

Former Member
0 Kudos


Thanks alot stephen!!

I have removed these fields also Action type and reson for action.

Now extraction was completed but with zero rows affected. I have also experimented wth ecoding by giving blank once and using ASCII once.

backend error is:

28/05/2014 12:59: INFO: SAP Extractor : Processing Function RfcReadTable(Read Table Function/BAPI).Downloading Tables Actions

28/05/2014 12:59: INFO: SAP Extractor : Processing Function  RfcReadTable(Read Table Function/BAPI).  Completed

28/05/2014 12:59: INFO: SAP Extractor : Saving Table  EmpActions...

28/05/2014 12:59: ERROR: CommandProcessor.executeCommandsAsTrans : CREATE TABLE EmpActions(Pernr VARCHAR(8),StartDate VARCHAR(8),EndDate VARCHAR(8),Employment Status VARCHAR(1)) : Source {IBM.Data.DB2}: Message {ERROR [42601] [IBM][DB2/NT] SQL0104N  An unexpected token "VARCHAR" was found following "8),Employment Status".  Expected tokens may include:  "DEFAULT".  SQLSTATE=42601

}

By looking error I am still now able to figure out what issue is? can you please help.

Thanks

Abhi

StephenBurr
Active Contributor
0 Kudos

I can't. Can you re-attach the latest downloadschema.xml?

Try this, which will return only active PERNR into a table called ACTIVEPERSON:


<function name="RfcReadTable" critical="true" encoding="UTF8">

  <download>true</download>

  <desc>Active Employee</desc>

  <dll>Nakisa.SAP.SAPeProcessor</dll>

  <class>Nakisa.SAP.SAPeProcessor.RfcReadTable</class>

  <params>

  <param name="FIELDLIST"><![CDATA[PERNR]]></param>

  <param name="CONDITION"><![CDATA[BEGDA <= '[DateToday]' And ENDDA >= '[DateToday]' And STAT2 = '3']]></param>

  <param name="SOURCETABLE"><![CDATA[PA0000]]></param>

  </params>

  <outputTables>

  <outputTable name="ACTIVEPERSON" download="false" critical="true" encoding="">

  <source>PA0000</source>

  <desc>Active Person</desc>

  <fields>

  <field name="PERNR" source="" mandatory="false" type="" encoding="ASCII">

  <alias>PERNR</alias>

  <desc><![CDATA[]]></desc>

  </field>

  </fields>

  <condition><![CDATA[]]></condition>

  </outputTable>

  </outputTables>

</function>

Stephen

StephenMillard
Active Contributor
0 Kudos

Abhi.

Looking at the error I think your SQL looks like this:


CREATE TABLE EmpActions

(

  Pernr VARCHAR(8),

  StartDate VARCHAR(8),

  EndDate VARCHAR(8),

  Employment Status VARCHAR(1)

)

Note in line 6 your column name is actually two separate words - "Employment" and "Status"  I'm guessing this is probably the source of your issue.

Try changing it to "Employment_Status" or "EmploymentStatus" and see if you still get the error.

Regards,

Stephen.

StephenBurr
Active Contributor
0 Kudos

PLANS,WERKS,PERSG,PERSK aren't valid fields for PA0000. You need to remove from your FIELDLIST param element and the subsequent list of <fields>.



Stephen