如何取消连接 Taleo Connect 客户端中的相关实体?

How can I unconcatenate related entities in Taleo Connect Client?

我有一个针对 Taleo Connect Client 的导出查询,它检索特定 Candidate 实体(Recruiting 15A 模型)提交的每个 Application 的编号。根据候选人 ID 1234.

筛选候选人

当我 运行 我的查询时,结果文件在单个条目中列出了所有候选人的申请,但是我希望每个 Application 都列为自己的条目。

当前结果:

CandidateID,ApplicationID
1234,(Applications:1)=15160;(Applications:2)=18433;(Applications:3)=19347

预期结果:

CandidateID,ApplicationID
1234,15160
1234,18433
1234,19347

如何让我的导出查询列表为每个应用程序单独列出条目?


TCC 导出查询 (candidate_app_sq.xml):

<quer:query productCode="RC1501" model="http://www.taleo.com/ws/tee800/2009/01" projectedClass="Candidate" locale="en" mode="CSV-ENTITY" csvheader="true" largegraph="true" preventDuplicates="false" xmlns:quer="http://www.taleo.com/ws/integration/query">
  <quer:subQueries/>
  <quer:projections>
    <quer:projection alias="CandidateID">
      <quer:field path="Number"/>
    </quer:projection>
    <quer:projection alias="ApplicationID">
      <quer:field path="Applications,Number"/>
    </quer:projection>
  </quer:projections>
  <quer:projectionFilterings/>
  <quer:filterings>
    <quer:filtering>
      <quer:equal>
        <quer:field path="Number"/>
        <quer:string>1234</quer:string>
      </quer:equal>
    </quer:filtering>
  </quer:filterings>
  <quer:sortings/>
  <quer:sortingFilterings/>
  <quer:groupings/>
  <quer:joinings/>
</quer:query>

不是导出特定的候选人并提取每个应用程序,而是导出应用程序列表并根据候选人编号过滤结果。

为此,我更改了我的导出查询以使用 Application 实体作为 projectedClass 并相应地更新了我的投影路径。

导出查询:

<quer:query productCode="RC1501" model="http://www.taleo.com/ws/tee800/2009/01" projectedClass="Application" locale="en" mode="CSV-ENTITY" csvheader="true" largegraph="true" preventDuplicates="false" xmlns:quer="http://www.taleo.com/ws/integration/query">
  <quer:subQueries/>
  <quer:projections>
    <quer:projection alias="CandidateID">
      <quer:field path="Candidate,Number"/>
    </quer:projection>
    <quer:projection alias="ApplicationID">
      <quer:field path="Number"/>
    </quer:projection>
  </quer:projections>
  <quer:projectionFilterings/>
  <quer:filterings>
    <quer:filtering>
      <quer:equal>
        <quer:field path="Candidate,Number"/>
        <quer:string>1234</quer:string>
      </quer:equal>
    </quer:filtering>
  </quer:filterings>
  <quer:sortings/>
  <quer:sortingFilterings/>
  <quer:groupings/>
  <quer:joinings/>
</quer:query>

输出:

CandidateID,ApplicationID
1234,15160
1234,18433
1234,19347

注意:请记住在更改 projectedClass 时更新投影路径。

Old Path (Candidate)      New Path (Application)
"Number"               →  "Candidate,Number"
"FirstName"            →  "Candidate,FirstName"
"LastName"             →  "Candidate,LastName"
"Application,BillRate" →  "BillRate"
"Application,Grade"    →  "Grade"
"Application,Number"   →  "Number"

要为每个值导出单独的行,请将导出模式更改为 CSV-Report (CSV)。

<quer:query productCode="RC1501" model="http://www.taleo.com/ws/tee800/2009/01"
    projectedClass="Candidate" locale="en" mode="CSV" csvheader="true" largegraph="true"
    preventDuplicates="false" xmlns:quer="http://www.taleo.com/ws/integration/query">

说明

Taleo Connect Client User Guide第 41 页)列出了 CSV 文件的两种导出模式:CSV-Entity 和 CSV-Report。当导出模式设置为 CSV 实体时,每个根实体的数据合并为一行。

  • CSV-entity: Based on the T-XML export mode, it handles multiple values and multilingual fields. All data related to the root entity is located on the same line. When a column contains multiple values (multilingual or relations of maximum cardinality "N"), the values are serialized inside a single column. The prevent duplicates, grouping, and joining features are not supported by the CSV-entity export mode.
  • CSV-report: Uses a flat file format (that can be directly imported as an Excel spreadsheet) to represent the data. This mode exports exactly the same information as the XML mode, hence has the same strengths and weaknesses.

要为每条记录输出单独的行,导出模式应设置为 CSV 报告 (mode="CSV")。

例子

<quer:query productCode="RC1501" model="http://www.taleo.com/ws/tee800/2009/01" projectedClass="Candidate" locale="en" mode="CSV" csvheader="true" largegraph="true" preventDuplicates="false" xmlns:quer="http://www.taleo.com/ws/integration/query">
  <quer:subQueries/>
  <quer:projections>
    <quer:projection alias="CandidateID">
      <quer:field path="Number"/>
    </quer:projection>
    <quer:projection alias="ApplicationID">
      <quer:field path="Applications,Number"/>
    </quer:projection>
  </quer:projections>
  <quer:projectionFilterings/>
  <quer:filterings>
    <quer:filtering>
      <quer:equal>
        <quer:field path="Number"/>
        <quer:string>1234</quer:string>
      </quer:equal>
    </quer:filtering>
  </quer:filterings>
  <quer:sortings/>
  <quer:sortingFilterings/>
  <quer:groupings/>
  <quer:joinings/>
</quer:query>

结果:

CandidateID,ApplicationID
1234,15160
1234,18433
1234,19347