Skip to Content
0
Dec 05, 2012 at 11:02 PM

Use of Alias in Query Generator

254 Views

Have 2 questions for Query Generator Syntax:

In query generator, created a query similar to the simplified one below:

SELECT T0.[FirstName]+' '+T0.[LastName] "ABCXYZ"

FROM OCPR

WHERE T0.[FirstName]+T0.[LastName] LIKE '%[%1]%'

Q1) How can I use the alias "ABCXYZ" in the WHERE statement instead of the concatenation?

Q2) On executing this statement, a pop-up of Query - Selection Criteria window appears with text "First Name contains". How can I make it appear as either "ABCXYZ contains" or something similar instead of just First Name since it is really searching the full concatenation for the text and not simply the first name?

Thanks,

Ajay