Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

It’s probably fine, but this sort of thing is why transactionAmount and transactionCurrency are better when separated. Consider the case when you’re doing some reporting from your DB based on currency; do you really want to have to deal with one string that contains both or just do a simple WHERE clause?


In our case those are indeed separate in the database, so that we can type the value as a numeric, which is very necessary for many operations. Those fields only get combined in the serialization.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: