Last post Apr 22, 2014 06:41 PM by Lannie
Apr 21, 2014 11:06 PM|ronnyrunatserver|LINK
I have a txt file containing multiple mobilenumbers eg:5 lakh..while uploading the file i am inserting the numbers in a data table(c#)
then looping each of them to send as parameter to the oracle procedure which returns me the status in YES and NO for each mobile number..which i update in other column corresponding to mobilenumber column in datatable(c#)...then i save this datable to sql
server using sqlbulkcopy
Problem is i want to optimize my code of hitting the stored procedure again and again for each number..which is very time consuming..
Any alternate way please tell
Thanks in advance
Apr 22, 2014 06:41 PM|Lannie|LINK
Store the numbers in a .NET dictionary class then export the entire dictionary in array to the database in one procedure call using associative array.
loading data into dictionary from a text file is fast.