java - Convert String containing letters to Int efficiently - Apache Spark -


i working dataset has users strings (ie. b000gkxy4s). convert each of these users int, can use rating(user: int, product: int, rating: double) class in apache spark als. efficient way this? preferably using spark scala functions or python native functions.

if want matchable string int - string.hashcode(). have deal possible hash collisions. alternatively you'd have convert each character int value , append (not add) of these together.


Comments

Popular posts from this blog

java - Oracle EBS .ClassNotFoundException: oracle.apps.fnd.formsClient.FormsLauncher.class ERROR -

c# - how to use buttonedit in devexpress gridcontrol -

nvd3.js - angularjs-nvd3-directives setting color in legend as well as in chart elements -