Access Function to add numbers 1,2,3...n to field values that are duplicates
$10-30 USD
Paid on delivery
I need a simple VBA function for MS Access (2010) that I can use in an update query to
1) checks the strings in a given field for duplicates
2) then, for strings that have duplicates, add digits to its end.
Example of the input and the expected output:
K17B8897 --> K17B8897-0
K17B8897 --> K17B8897-1
H19R1234 --> H19R1234-0
H19R1234 --> H19R1234-1
H19R1235 --> H18R1235
P22K4456 --> H22K4456
K17B8897 --> K17B8897-2 (mind the hyphen!)
K17B8897 --> K17B8897-3 (mind the hyphen!)
The output strings should be put into a new field, which the function should create itself, ideally to the right of the source field.
The function will have three parameters:
CheckDuplicates(WhichFieldToCheck, NameOfFieldToCreateForOutput; StartWithNumber)
The parameters are
- WhichFieldToCheck: Name of the field to check
- NameOfFieldtoCreateForOutput: Possibility to set a name for the new column that will be created; if not name is given, "Modified" is used.
- StartWithNumber: Set a number to start with, e.g. 1000 --> 1000, 1001, 1002...; if not set, counting starts with 0.
For delivery, it is sufficient to send me the VBA code; I will myself create a module to store it where I need it.
Project ID: #5325031
About the project
Awarded to:
I have been developing applications in both Access and Excel for 20 years with extensive use of VBA. I have developed several applications for Freelance clients, please see Feedback. I am UK based, a native English More
9 freelancers are bidding on average $31 for this job
Hi Chgeiselmann. Your requirement requires a recursive query function that would make a lot of queries and would slow down the system. What if I write you a VBA function in Excel that would do the following with the sa More
Dear Sir, I'm Expert with access, talent with VBA, and i'm interested in doing your project. I have a part of that function just few modification and it will be ready. Kind Regards, NourElDeen
Dear sir, I've read you requirement carefully. With expertise in VBA and much experience working with Acess-SQL, I could be a good fit. Kind regards, LY
Hello There, I am excited to do this. I can complete this by today. Why you should choose me? 1.) I am proficient in VB, VBA. I can show you projects I have made if you want. 2.) I give timely updates on the More
I am a professional software engineer with 9+ years of experience. I am very talented programmer with the following skills c, c++ , java ,VB, UNIX, Linux,SSH, PHP, Jsp , Js , advanced js like jquery, extjs etc. My ski More