title: What is the use of oracle first_Value analytical function?
body: <p>I have a query which has first_value() as a analytic function.</p>
  
  <pre><code>SELECT 
      product_id, 
      product_name,
      list_price, 
      FIRST_VALUE(product_name) 
       OVER (ORDER BY list_price) first_product,
       category_id
  FROM 
      ot.products
  WHERE 
      category_id = 1;
  </code></pre>
  
  <p>The output I got was:
  <a href="https://i.stack.imgur.com/qIxUN.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/qIxUN.png" alt="enter image description here"></a></p>
  
  <p>Here I got 70 rows.</p>
  
  <p>So,I tried new query as:</p>
  
  <pre><code>SELECT product_id, 
         product_name, 
         list_price 
  FROM   ot.products 
  WHERE  category_id = 1 
  ORDER  BY list_price; 
  </code></pre>
  
  <p>The output I got is:</p>
  
  <p><a href="https://i.stack.imgur.com/8kR7K.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/8kR7K.png" alt="enter image description here"></a></p>
  
  <p>In this query I again got 70 rows.So,I am not understanding what is the use of fisrt_value() in the first query?Since the data I am getting is same what is the use of this analytical function?</p>