title: Scrapy: extracting data from an html tag that uses an "id" Selector instead of a "class"
body: <p>I am new to web scraping and Scrapy. I hope you can help me. </p>
  
  <p>I am trying to extract data from a web page where it uses  tag. Usually, if the span tag is using a class, for example:</p>
  
  <pre><code>&lt;span class="class_A&gt;Hello, World!&lt;/span&gt;
  </code></pre>
  
  <p>I would use the following code to retrieve the text.</p>
  
  <pre><code>request.css('span.class_A::text').extract()
  </code></pre>
  
  <p>However, when an html is now using an "id" instead of a "class", for example,</p>
  
  <pre><code>&lt;span id="id_A&gt;Hello, Universe!&lt;/span&gt;
  </code></pre>
  
  <p>the code below does not work anymore.</p>
  
  <pre><code>request.css('span.id_A::text').extract()
  </code></pre>
  
  <p>Please help! What's the correct way of extracting data using an "id".</p>
  
  <p>Thank you for your help!</p>