Debugging: String or binary data would be truncated

Discussion in 'ASP General' started by Lord Merlin, Apr 19, 2004.

  1. Lord Merlin

    Lord Merlin Guest

    I hope someone can help me with this:

    This error gets generated from one of my client's sites, which records a
    lot of info via forms. It happened today, when someone tried to make a
    comment about a company, yet it's the only time that this error was recorded
    while doing a capture. My client has however been complaining for a few days
    now, that when she wants to display all comments added for the past 5 days,
    she gets that error. On the form is a dropdown that has different industry
    categories, and when she choose any of those categories, and it only display
    comments for that category it's fine.
    If I run the query in enterprise manager, it's fine.

    Now, what makes it a bit more interesting. When I run the queries @ night,
    when there are less people on the site, it works fine, when I run it during
    the day, it gives me this error. Can this directly be related to server
    taking strain? Too high CPU / Memory usage?

    How would I debug / diagnose such a problem?

    --

    Kind Regards
    Rudi Ahlers
    +27 (82) 926 1689

    Greater love has no one than this, that he lay down his life for his friends
    (John 15:13).
     
    Lord Merlin, Apr 19, 2004
    #1
    1. Advertising

  2. Lord Merlin

    Ray at Guest

    This means that the column in the database accepts a maximum datalength of
    n, and the value that your page tried to insert into the database was > n.

    Like, if you have a column called Comments with a maximum length of 500 and
    someone writes a 600 character paragraph and tries to submit the form, you
    page doesn't have anything in place to deal with data that is longer than
    the allowed length.

    Ray at work

    "Lord Merlin" <SP4M_Rudi@SP4M_Bonzai.org.za_SP4M> wrote in message
    news:...
    > I hope someone can help me with this:
    >
    > This error gets generated from one of my client's sites, which records a
    > lot of info via forms. It happened today, when someone tried to make a
    > comment about a company, yet it's the only time that this error was

    recorded
    > while doing a capture. My client has however been complaining for a few

    days
    > now, that when she wants to display all comments added for the past 5

    days,
    > she gets that error. On the form is a dropdown that has different industry
    > categories, and when she choose any of those categories, and it only

    display
    > comments for that category it's fine.
    > If I run the query in enterprise manager, it's fine.
    >
    > Now, what makes it a bit more interesting. When I run the queries @ night,
    > when there are less people on the site, it works fine, when I run it

    during
    > the day, it gives me this error. Can this directly be related to server
    > taking strain? Too high CPU / Memory usage?
    >
    > How would I debug / diagnose such a problem?
    >
    > --
    >
    > Kind Regards
    > Rudi Ahlers
    > +27 (82) 926 1689
    >
    > Greater love has no one than this, that he lay down his life for his

    friends
    > (John 15:13).
    >
    >
     
    Ray at, Apr 19, 2004
    #2
    1. Advertising

  3. Lord Merlin

    Bob Barrows Guest

    The error is a warning that the string you are attempting to use to set a
    column's value is too long to fit into the column which is being used. It
    has nothing to do with number of users, memory, etc. It means the string is
    too long.

    You will need to validate the comment and make sure it will fit into the
    column for which it is intended. I can't get specific because I can't see
    the code you are using to pass this value to the database.

    In the future, please provide the ENTIRE error message. I happened to
    recognize this as a database error message, but others might not, causing
    them to waste their time and yours with irrelevant suggestions.

    Bob Barrows

    Lord Merlin wrote:
    > I hope someone can help me with this:
    >
    > Now, what makes it a bit more interesting. When I run the queries @
    > night, when there are less people on the site, it works fine, when I
    > run it during the day, it gives me this error. Can this directly be
    > related to server taking strain? Too high CPU / Memory usage?
    >
    > How would I debug / diagnose such a problem?


    --
    Microsoft MVP - ASP/ASP.NET
    Please reply to the newsgroup. This email account is my spam trap so I
    don't check it very often. If you must reply off-line, then remove the
    "NO SPAM"
     
    Bob Barrows, Apr 19, 2004
    #3
  4. Lord Merlin

    Lord Merlin Guest

    Hi Bob

    I appreciate what you say. The page in question does have JavaScript to
    limit the input. Here is the code:

    strsubject = Trim(strsubject )
    incident = Trim(incident )
    solution = Trim(solution )

    ticksubscriber = "N"
    tickindustry = "N"
    companycount = 0

    strcomment = GetFormData("strcomment")
    subscriber = GetFormData("subscriber")
    company_dont = GetFormData("company_dont")
    industry = GetFormData("industry")
    othersupplier = Trim(GetFormData("othersupplier"))
    if subscriber = "0" then
    'tickindustry = "Y"
    if company_dont ="0" then
    else
    othersupplier = company_dont
    tickindustry = "Y"
    end if
    else
    othersupplier = subscriber
    ticksubscriber = "Y"
    tickindustry = "Y"
    end if
    country = GetFormData("country")
    province = Trim(GetFormData("strprovince"))
    city = Trim(GetFormData("city"))
    area = Trim(GetFormData("area"))
    person = Trim(GetFormData("person"))
    telno = GetFormData("telno")
    datemonth = GetFormData("datemonth")
    dateday = GetFormData("dateday")
    dateyear = GetFormData("dateyear")
    timehour = GetFormData("timehour")
    timeminute = GetFormData("timeminute")
    timeampm = GetFormData("timeampm")
    alias = Trim(GetFormData("alias"))
    fullname = Trim(GetFormData("fullname"))
    emailaddress = Trim(GetFormData("emailaddress"))
    tel1 = Trim(GetFormData("telnum1"))
    tel2 = Trim(GetFormData("telnum2"))
    contacttype = GetFormData("contacttype")

    if ((timehour = "") OR (timehour = " ")) then timehour = "1"
    if ((timeminute = "") OR (timeminute = " ")) then timeminute = "00"
    if ((timeampm = "") OR (timeampm = " ")) then timeampm = "AM"

    telnum1 = tel1 & " " & tel2
    'currentdate = Now()
    currentdate = Month(Date())& "/" & Day(Date())& "/" & Year(Date())& " " &
    formatdatetime(now(),3)

    tempcompany = othersupplier

    thedate = datemonth & "/" & dateday & "/" & dateyear & " " & timehour & ":"
    & timeminute & " " & timeampm




    InsertQuery="INSERT INTO comments " &_
    "(NUserID,thedate, currentdate, commenttype, userid, username,
    supplier, person, subject, description, solution, industry, country,
    province, city, area, emailsent, clientresponse, compliment,
    complaint,telno,subscriber)" &_
    " VALUES (" & Session("NUserID") & ", '" &_
    thedate & "','" &_
    currentdate & "','" &_
    strcomment & "'," &_
    Session("NUserID") & ",'" &_
    alias & "','" &_
    Replace(companyname,"'","''") & "','" &_
    person & "','" &_
    Replace(strsubject, "'", chr(39) & chr(39)) & "','" &_
    Replace(incident, "'", chr(39) & chr(39)) & "','" &_
    Replace(solution, "'", chr(39) & chr(39)) & "','" &_
    industry & "','" &_
    country & "','" &_
    province & "','" &_
    city & "','" &_
    area & "','" &_
    "no" & "','" &_
    "" & "'," &_
    compliment & "," &_
    complaint & ",'" &_
    telno & "','" & ticksubscriber & "');Select @@IDENTITY as id;"



    And the Javascript to limit the input:


    function checkincident() {
    var formname = document.commentform;
    var incident = formname.incident.value;

    if (incident.length > 1199) {
    alert("Please limit your Incident Description to 1200 characters!");
    return(false);
    }
    }

    function checksolution() {
    var formname = document.commentform;
    var solution = formname.solution.value;

    if (solution.length > 1199) {
    alert("Please limit your Solution to 1200 characters!");
    return(false);
    }
    }


    I hope this is useful :)

    --

    Kind Regards
    Rudi Ahlers
    +27 (82) 926 1689

    Greater love has no one than this, that he lay down his life for his friends
    (John 15:13).
    "Bob Barrows" <> wrote in message
    news:...
    : The error is a warning that the string you are attempting to use to set a
    : column's value is too long to fit into the column which is being used. It
    : has nothing to do with number of users, memory, etc. It means the string
    is
    : too long.
    :
    : You will need to validate the comment and make sure it will fit into the
    : column for which it is intended. I can't get specific because I can't see
    : the code you are using to pass this value to the database.
    :
    : In the future, please provide the ENTIRE error message. I happened to
    : recognize this as a database error message, but others might not, causing
    : them to waste their time and yours with irrelevant suggestions.
    :
    : Bob Barrows
    :
    : Lord Merlin wrote:
    : > I hope someone can help me with this:
    : >
    : > Now, what makes it a bit more interesting. When I run the queries @
    : > night, when there are less people on the site, it works fine, when I
    : > run it during the day, it gives me this error. Can this directly be
    : > related to server taking strain? Too high CPU / Memory usage?
    : >
    : > How would I debug / diagnose such a problem?
    :
    : --
    : Microsoft MVP - ASP/ASP.NET
    : Please reply to the newsgroup. This email account is my spam trap so I
    : don't check it very often. If you must reply off-line, then remove the
    : "NO SPAM"
    :
    :
     
    Lord Merlin, Apr 20, 2004
    #4
  5. Lord Merlin

    Ken Schaefer Guest

    Verify the length of the input on the *server*

    a) javascript may not be running on the client
    b) javascript may have a bug
    c) ??

    You can't rely on client-side validation to protect the app, since the code
    is running on an untrusted machine completely out of your server's control.
    The only benefit to running javascript is to save the user a round-trip. You
    need to reverify everything on the server.

    Cheers
    Ken


    "Lord Merlin" <SP4M_Rudi@SP4M_Bonzai.org.za_SP4M> wrote in message
    news:...
    : Hi Bob
    :
    : I appreciate what you say. The page in question does have JavaScript to
    : limit the input. Here is the code:
    :
    : strsubject = Trim(strsubject )
    : incident = Trim(incident )
    : solution = Trim(solution )
    :
    : ticksubscriber = "N"
    : tickindustry = "N"
    : companycount = 0
    :
    : strcomment = GetFormData("strcomment")
    : subscriber = GetFormData("subscriber")
    : company_dont = GetFormData("company_dont")
    : industry = GetFormData("industry")
    : othersupplier = Trim(GetFormData("othersupplier"))
    : if subscriber = "0" then
    : 'tickindustry = "Y"
    : if company_dont ="0" then
    : else
    : othersupplier = company_dont
    : tickindustry = "Y"
    : end if
    : else
    : othersupplier = subscriber
    : ticksubscriber = "Y"
    : tickindustry = "Y"
    : end if
    : country = GetFormData("country")
    : province = Trim(GetFormData("strprovince"))
    : city = Trim(GetFormData("city"))
    : area = Trim(GetFormData("area"))
    : person = Trim(GetFormData("person"))
    : telno = GetFormData("telno")
    : datemonth = GetFormData("datemonth")
    : dateday = GetFormData("dateday")
    : dateyear = GetFormData("dateyear")
    : timehour = GetFormData("timehour")
    : timeminute = GetFormData("timeminute")
    : timeampm = GetFormData("timeampm")
    : alias = Trim(GetFormData("alias"))
    : fullname = Trim(GetFormData("fullname"))
    : emailaddress = Trim(GetFormData("emailaddress"))
    : tel1 = Trim(GetFormData("telnum1"))
    : tel2 = Trim(GetFormData("telnum2"))
    : contacttype = GetFormData("contacttype")
    :
    : if ((timehour = "") OR (timehour = " ")) then timehour = "1"
    : if ((timeminute = "") OR (timeminute = " ")) then timeminute = "00"
    : if ((timeampm = "") OR (timeampm = " ")) then timeampm = "AM"
    :
    : telnum1 = tel1 & " " & tel2
    : 'currentdate = Now()
    : currentdate = Month(Date())& "/" & Day(Date())& "/" & Year(Date())& " " &
    : formatdatetime(now(),3)
    :
    : tempcompany = othersupplier
    :
    : thedate = datemonth & "/" & dateday & "/" & dateyear & " " & timehour &
    ":"
    : & timeminute & " " & timeampm
    :
    :
    :
    :
    : InsertQuery="INSERT INTO comments " &_
    : "(NUserID,thedate, currentdate, commenttype, userid, username,
    : supplier, person, subject, description, solution, industry, country,
    : province, city, area, emailsent, clientresponse, compliment,
    : complaint,telno,subscriber)" &_
    : " VALUES (" & Session("NUserID") & ", '" &_
    : thedate & "','" &_
    : currentdate & "','" &_
    : strcomment & "'," &_
    : Session("NUserID") & ",'" &_
    : alias & "','" &_
    : Replace(companyname,"'","''") & "','" &_
    : person & "','" &_
    : Replace(strsubject, "'", chr(39) & chr(39)) & "','" &_
    : Replace(incident, "'", chr(39) & chr(39)) & "','" &_
    : Replace(solution, "'", chr(39) & chr(39)) & "','" &_
    : industry & "','" &_
    : country & "','" &_
    : province & "','" &_
    : city & "','" &_
    : area & "','" &_
    : "no" & "','" &_
    : "" & "'," &_
    : compliment & "," &_
    : complaint & ",'" &_
    : telno & "','" & ticksubscriber & "');Select @@IDENTITY as id;"
    :
    :
    :
    : And the Javascript to limit the input:
    :
    :
    : function checkincident() {
    : var formname = document.commentform;
    : var incident = formname.incident.value;
    :
    : if (incident.length > 1199) {
    : alert("Please limit your Incident Description to 1200 characters!");
    : return(false);
    : }
    : }
    :
    : function checksolution() {
    : var formname = document.commentform;
    : var solution = formname.solution.value;
    :
    : if (solution.length > 1199) {
    : alert("Please limit your Solution to 1200 characters!");
    : return(false);
    : }
    : }
    :
    :
    : I hope this is useful :)
    :
    : --
    :
    : Kind Regards
    : Rudi Ahlers
    : +27 (82) 926 1689
    :
    : Greater love has no one than this, that he lay down his life for his
    friends
    : (John 15:13).
    : "Bob Barrows" <> wrote in message
    : news:...
    : : The error is a warning that the string you are attempting to use to set
    a
    : : column's value is too long to fit into the column which is being used.
    It
    : : has nothing to do with number of users, memory, etc. It means the string
    : is
    : : too long.
    : :
    : : You will need to validate the comment and make sure it will fit into the
    : : column for which it is intended. I can't get specific because I can't
    see
    : : the code you are using to pass this value to the database.
    : :
    : : In the future, please provide the ENTIRE error message. I happened to
    : : recognize this as a database error message, but others might not,
    causing
    : : them to waste their time and yours with irrelevant suggestions.
    : :
    : : Bob Barrows
    : :
    : : Lord Merlin wrote:
    : : > I hope someone can help me with this:
    : : >
    : : > Now, what makes it a bit more interesting. When I run the queries @
    : : > night, when there are less people on the site, it works fine, when I
    : : > run it during the day, it gives me this error. Can this directly be
    : : > related to server taking strain? Too high CPU / Memory usage?
    : : >
    : : > How would I debug / diagnose such a problem?
    : :
    : : --
    : : Microsoft MVP - ASP/ASP.NET
    : : Please reply to the newsgroup. This email account is my spam trap so I
    : : don't check it very often. If you must reply off-line, then remove the
    : : "NO SPAM"
    : :
    : :
    :
    :
     
    Ken Schaefer, Apr 20, 2004
    #5
  6. Lord Merlin

    Lord Merlin Guest

    Ok, this is a good point you bring out, and it didn't cross my mind. How
    though, would I do it?
    I now have two inputs, incident = Trim(incident ) and solution =
    Trim(solution ) <- these are the text fields.
    what would the code be to check the length of the characters, and what is a
    good recommendation todo if the string is longer that 1200 caracters?
    Redirect them to a new page, with the same text box, and their text, but
    with that which is longer than the 1200 caracters? I can't insert
    half-cutoff sentences, so I would need to make them retype say the last
    sentense or so.
    --

    Kind Regards
    Rudi Ahlers
    +27 (82) 926 1689

    Greater love has no one than this, that he lay down his life for his friends
    (John 15:13).
    "Ken Schaefer" <> wrote in message
    news:#...
    : Verify the length of the input on the *server*
    :
    : a) javascript may not be running on the client
    : b) javascript may have a bug
    : c) ??
    :
    : You can't rely on client-side validation to protect the app, since the
    code
    : is running on an untrusted machine completely out of your server's
    control.
    : The only benefit to running javascript is to save the user a round-trip.
    You
    : need to reverify everything on the server.
    :
    : Cheers
    : Ken
    :
    :
    : "Lord Merlin" <SP4M_Rudi@SP4M_Bonzai.org.za_SP4M> wrote in message
    : news:...
    : : Hi Bob
    : :
    : : I appreciate what you say. The page in question does have JavaScript to
    : : limit the input. Here is the code:
    : :
    : : strsubject = Trim(strsubject )
    : : incident = Trim(incident )
    : : solution = Trim(solution )
    : :
    : : ticksubscriber = "N"
    : : tickindustry = "N"
    : : companycount = 0
    : :
    : : strcomment = GetFormData("strcomment")
    : : subscriber = GetFormData("subscriber")
    : : company_dont = GetFormData("company_dont")
    : : industry = GetFormData("industry")
    : : othersupplier = Trim(GetFormData("othersupplier"))
    : : if subscriber = "0" then
    : : 'tickindustry = "Y"
    : : if company_dont ="0" then
    : : else
    : : othersupplier = company_dont
    : : tickindustry = "Y"
    : : end if
    : : else
    : : othersupplier = subscriber
    : : ticksubscriber = "Y"
    : : tickindustry = "Y"
    : : end if
    : : country = GetFormData("country")
    : : province = Trim(GetFormData("strprovince"))
    : : city = Trim(GetFormData("city"))
    : : area = Trim(GetFormData("area"))
    : : person = Trim(GetFormData("person"))
    : : telno = GetFormData("telno")
    : : datemonth = GetFormData("datemonth")
    : : dateday = GetFormData("dateday")
    : : dateyear = GetFormData("dateyear")
    : : timehour = GetFormData("timehour")
    : : timeminute = GetFormData("timeminute")
    : : timeampm = GetFormData("timeampm")
    : : alias = Trim(GetFormData("alias"))
    : : fullname = Trim(GetFormData("fullname"))
    : : emailaddress = Trim(GetFormData("emailaddress"))
    : : tel1 = Trim(GetFormData("telnum1"))
    : : tel2 = Trim(GetFormData("telnum2"))
    : : contacttype = GetFormData("contacttype")
    : :
    : : if ((timehour = "") OR (timehour = " ")) then timehour = "1"
    : : if ((timeminute = "") OR (timeminute = " ")) then timeminute = "00"
    : : if ((timeampm = "") OR (timeampm = " ")) then timeampm = "AM"
    : :
    : : telnum1 = tel1 & " " & tel2
    : : 'currentdate = Now()
    : : currentdate = Month(Date())& "/" & Day(Date())& "/" & Year(Date())& " "
    &
    : : formatdatetime(now(),3)
    : :
    : : tempcompany = othersupplier
    : :
    : : thedate = datemonth & "/" & dateday & "/" & dateyear & " " & timehour &
    : ":"
    : : & timeminute & " " & timeampm
    : :
    : :
    : :
    : :
    : : InsertQuery="INSERT INTO comments " &_
    : : "(NUserID,thedate, currentdate, commenttype, userid, username,
    : : supplier, person, subject, description, solution, industry, country,
    : : province, city, area, emailsent, clientresponse, compliment,
    : : complaint,telno,subscriber)" &_
    : : " VALUES (" & Session("NUserID") & ", '" &_
    : : thedate & "','" &_
    : : currentdate & "','" &_
    : : strcomment & "'," &_
    : : Session("NUserID") & ",'" &_
    : : alias & "','" &_
    : : Replace(companyname,"'","''") & "','" &_
    : : person & "','" &_
    : : Replace(strsubject, "'", chr(39) & chr(39)) & "','" &_
    : : Replace(incident, "'", chr(39) & chr(39)) & "','" &_
    : : Replace(solution, "'", chr(39) & chr(39)) & "','" &_
    : : industry & "','" &_
    : : country & "','" &_
    : : province & "','" &_
    : : city & "','" &_
    : : area & "','" &_
    : : "no" & "','" &_
    : : "" & "'," &_
    : : compliment & "," &_
    : : complaint & ",'" &_
    : : telno & "','" & ticksubscriber & "');Select @@IDENTITY as id;"
    : :
    : :
    : :
    : : And the Javascript to limit the input:
    : :
    : :
    : : function checkincident() {
    : : var formname = document.commentform;
    : : var incident = formname.incident.value;
    : :
    : : if (incident.length > 1199) {
    : : alert("Please limit your Incident Description to 1200 characters!");
    : : return(false);
    : : }
    : : }
    : :
    : : function checksolution() {
    : : var formname = document.commentform;
    : : var solution = formname.solution.value;
    : :
    : : if (solution.length > 1199) {
    : : alert("Please limit your Solution to 1200 characters!");
    : : return(false);
    : : }
    : : }
    : :
    : :
    : : I hope this is useful :)
    : :
    : : --
    : :
    : : Kind Regards
    : : Rudi Ahlers
    : : +27 (82) 926 1689
    : :
    : : Greater love has no one than this, that he lay down his life for his
    : friends
    : : (John 15:13).
    : : "Bob Barrows" <> wrote in message
    : : news:...
    : : : The error is a warning that the string you are attempting to use to
    set
    : a
    : : : column's value is too long to fit into the column which is being used.
    : It
    : : : has nothing to do with number of users, memory, etc. It means the
    string
    : : is
    : : : too long.
    : : :
    : : : You will need to validate the comment and make sure it will fit into
    the
    : : : column for which it is intended. I can't get specific because I can't
    : see
    : : : the code you are using to pass this value to the database.
    : : :
    : : : In the future, please provide the ENTIRE error message. I happened to
    : : : recognize this as a database error message, but others might not,
    : causing
    : : : them to waste their time and yours with irrelevant suggestions.
    : : :
    : : : Bob Barrows
    : : :
    : : : Lord Merlin wrote:
    : : : > I hope someone can help me with this:
    : : : >
    : : : > Now, what makes it a bit more interesting. When I run the queries @
    : : : > night, when there are less people on the site, it works fine, when I
    : : : > run it during the day, it gives me this error. Can this directly be
    : : : > related to server taking strain? Too high CPU / Memory usage?
    : : : >
    : : : > How would I debug / diagnose such a problem?
    : : :
    : : : --
    : : : Microsoft MVP - ASP/ASP.NET
    : : : Please reply to the newsgroup. This email account is my spam trap so I
    : : : don't check it very often. If you must reply off-line, then remove the
    : : : "NO SPAM"
    : : :
    : : :
    : :
    : :
    :
    :
     
    Lord Merlin, Apr 20, 2004
    #6
  7. Lord Merlin

    roger Guest

    "Lord Merlin" wrote
    > Ok, this is a good point you bring out, and it didn't cross my mind. How
    > though, would I do it?
    > I now have two inputs, incident = Trim(incident ) and solution =
    > Trim(solution ) <- these are the text fields.
    > what would the code be to check the length of the characters, and what is

    a
    > good recommendation todo if the string is longer that 1200 caracters?
    > Redirect them to a new page, with the same text box, and their text, but
    > with that which is longer than the 1200 caracters? I can't insert
    > half-cutoff sentences, so I would need to make them retype say the last
    > sentense or so.


    In vbscript that would be -

    if len(string) > 1200 then redisplay_data

    --
    roger
     
    roger, Apr 21, 2004
    #7
  8. Lord Merlin

    Lord Merlin Guest

    Thanx Roger

    --

    Kind Regards
    Rudi Ahlers
    +27 (82) 926 1689

    Greater love has no one than this, that he lay down his life for his friends
    (John 15:13).
    "roger" <> wrote in message
    news:c65iuq$n7r$...
    : "Lord Merlin" wrote
    : > Ok, this is a good point you bring out, and it didn't cross my mind. How
    : > though, would I do it?
    : > I now have two inputs, incident = Trim(incident ) and solution =
    : > Trim(solution ) <- these are the text fields.
    : > what would the code be to check the length of the characters, and what
    is
    : a
    : > good recommendation todo if the string is longer that 1200 caracters?
    : > Redirect them to a new page, with the same text box, and their text, but
    : > with that which is longer than the 1200 caracters? I can't insert
    : > half-cutoff sentences, so I would need to make them retype say the last
    : > sentense or so.
    :
    : In vbscript that would be -
    :
    : if len(string) > 1200 then redisplay_data
    :
    : --
    : roger
    :
    :
     
    Lord Merlin, Apr 21, 2004
    #8
  9. Lord Merlin

    Lord Merlin Guest

    Thanx Roger

    --

    Kind Regards
    Rudi Ahlers
    +27 (82) 926 1689

    Greater love has no one than this, that he lay down his life for his friends
    (John 15:13).
    "roger" <> wrote in message
    news:c65iuq$n7r$...
    : "Lord Merlin" wrote
    : > Ok, this is a good point you bring out, and it didn't cross my mind. How
    : > though, would I do it?
    : > I now have two inputs, incident = Trim(incident ) and solution =
    : > Trim(solution ) <- these are the text fields.
    : > what would the code be to check the length of the characters, and what
    is
    : a
    : > good recommendation todo if the string is longer that 1200 caracters?
    : > Redirect them to a new page, with the same text box, and their text, but
    : > with that which is longer than the 1200 caracters? I can't insert
    : > half-cutoff sentences, so I would need to make them retype say the last
    : > sentense or so.
    :
    : In vbscript that would be -
    :
    : if len(string) > 1200 then redisplay_data
    :
    : --
    : roger
    :
    :
     
    Lord Merlin, Apr 21, 2004
    #9
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Replies:
    1
    Views:
    27,417
  2. dermoon
    Replies:
    0
    Views:
    501
    dermoon
    Oct 8, 2003
  3. =?Utf-8?B?RGF2ZQ==?=
    Replies:
    2
    Views:
    16,089
    Alexey Smirnov
    Jul 15, 2007
  4. George Jackson
    Replies:
    1
    Views:
    216
    George Jackson
    Jan 11, 2006
  5. J. Muenchbourg

    String or binary data would be truncated error

    J. Muenchbourg, Sep 18, 2003, in forum: ASP General
    Replies:
    1
    Views:
    180
    Ray at
    Sep 18, 2003
Loading...

Share This Page