ORA-904: "DDOCLASTMODIFIEDDATE": Invalid Identifier When Calling GET_SEARCH_RESULTS (Doc ID 1366388.1)

Last updated on MARCH 08, 2017

Applies to:

Oracle Universal Content Management - Version: 11.1.1.5.0 and later   [Release: 11g and later ]
Information in this document applies to any platform.

Symptoms

Using Content Server 11.1.1.5 on Linux

Content Server connects to an Oracle 10.2 database with Search Engine set to DATABASE.METADATA

When performing a call to the GET_SEARCH_RESULTS and sorting the result set on the last modified date, following error gets raised:

Error Unable to retrieve search results. Error occurred while processing. Unable to return results. Unable to create the result set for query
'SELECT *
FROM (SELECT dStatus, dDocName, dDocTitle, Revisions.dDocType, doc_types.dDescription, dRevisionID, dSecurityGroup, dDocAuthor, dDocAccount, dRevLabel, dFormat, dOriginalName, LOWER(dExtension) AS dExtension, dWebExtension, dInDate, dOutDate, dPublishType, dRendition1, dRendition2, dFileSize AS VaultFileSize, DENSE_RANK() OVER (PARTITION BY Revisions.dDocName ORDER BY Revisions.dID desc) last_rev_topN, DocMeta.*
FROM Revisions, DocMeta, Documents, (select dDocType as ddoctype_name, dDescription from DocTypes) doc_types
WHERE Revisions.dID=DocMeta.dID
AND Revisions.dID=Documents.dID
AND doc_types.ddoctype_name = Revisions.dDocType
AND dReleaseState IN ('N', 'R', 'Y', 'U', 'I', 'E')
AND ((( xTestfield LIKE '219' )))
AND dIsPrimary = 1
) a
WHERE a.last_rev_topN=1
ORDER BY dDocLastModifiedDate Desc'. ORA-00904: "DDOCLASTMODIFIEDDATE": invalid identifier
java.sql.SQLSyntaxErrorException: ORA-00904: "DDOCLASTMODIFIEDDATE": invalid identifier.

GET_SEARCH_RESULTS is called with following parameters:

IdcService=GET_SEARCH_RESULTS
&ftx=
&QueryText=xTestfield <matches> `219`
&SortField=dDocLastModifiedDate
&SortOrder=Desc
&ResultCount=20
&FromPageUrl=
&SearchQueryFormat=UNIVERSAL
&IsSavedQuery=1

Cause

Sign In with your My Oracle Support account

Don't have a My Oracle Support account? Click to get started

My Oracle Support provides customers with access to over a
Million Knowledge Articles and hundreds of Community platforms