SQL Server Forums
Profile | Register | Active Topics | Members | Search | Forum FAQ
 
Register Now and get your question answered!
Username:
Password:
Save Password
Forgot your Password?

 All Forums
 General SQL Server Forums
 Database Design and Application Architecture
 How to generate new ID serie that remembers
 New Topic  Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic  

Danny Artavia
Starting Member

Costa Rica
2 Posts

Posted - 04/04/2013 :  13:02:48  Show Profile  Reply with Quote
Hello!!!

I need a database from an Insurance company, but they don't want to give it becuase it has a column with the ID number of each patient and their medical history.

They will give it to me only if I can find a 'script' that allows them to switch that ID number, but I need to 'remember' each ID across all the dase...

For example,

If I have (in a column) the ID 12345 and you 54321, y must generate a new number for each one. It can be 1 for me and 2 for you; but each time it reads 12345 it has to change to 1 exclusively.
In conlution, it has to identify each person with a new ID number.

Thanks !!!

Edited by - Danny Artavia on 04/04/2013 13:45:28

visakh16
Very Important crosS Applying yaK Herder

India
52309 Posts

Posted - 04/04/2013 :  14:27:12  Show Profile  Reply with Quote
sounds like what you need is a hashing algorithm for converting those id values

------------------------------------------------------------------------------------------------------
SQL Server MVP
http://visakhm.blogspot.com/
https://www.facebook.com/VmBlogs
Go to Top of Page

TG
Flowing Fount of Yak Knowledge

USA
6059 Posts

Posted - 04/04/2013 :  15:36:00  Show Profile  Reply with Quote
Not sure I'm following what your trying to achieve. Are you saying that they will give you all the insured people and all of their medical records as long as you can't tell which medical records are associated with which people?

could an alternative be to obfuscate the external identifiers of the people like name, SSN, etc.
Messing with primary key values may not be practical assuming the database has referential integrity set up.

Be One with the Optimizer
TG
Go to Top of Page
  Previous Topic Topic Next Topic  
 New Topic  Reply to Topic
 Printer Friendly
Jump To:
SQL Server Forums © 2000-2009 SQLTeam Publishing, LLC Go To Top Of Page
This page was generated in 0.39 seconds. Powered By: Snitz Forums 2000