Results 1 to 2 of 2
  1. #1
    Join Date
    May 2013
    Posts
    1

    Unanswered: Scalar function: format address

    Hey everybody,

    I'm beging in DB2 and I need creat some scalar function but I don't know how to start here is my exercise:

    Define a scalar function, which takes the ID of an address as input parameter and return a string in the format "user@domain", e.g. "john@foobar.com".

    Function name: format_address
    Input: addressId of type "ref(address_t)"
    Output: formatted address string of type "varchar"

    Someone knows how can I to do that?

  2. #2
    Join Date
    Apr 2006
    Location
    Belgium
    Posts
    2,514
    Provided Answers: 11
    Best Regards, Guy Przytula
    Database Software Consultant
    Good DBAs are not formed in a week or a month. They are created little by little, day by day. Protracted and patient effort is needed to develop good DBAs.
    Spoon feeding : To treat (another) in a way that discourages independent thought or action, as by overindulgence.
    DB2 UDB LUW Certified V7-V8-V9-V9.7-V10.1-V10.5 DB Admin - Advanced DBA -Dprop..
    Information Server Datastage Certified
    http://www.infocura.be

Posting Permissions

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