Results 1 to 9 of 9
  1. #1
    Join Date
    Dec 2012
    Posts
    53

    Unanswered: db2 table definition

    Hi all

    Today i saw some tables in db with table names start with /aa/asjkjk something like that and other table names are fine starts witha character .

    and I execute the following query to see table names

    query -- db2 select tabname from syscat.tables where tabschema= 'schemaname' "

  2. #2
    Join Date
    Apr 2006
    Location
    Belgium
    Posts
    2,514
    Provided Answers: 11
    so : question/problem ??
    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

  3. #3
    Join Date
    Dec 2012
    Posts
    53
    question? is it possible to create tables with name starts with special character

  4. #4
    Join Date
    Apr 2006
    Location
    Belgium
    Posts
    2,514
    Provided Answers: 11
    yes you can.. as long as it does not start with sys....
    to query these tables is another topic...
    have a look at
    http://publib.boulder.ibm.com/infoce.../c0007245.html
    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

  5. #5
    Join Date
    Dec 2012
    Posts
    53
    thanks
    can you help me on how to query those tables.

  6. #6
    Join Date
    Apr 2006
    Location
    Belgium
    Posts
    2,514
    Provided Answers: 11
    from a command file: db2 -tvf tt
    tt : keeping -->
    select * from "/test" ;
    from command window single quotes - double quotes - escape characters can help
    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

  7. #7
    Join Date
    Dec 2012
    Posts
    53
    from command window i tried
    db2 " select colm1 from "/1c/aaaa" ". throwing error-SQL0103N The numeric literal "1CN" is not valid-

  8. #8
    Join Date
    Apr 2006
    Location
    Belgium
    Posts
    2,514
    Provided Answers: 11
    tried in linux
    (4)[db2inst1@dlx00031 work]$ db2 'select * from "/test" '

    COL1
    -----------

    0 record(s) selected.
    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

  9. #9
    Join Date
    Dec 2012
    Posts
    53
    it's working . I tried on AIX , thanks a lott. you are db2 genius .

Posting Permissions

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