Skip to content
Sunday, April 18, 2021

IT Talkers

Technology HUB

  • ETL
    • Pentaho
    • Tableau
  • SCRIPTING
    • Shell Script
  • AWS
    • ATHENA
    • S3
    • SQL_SERVER
  • Git GUI
  • C++
    • C++11
    • C++98
  • DATABASE
    • HIVE
    • ORACLE
    • SQL_SERVER
  • BIG DATA
    • HDFS
  • SAS
  • Data Structure
    • Stack
  • Networking

Tag: mask mobile number using hive

Masking the mobile number in hive

admin

Today, I will discuss about the masking the details of the customer. It may be mobile number, Bank Account Number,Security PIN,customer_ID etc.For this, we can use combination of substring and regexp_replace function in hive.For example, you want to mask the first 5 digit of a mobile number like 1234567890 as #####67890, then use the below query. select concat(regexp_replace(substring(‘1234567890′,1,5),'[0-9]’,’#’),substring(‘1234567890’,6,5)); You can use mask_show_last_n function but here concern is, it will replace number by “n”. See the below Query : select mask_show_last_n(‘1234567890’,5) ; Result is nnnnn67890

DATABASE, HIVEmask bank account number using query, mask mobile number using database query, mask mobile number using hive, mask part of string using database query

Recent Posts

  • DHCP
  • Conversions
  • IPv4 Address
  • Call Pentaho Job using Batch Script
  • Queue using stack
  • nullptr
  • auto keyword
  • GET HIERARCHICAL VALUES PRESENT IN SAME COLUMN OF A TABLE
  • Stack Using Linked List
  • Stack using fixed size array

Categories

all about technology

Proudly powered by WordPress | Theme: AcmeBlog by AcmeThemes.