Qt Forum

    • Login
    • Search
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Search
    • Unsolved

    Update: Forum Guidelines & Code of Conduct

    [SOLVED] Problem with QString

    General and Desktop
    2
    4
    929
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • R
      Romaniy last edited by

      Hello, everyone.
      I need help with QString variable. I want to create a sql query which contains near 1450 symbols.
      Firstly, I create QString variable. When I'm checking size of my variable I see 1450 symbols. But when I'm trying to execute my QSqlQuery I catch an error. From the qDebug() I see first 1024 symbols normally and next only unreadable symbols. In the same time count show 1450 symbols. Please help my to understand what is wrong.
      Thank in advance

      1 Reply Last reply Reply Quote 0
      • rootshell
        rootshell last edited by

        Any chance you have escape charactors in it such as \ " ' etc etc

        Certifications: CISSP, MCITP, MCSE, MCSA, BA, AA, AG, CST, CNST, Linux+, Security+, Server+, Network+, A+, iNet+

        Languages: C++, C#, VB, Python, Java

        1 Reply Last reply Reply Quote 0
        • R
          Romaniy last edited by

          Thanks for your reply!

          But I can't find any mistake in my string.
          Bye the way, I tried to execute the next code:
          @ QString ar;
          for (int i=0; i < 1020; ++i)
          {
          ar += 'a';
          }
          qDebug() << ar;@

          and have in the end of my output something like that
          ......aaaaaaaaaaaaaaaaaaaa"
          ˜Î4O"š

          Thanks

          1 Reply Last reply Reply Quote 0
          • R
            Romaniy last edited by

            It was stupid question)

            Sorry for disturb

            1 Reply Last reply Reply Quote 0
            • First post
              Last post