DBAsupport.com Forums - Powered by vBulletin
Results 1 to 3 of 3

Thread: Update question

  1. #1
    Join Date
    Nov 2002
    Posts
    25

    Update question

    Hi,

    I've got a table t1 with a column TEST thats a varchar2(16). It holds a loads of records padded records, i.e they're all length 16 even though some entries are only 4 characters long. I need to update the column TEST to remove the padding but am struggling to come up with the SQL. Can anyone help please!?

  2. #2
    Join Date
    Nov 2002
    Location
    Geneva Switzerland
    Posts
    3,142
    UPDATE T1 SET TEST=TRIM(TEST);
    "The power of instruction is seldom of much efficacy except in those happy dispositions where it is almost superfluous" - Gibbon, quoted by R.P.Feynman

  3. #3
    Join Date
    Nov 2002
    Posts
    25
    D'oh!! And there was me messing with self joins and stuff! Not having a good day

Posting Permissions

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


Click Here to Expand Forum to Full Width