Jump to content
php.lv forumi

order by nepareiza secība


Jackal

Recommended Posts

mysql datubāzes tabulā ir kolonna num, kur katram ierakstam glabājas vērtība - 3.1., 3.2., utt. Šī kolonna norāda secību, kadā dati tiks izvadīti.

Problēma sākas, kad šī vērtība ir lielāka par 3.9.

 

Izmantojot order by num ASC dati izvadās šādā secībā:

 

3.1.

3.10.

3.11.

3.2.

3.3.

 

bet vajadzētu būt šādi:

 

3.1.

3.2.

3.3.

3.10.

3.11.

 

Ir kāds veids kā šo problēmu novērst?

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...