Help _ How To wrap _ AX

Source: Internet
Author: User
String str = String. format (@ "insert into AD_TRAINTESTA VALUES ('{0}', '{1}', '{2}', '{3}', '{4 }', '{5}', '{6}', '{7}', '{8}', '{9}', '{10 }', '{11}', '{12}', '{13}', '{14}', '{15 }',
'{16}', '{17}', '{18}', '{19}', '{20}', '{21 }', '{22}', '{23}', '{24}', '{25}', '{26}', '{27 }', '{28}', '{29}', '{30 }')"
, R [0], r [1], r [2], r [3], r [4], r [5], r [6], r [7], r [8], r [9], r [10], r [11], r [12], r [13], r [14], r [15], r [16], r [17], r [18], r [19], r [20], r [21], r [22], r [23], r [24], r [25], r [26], r [27], r [28], r [29], r [30]);

The equals sign is followed by a line in the Code and can be run,
So how to wrap it? This line is too long... (I don't discuss whether the database design is reasonable. Of course it's unreasonable. So I have changed the database, but this problem has never been solved)

Practice is the only criterion for testing truth:
String s = String. Format (@ "safjdlksajkf
Djksaf {0} asdfasfdsa {1} asdfsadf {2} "," 2 ",
"2"
, "2 ");
// [Result]
// S = "safjdlksajkf \ r \ ndjksaf2asdfasfdsa2asdfsadf2"

[Summary]
① The first line of the string cannot be a line break. Otherwise, a line break symbol [\ r \ n] will appear in the result. You must remove it through processing to get the desired result ,,,
② Variables can be wrapped in line, and !!

[The problem has been solved. Please do not reply]

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.