Bishop's Pond

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Next revision
Previous revision
dbquery:test3 [2025/08/27 12:05] – created Richard Whitedbquery:test3 [2025/08/27 12:26] (current) – [Test3 status query] Richard White
Line 2: Line 2:
  
 <code sql> <code sql>
-SELECT common_name AS "Common name"scientific_name AS "Scientific name", date, location, note, id FROM species ORDER BY common_name;+SELECT  
 +    IIF (lower(common_name) LIKE '%frog%', 'frog', 'notfrog'AS status, 
 +    common_name AS result 
 +FROM species 
 +WHERE lower(common_name) LIKE '%frog%' 
 +LIMIT 1;
 </code> </code>
  
 +
 +===== These are the possible status codes =====
 +
 +==== frog ====
 +
 +<code html>
 +<div style="background-color: #D5E8D4">Frog: :result</div>
 +</code>
 +
 +
 +==== notfrog ====
 +
 +<code html>
 +<div style="background-color: #F8CECC">No frog found: :result</div>
 +</code>
dbquery/test3.1756296313.txt.gz · Last modified: by Richard White