Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
Clear All
new posts

    Connecting different datasources to different DBs

    Hi Isomorphic,

    Hi Isomorphic Team,
    We are using the ismorphic version : 6.1-p20170930
    my current functionality uses SmartGWT + Spring Rest services.
    We are using Google chrome browser latest version.

    My application has a page which has 2 components (Form and Grid)
    Grid is connected to Datasource1 and Form is connected to Datasource2.

    I want Datasource1 to connect to a 'DB2' schema tables and
    Datasource2 to connect to 'Sql server' schema tables.

    I want to use "customHQL" in my ds.xml files.

    Could you please suggest how I can achieve this?

    #2
    If these are SQLDataSources, you just use a different setting for DataSource.dbName. You can use customSQL as usual.

    However for some reason you also mention customHQL, which is a feature of HibernateDataSources, not SQLDataSources. If that's not just a typo, then note that for Hibernate, connections to multiple different databases are handled via Hibernate configuration.

    Comment


      #3
      Oh and also, it almost certainly does not make sense to use Spring Rest Services since you already have our server framework. That would just create a lot of unnecessary extra work. Even if you already have the services built, it's still probably a bad idea - see the FAQ about using pre-existing REST services.

      Comment

      Working...
      X