Hi! I think you've found the wrong mailing list for this post. This mailing list is for the development of Django itself, not for support using Django. This means the discussions of bugs and features in Django itself, rather than in your code using it. People on this list are unlikely to answer your support query with their limited time and energy. Read more on the mailing lists at https://www.djangoproject.com/community/
For support, please use the django-users mailing list, or IRC #django on Freenode, or a site like Stack Overflow. There are people out there willing to help on those channels, but they might not respond if you don't ask your question well. Stack Overflow's question guide can help you frame it well: https://stackoverflow.com/help/how-to-ask . Also if you haven't read it, please take a look at Django's Code of Conduct: https://www.djangoproject.com/conduct/ . These are our "ground rules" for working well as a community, and will help you get the most out of Django and our fantastic community. On your question - I think you want the SQL CASE and WHEN which are mapped in the Django ORM as the Case and When functions: https://docs.djangoproject.com/en/2.2/ref/models/conditional-expressions/ Thanks for your understanding, Adam On Wed, 14 Aug 2019 at 03:22, 'Fadi Haddad' via Django developers (Contributions to Django itself) <email@example.com> wrote: > Hi, > > I have created a table called dataset > > I put the age as integer e.g. 34, 23, 10, 47 > > I need to create Age range for the age column. I need the age to be > displayed as [1-10], [11,20], [21-30] ... etc. Can this happen by replacing > values or do I have to create another column for this? The goal is to > anonymize my dataset therefore if it is possible to replace values (age) > rather than creating new column would be excellent. > > Can anyone help me how to code this in SQL? Would be appreciated if code > is included in the response > > Regards > > Fadi > > -- > You received this message because you are subscribed to the Google Groups > "Django developers (Contributions to Django itself)" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to django-developers+unsubscr...@googlegroups.com. > To view this discussion on the web visit > https://groups.google.com/d/msgid/django-developers/79b8a25a-ce6b-4a73-9be2-d67c7d78e2ff%40googlegroups.com > <https://groups.google.com/d/msgid/django-developers/79b8a25a-ce6b-4a73-9be2-d67c7d78e2ff%40googlegroups.com?utm_medium=email&utm_source=footer> > . > -- Adam -- You received this message because you are subscribed to the Google Groups "Django developers (Contributions to Django itself)" group. To unsubscribe from this group and stop receiving emails from it, send an email to django-developers+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/django-developers/CAMyDDM10uV0Lfx2rAzFN3K95F-KwUC3TC5dsQvcehNpTtXYTwA%40mail.gmail.com.