Transactions covering multiple databases?


Author
Message
Sam Tenney
Sam Tenney
StrataFrame User (140 reputation)StrataFrame User (140 reputation)StrataFrame User (140 reputation)StrataFrame User (140 reputation)StrataFrame User (140 reputation)StrataFrame User (140 reputation)StrataFrame User (140 reputation)StrataFrame User (140 reputation)StrataFrame User (140 reputation)
Group: StrataFrame Users
Posts: 70, Visits: 3.5K
I am trying to learn what the StrataFrame Application Framework can accomplish in a rather complicated proposed application.  I am confused about transactions.  The application will have multiple SQL tables in Multiple databases but they are all housed in a single SQL server.  I will be using SQL Server 2008.

I will have a need to save changes to several different tables in several different databases all within a single transaction of some sort.  If any optimistic concurrency conflict occurs in any of the tables in any of the different databases, I want to roll back all attempted changes in all tables in all databases.

My research on the internet indicates that transactions will not work across multiple databases.  Does StrataFrame have a way of handling this scenario?  Will I need to write my own code based on my own solution, or can StrataFrame handle this out of the box?

Sam

Replies
Sam Tenney
Sam Tenney
StrataFrame User (140 reputation)StrataFrame User (140 reputation)StrataFrame User (140 reputation)StrataFrame User (140 reputation)StrataFrame User (140 reputation)StrataFrame User (140 reputation)StrataFrame User (140 reputation)StrataFrame User (140 reputation)StrataFrame User (140 reputation)
Group: StrataFrame Users
Posts: 70, Visits: 3.5K
Thanks Edhy.

I appreciate the time it took to give me these ideas.  Are you aware of anybody actually using a transaction across multiple databases with StrataFrame?  I am only a beginner and it will take me some time to absorb everything you suggested, but based on the little bit I know now, I am not sure yet if your ideas will work.  If I ever figure it out, I will let you know what I found.

Sam

Edhy Rijo
E
StrataFrame VIP (6.4K reputation)StrataFrame VIP (6.4K reputation)StrataFrame VIP (6.4K reputation)StrataFrame VIP (6.4K reputation)StrataFrame VIP (6.4K reputation)StrataFrame VIP (6.4K reputation)StrataFrame VIP (6.4K reputation)StrataFrame VIP (6.4K reputation)StrataFrame VIP (6.4K reputation)
Group: StrataFrame Users
Posts: 2.4K, Visits: 23K
You are welcome Sam!



Please do not get intimidated by all this, after you print it out and review it with a simple sample project you will see it is really easy.



I have not worked with SF transactions working with multiple databases. I have used them with a single database, but based on the parameters used by the transactions methods, you need to pass the DataSourceKey which will internally identify which connection the BO will use.



I suggest you create a simple form with 2 tables using 2 databases and test your scenario. I currently don't have time to get into building that sample, but the whole experience will help you understand SF and what I have found working with SF is that most of the SF approach to solve developers problems are much simpler than what it looks like, of course in your case being new to SF it may take you longer, but the faster you start and post back any block road, the faster any of us will help you out. Hehe

Edhy Rijo

Greg McGuffey
Greg McGuffey
Strategic Support Team Member (4.8K reputation)
Group: Forum Members
Posts: 2K, Visits: 6.6K
I'm checking with the SF developers on this. Hopefully I get an answer tomorrow.
GO

Merge Selected

Merge into selected topic...



Merge into merge target...



Merge into a specific topic ID...





Similar Topics

Reading This Topic

Login

Explore
Messages
Mentions
Search