简体   繁体   中英

How to alias the ClassDescription property in a FileNet P8 saved search?

Given this SQL statement written in ACCE:

SELECT 
 This, 
 D.ClassDescription,
 D.Id myId,
 D.MimeType myMimeType
FROM 
 Document D 
WHERE 
 D.Id= '{00093471-0100-C09E-828F-6B22177A2922}'

How do I properly alias the ClassDescription field?, it does not work like the other columns (properties).

I've tried using 'AS' and Brackets '[]' but no such luck, the column is silently removed from the results of the query.

Thank you, Stephen

The aliasing of columns is straight-forward, you can use the following:

foo AS bar
foo [bar]
foo bar

As a side note to anyone who may peruse this question and answer, the installation of the ACCE instance I was using was somewhat problematic (or a bug), it would NOT allow me to alias the ClassDescription Property. If I programmatically create the same query using the SearchSQL API, the aliasing works as expected as long as it conforms to SQL-92 dialect.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM