Results 1 to 14 of 14

Thread: Sequences

  1. #1
    Join Date
    Jan 2009
    Posts
    153

    Unanswered: Sequences

    Hi Experts,

    I have two databases and one contain all the sequences and the other contains tables.

    Is it possible to insert data into tablesin database2 using the sequence from database1?

    TIA

  2. #2
    Join Date
    Jan 2007
    Location
    Jena, Germany
    Posts
    2,721
    Different answer: have you considered using DB2's SEQUENCE objects? Have a look at the CREATE SEQUENCE statement.
    Knut Stolze
    IBM DB2 Analytics Accelerator
    IBM Germany Research & Development

  3. #3
    Join Date
    Jan 2009
    Posts
    153
    Thanks for the reply stolze...

    I have created sequences in Db1 and tables in Db2 ...i want to insert data on to tables in db2 using the sequences in db1.

    Is it possible to do that?

  4. #4
    Join Date
    Jan 2007
    Location
    Jena, Germany
    Posts
    2,721
    What do you mean with "created sequences in DB1"? Which version of DB2 are you using on which platform?

    In DB2 z/OS, a database is basically just a qualifier for tablespaces (plus some privilege management). Aside from that, you can ignore it. In DB2 LUW, a database represents a fully encapsulated entity for your data and database objects. If you want to do cross-database operations in DB2 LUW, you need federation.
    Knut Stolze
    IBM DB2 Analytics Accelerator
    IBM Germany Research & Development

  5. #5
    Join Date
    Jan 2009
    Posts
    153
    Thanks Stolze ,

    I mean i have created sequences in the first database.

    How to do federation or how can i achieve that?

    TIA

  6. #6
    Join Date
    Jan 2009
    Posts
    153
    Can you please tell me how to access an object from databaseA when we are connected to databaseB

    TIA

  7. #7
    Join Date
    Jan 2009
    Posts
    153
    Is it possible to query like this

    SELECT * FROM DATABASE1.ADMINISTRATOR.CARDT
    When I am connected to DATABASE2

  8. #8
    Join Date
    Jan 2007
    Location
    Jena, Germany
    Posts
    2,721
    Once you answer the question on the DB2 version and platform, we can tell you whether federation is applicable for you. Regarding federation, have a look at the manuals. This topic has been discussed there and also here in the forum extensively.
    Knut Stolze
    IBM DB2 Analytics Accelerator
    IBM Germany Research & Development

  9. #9
    Join Date
    Jan 2009
    Posts
    153
    DB2 Version:9.5c Express
    OS Version:Windows XP

  10. #10
    Join Date
    Jan 2007
    Location
    Jena, Germany
    Posts
    2,721
    I don't know if your edition/license entitles you to use DB2's federation feature.

    You will find the DB2 manuals here: IBM DB2 9.5 Information Center for Linux, UNIX, and Windows
    Knut Stolze
    IBM DB2 Analytics Accelerator
    IBM Germany Research & Development

  11. #11
    Join Date
    Nov 2005
    Location
    IL
    Posts
    557
    federation future is not free in Express

    IBM DB2 9.5 Information Center for Linux, UNIX, and Windows
    --
    IBM Certified DBA on DB2 for Linux, UNIX, and Windows

    DB2 v9.7.0.6 os 6.1.0.0

  12. #12
    Join Date
    Jan 2009
    Posts
    153
    Thanks Cougar,


    which is the free version available with federation applicable?

    What is the price for DB2 versions?

    TIA

  13. #13
    Join Date
    Nov 2005
    Location
    IL
    Posts
    557
    follow the link that I have provided.
    --
    IBM Certified DBA on DB2 for Linux, UNIX, and Windows

    DB2 v9.7.0.6 os 6.1.0.0

  14. #14
    Join Date
    Jan 2009
    Posts
    153
    I went through the link but I am unable to find any pricing details of DB2 9.5 Express

Posting Permissions

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