Oracle SQL - Add a column with data not included in any table
oracle, sql
Solution
You can add `virtual column` on your `SELECT` statement,
SELECT Trunc(Red.Fulfilled_Dtime),
P.Email,
(Red.Points_Deducted *.003)*(1/1.02) As Redeem_Amt,
Red.Player_Id,
Red.Prize_Id,
Red.Points_Deducted,
'USD' AS "Currency" -- <<== virtual column
FROM Redemption_Log Red
Inner Join Player P
On Red.Player_Id=P.Player_Id
WHERE Red.Prize_Id In (8907,8906,8905,8904,8903,8902,8901)
Problem
I have this query: ``` Select Trunc(Red.Fulfilled_Dtime), P.Email, (Red.Points_Deducted *.003)*(1/1.02) As Redeem_Amt, Red.Player_Id, Red.Prize_Id, Red.Points_Deducted From Redemption_Log Red Inner Join Player P On Red.Player_Id=P.Player_Id Where Red.Prize_Id In (8907,8906,8905,8904,8903,8902,8901) ``` I want to add a column to my result called "Currency" in which every row in my results has the output "USD". Is this possible?