Specifying Query Columns
Following is the columns portion of the SELECT clause syntax:
<column> [ {, <column>} … ]
Separate multiple column specifiers by using commas.
Column names can be either regular or delimited identifiers. In Microsoft SharePoint Portal Server Search (SharePointPSSearch), most of the properties derived from the document are specified using namespace-qualified Uniform Resource Names (URNs). Examples are "DAV:href" and "urn:schemas-microsoft-com:office:office#Author". URNs must be specified as delimited identifiers, enclosed in double quotation marks.
When the query returns a document that does not have the requested column, the value of that column for the document is NULL.
In the SQL query, you are allowed to use the asterisk (*) to specify that all columns in a table are to be returned. However, no defined and fixed set of properties applies to all documents. For this reason, the SQL asterisk is not permitted in the <columns> setting.
Casting Column Data Types
SharePointPSSearch does not support casting the column data type as it is returned in the query.
Column Aliasing
SharePointPSSearch does not support column aliasing. It also does not support limiting the column length, but returns the full length of each text property.
Examples
This example returns the size of the document, and a Hypertext Transfer Protocol (HTTP) link pointing to the matching documents. The URN column name "DAV:href" contains a colon, and therefore must be enclosed in double quotation marks.
SELECT size, "DAV:href" FROM Portal_Content..Scope() WHERE...