Americans spent $135.5 billion on back-to-school and back-to-college shopping in 2023, making the season a …
Cloud-native POS platform for seamless omnichannel customer experience.
A single hub for all promotions campaigns.
The most advanced synchronization solution for databases and file systems.
Data configuration and batch automation across different disparate systems and vendors.
Americans spent $135.5 billion on back-to-school and back-to-college shopping in 2023, making the season a …
Google may have introduced the concept of micro-moments almost ten years ago, but year after …
We’ve all heard the words omnichannel and seamless shopping by now…but achieving it can be …
The new release of SymmetricDS Pro 3.16 data replication software simplifies setup, improves performance, and …
Sybase ASE (more recently known as SAP Adaptive Server Enterprise), announced its end of mainstream …
Azure Blob Storage has become a popular option for storing files in the cloud. And …
Jumpmind Powers Point of Sale and Promotions Execution for Landmark Retail, One of the Largest …
Retail Technology Leader Jumpmind to Enable Mobile Point of Sale and Inventory Management for DTLR/VILLA …
The retailer is charting its next chapter with retail technology modernization to power inspired omnichannel …
Jumpmind Powers Point of Sale and Promotions Execution for Landmark Retail, One of the Largest …
Jumpmind Launches The Jumpmind Cloud, Powered by Amazon Web Services New Offering Provides Newfound Application …
Retail Technology Leader Jumpmind to Enable Mobile Point of Sale and Inventory Management for DTLR/VILLA …
Cloud-native POS platform for seamless omnichannel customer experience.
A single hub for all promotions campaigns.
The most advanced synchronization solution for databases and file systems.
Data configuration and batch automation across different disparate systems and vendors.
SymmetricDS can be used to replicate Firebird databases to the cloud for Disaster Recovery. Setup is fairly straightforward. Select the tables you want to sync and the direction you want to sync them and, voilà, you have a backup database. While this is all well and good, if the database relies on id generators for primary key generation, then when failing over to the slave database you will probably end up with generators that no longer reflect the next value to insert.
You can solve this problem by adding load transforms to your tables that use generators. The following example is a Java Extension Point that can be used as a column transform that keeps a named generator up to date.
First, you want to add a new extension point. You do this from the Configure > Extensions screen. Make sure you select the ISingleNewAndOldValueColumnTransform interface.
Adding a Custom Extension Point
Next, you need to add the Java code that represents the implementation of the interface. You do this by selecting the extension and pressing the Edit Script button.
Adding Java Code for the Extension
Following is the implementation of the column transform. It simply checks to see that table and column it is associated with does NOT have a bigger value in the target table. If it doesn’t, then it assumes that it is safe to update the generator to the current id value. Note that it gets the name of the generator from the transform expression. This will need to be configured when the transform is setup on the target table(s).
Now we have a registered column transform extension that we can use. It is time to setup the transform on a table. For this example, the table transform is going to be on the NOTE table. We will assume that the NOTE table has already been configured to synchronize. Use the Auto Create button to select the NOTE table. We are using an IMPLIED table transform which means all of the columns that are not explicitly named will be passed through.
Next we need to edit the table transform to make the transform a LOAD transform. LOAD transforms execute on the target node. EXTRACT transforms execute on the source node.
Finally, we need to add our column transform on our ID column. Select the table transform and press the Edit Columns button. Add a column and select ID for the source and target columns. Drop down the transform type and select our custom transform. The custom transform expects the transform expression to be the name of the generator.
Add the Custom Column Transform
At this point, everything is configured. It is time to test!
This has been another example of the flexibility of SymmetricDS. The exact same pattern can be used to keep Oracle and Postgres sequences in sync.