Tuesday 15 May 2012

sql - display the row with the first and last odd number -


Good day everyone

For example, my column name is tax < Code>, tax these values ​​are:

  tax ----- 3681 4292 4895 1894 1127   

Program 3681 and Number 1127 will be shown. Any feedback is very much appreciated. Bitdeath is using our MS SQL Server 2000 server.

By my understanding of your question, you enter the rows with the least or the highest number as the last character ? If yes, then it should work:

  Select TATx from your table (select the minimum (right (1, 1)), maximum (right, tax, 1). Tablet where tax% 2 = 1 - odd strange results) is correct on T2 (TTCX, 1) (T. 2.Myndode, T.Maxoddar)   
  • < / Li>

No comments:

Post a Comment