Announcement

Collapse
No announcement yet.

Form issue with field type nvarchar

Collapse
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • Form issue with field type nvarchar

    Hi,

    We are converting our SC7 applicatio to SC8.

    We have an MSSQL database.
    We had fields with ntext type.
    But as it is on MSSQL 2008R2 DB, and we cannot convert to never version, we converted the fields from ntext to nvarchar(4000). This in order to avoid problems on SC8.

    Now, on our Scriptcase 8 form, we see the field, but it is cut at 255 characters!

    How, can we see, then edit and update the complete length of this field? With 4000 characters.

    THX in advance for your help.

    Best regards,

    Fabrice

  • #2
    Do you mean the field itself, e.g viewing the text you've inputted.

    If that is the case change the field to a multi-line text field, you can change the number of lines high you want to view.

    Also a multi-line field, has a variable text box size. e.g the user can change the size of the field when typing.

    Comment


    • #3
      Hi,

      Yes, it is already set as Multi Lines Text.
      Then I also tried to increase the number of lines from 6 to 50, but nothing has changed.

      I also updtaed the Field size in database, and in the value format part, the maximum size also, but nothing helps.

      Attached, you can see a screenshot of the form field options.

      For me, the problem seems more related to the database connection to MSSQL, as if I also try to view the data, with for example the following SQL request, the field is also truncated at 255 characters.
      SQL: SELECT id, Description FROM project

      THX for your help!
      Attached Files

      Comment


      • #4
        Originally posted by ssm_script View Post
        Hi,

        Yes, it is already set as Multi Lines Text.
        Then I also tried to increase the number of lines from 6 to 50, but nothing has changed.

        I also updtaed the Field size in database, and in the value format part, the maximum size also, but nothing helps.

        Attached, you can see a screenshot of the form field options.

        For me, the problem seems more related to the database connection to MSSQL, as if I also try to view the data, with for example the following SQL request, the field is also truncated at 255 characters.
        SQL: SELECT id, Description FROM project

        THX for your help!
        Ah i see, yea seems like SQL.

        I have used LONGTEXT in MySQL before and Scriptcase automatically picked up the field length at 32767.

        So maybe the field type your using NVARCHAR(4000), ScriptCase no like?

        or try NVARCHAR(MAX) instead?

        Comment


        • #5
          In fact, before we also tried nvarchar(max) and SC8 does not like this at all!

          So, this is reason why we went to nvarchar(4000).

          And the length was set to 32767, but this is not helping, so I also tested 4000 to match the MSSQL settings.

          In fact, here it is MSSQL, and not MySQL.

          Comment


          • #6
            Fair enough, i'm sorry i couldn't help you here!

            Comment


            • #7
              Originally posted by ssm_script View Post
              Hi,

              We are converting our SC7 applicatio to SC8.

              We have an MSSQL database.
              We had fields with ntext type.
              But as it is on MSSQL 2008R2 DB, and we cannot convert to never version, we converted the fields from ntext to nvarchar(4000). This in order to avoid problems on SC8.

              Now, on our Scriptcase 8 form, we see the field, but it is cut at 255 characters!

              How, can we see, then edit and update the complete length of this field? With 4000 characters.

              THX in advance for your help.

              Best regards,

              Fabrice
              Hello,

              In another topic, a user reported a problem with fields of type ntext, and solve your problem by modifying the type of connection to PDO.

              Could test resolves?

              Thank you!
              Best regards,
              Thomas Soares.
              ScriptCase International.

              Email: t.soares@scriptcase.net
              Visit our Blog: http://www.scriptcase.net/blog/
              Visit out fan page: http://www.facebook.com/Scriptcase

              Comment


              • #8
                Hi,

                This is not an option as the drivers need to be updated to version 2012, and this cannot be done on this server!

                For me, there is clearly a bug somewhere.

                So, can someone confirm this?

                Comment

                Working...
                X