Click here to Skip to main content
12,952,215 members (62,435 online)
Rate this:
 
Please Sign up or sign in to vote.
See more:
Hello Viewers ..I am developing C# based windows application and these Application Front end is MS Access...In this Application I want insert multiple records using one query...my query is ..

Insert into ReciverAddress(ReciverAddressId,ReciverName,ReciverCompany,ReciverAddress,ReciverState,ReciverCity,ReciveCountryCode,ReciverPostalCode,ReciverContact) values(1,'RAMU GUPTA','EVENZ INDIA','NEW DELHI,DWARKA MOR','Delhi','DWARKA',110078,118877,98768423764)
Insert into ReciverAddress(ReciverAddressId,ReciverName,ReciverCompany,ReciverAddress,ReciverState,ReciverCity,ReciveCountryCode,ReciverPostalCode,ReciverContact) values(2,'ROHAN GUPTA','KMK NETWORK','SURAJ MAL VIHAR','Delhi','NEW DELHI',612361,932749,98634872364)
Insert into ReciverAddress(ReciverAddressId,ReciverName,ReciverCompany,ReciverAddress,ReciverState,ReciverCity,ReciveCountryCode,ReciverPostalCode,ReciverContact) values(3,'RAJESH SHARGOHI','SSS','GHANDHI NAGAR,NEW DELHI','Delhi','LAXMI NAGAR',11006,110096,9716346947)
Insert into ReciverAddress(ReciverAddressId,ReciverName,ReciverCompany,ReciverAddress,ReciverState,ReciverCity,ReciveCountryCode,ReciverPostalCode,ReciverContact) values(4,'PALLAVI AGARWAL','KS Infotech','Uttar pardesh','Uttar Pradesh','MATHURA',110055,999871,98991273982)

but this query is not executed and Given same exception..Exception is
Missing semicolon (;) at end of SQL statement...so given same idea or your views to correct this Exception...Thank you..
Posted 14-Jan-13 20:42pm
Comments
Zoltán Zörgő 15-Jan-13 2:45am
   
1) Why?
2) what has this to do with c#?
David_Wimbley 15-Jan-13 10:39am
   
I dont understand, if your exception is missing semi colon and your wanting to do multiple inserts using that sql...why not just add the semi colon and problem solved? Am i missing something?

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

    Print Answers RSS
Top Experts
Last 24hrsThis month
OriginalGriff 6,239
CHill60 3,490
Maciej Los 3,083
Jochen Arndt 1,975
ppolymorphe 1,880


Advertise | Privacy | Mobile
Web01 | 2.8.170525.1 | Last Updated 15 Jan 2013
Copyright © CodeProject, 1999-2017
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100