C# Tutorials and offshore development in India
    Tutorials   Resources   Forum   Communities   Interview   Jobs   Projects   Offshore Development    
Silverlight Tutorials | Mentor | Code Converter | Articles | Code Factory | Computer Jokes | Members | Peer Appraisal | IT Companies | Bookmarks | Revenue Sharing |


Prizes & Awards
My Profile



Active Members
TodayLast 7 Days more...

New Feature: Community Sites: Create your own .NET community website and start earning from Google AdSense ! It's Free !




How to use too lengthy connection string?


Posted Date: 21 Jun 2007      Total Responses: 2

Posted By: sankar       Member Level: Silver     Points: 2


I am using too lengthy connection string, when brek the connection string it show error : "Newline In constant "
qs = "INSERT INTO EMPLOYEE (Name_1,Org_2,Nat_Bus3,Year_4,Plevel_5,Gross_7,B_8,A_8,B_9,A_9,B_10 ,A_10 ,B_11 ,A_11

,B_12 ,A_12 ,B_13 ,A_13 VALUES (‘ “+TB2_NAO.SelectedValue+” ‘ ,‘

“+DDQ3NoB.SelectedValue+” ‘ ,‘ “+DDQ4HMY.SelectedValue+” ‘ ,

‘ “+DDQ5POL.SelectedValue+” ‘ ,‘ “+DDQ6REM.SelectedValue+” ‘ , ‘
“+DDQ7AGS.SelectedValue+” ‘ );
How to break it?




Responses

Author: Vasudevan Deepak Kumar    21 Jun 2007Member Level: DiamondRating:     Points: 2
You can use your Visual Studio's Word Wrap option to see soft break instead.

Also, you can build the string using StringBuilder instead of costly string concatenation.

Also, you are meaning a 'query' and not a 'connection string'. Both are different.


Author: Rajaraman    21 Jun 2007Member Level: DiamondRating:     Points: 2
Yeah. vasudevan is pointed out correcly..



Post Reply
You must Sign In to post a response.
Next : export data from excelworkbook
Previous : generate a random value from a database column
Return to Discussion Forum
Post New Message
Category: ASP.NET

Related Messages



dotNet Slackers   BizTalk Adaptors    Web Design

it help desk

Contact Us    Privacy Policy    Terms Of Use