Results 1 to 3 of 3
  1. #1
    Join Date
    Oct 2014
    Posts
    1

    Unanswered: Meaning of this sql statement in db2

    Hi Friends,

    I was trying to understand what this function does. Is the use of 'count' valid here?

    REPEAT(' ',5-length(rtrim(char(count('Arvin Holmes')))))

    Thank you for your help with this.

  2. #2
    Join Date
    Jun 2003
    Location
    Toronto, Canada
    Posts
    5,516
    Provided Answers: 1
    This is an incomplete statement, so it cannot have any meaning. May be you can publish a larger fragment, if not the entire statement.
    ---
    "It does not work" is not a valid problem statement.

  3. #3
    Join Date
    Feb 2008
    Location
    Japan
    Posts
    3,483
    I agree with n_i.

    Without knowing the context(e.g. phrase, clause, statement, so on...) in which the expression was used,
    it might be difficult to say the validity and/or the meaning of the expression.


    Anyway,
    syntax of "count('Arvin Holmes')" in itself is valid.
    (Though, I couldn't understand the meaning of 'Arvin Holmes')

    For example:
    Code:
    ------------------------------ Commands Entered ------------------------------
    SELECT count('Arvin Holmes')
     FROM  department
    ;
    ------------------------------------------------------------------------------
    
    1          
    -----------
              9
    
      1 record(s) selected.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •