Hiding part of a Social Security Number

  • Follow


I have a database application that includes some privacy information for 
employees. Permissions to view and/or edit are handled in code. The last four 
digits of the Social Security number are used along with the first and last 
names to confirm a "match" for data coming in from other systems. On the main 
data input form for the employees, I want the Social Security number to 
appear like: 
*****1234        for all users who have permission to view the data, but 
567891234         for users who have permission to edit the data when they 
click on that field. Or, alternately, change to showing all digits as soon as 
they start to edit the record or begin a new record. Any ideas? This is in 
single form (not continuous). 
0
Reply Utf 12/18/2009 7:01:02 PM

What I would do is add a column in the underlying query that is the form's 
recordsource:

NoPerm: "*****" & Right([SSN], 4)

Then in your form's open event determine the user permissions and show or 
hide the appropriate textbox bound to that data. You want to Lock and/or 
Disable that textbox so no one can even try to edit it.

Now, for the lecture. Why are you storing personal information? Is this a 
payroll database? If not, you probably should not be storing it, since it is 
not likely that you can secure it enough to protect it. Do not store any 
personal information that is not absolutely required for your business 
process.
-- 
Arvin Meyer, MCP, MVP
http://www.datastrat.com
http://www.mvps.org/access
http://www.accessmvp.com


"Maredith" <Maredith@discussions.microsoft.com> wrote in message 
news:93D30033-2B9D-4D26-A8B5-1D58F3AFAFC1@microsoft.com...
>I have a database application that includes some privacy information for
> employees. Permissions to view and/or edit are handled in code. The last 
> four
> digits of the Social Security number are used along with the first and 
> last
> names to confirm a "match" for data coming in from other systems. On the 
> main
> data input form for the employees, I want the Social Security number to
> appear like:
> *****1234        for all users who have permission to view the data, but
> 567891234         for users who have permission to edit the data when they
> click on that field. Or, alternately, change to showing all digits as soon 
> as
> they start to edit the record or begin a new record. Any ideas? This is in
> single form (not continuous). 


0
Reply Arvin 12/18/2009 7:29:53 PM

1 Replies
675 Views

(page loaded in 0.038 seconds)


Reply: