StrataFrame Forum
Home      Members   Calendar   Who's On
Welcome Guest ( Login | Register )
      



DDT Data Deployment ErrorExpand / Collapse
Author
Message
Posted 02/11/2007 2:48:41 PM
StrataFrame User

StrataFrame UserStrataFrame UserStrataFrame UserStrataFrame UserStrataFrame UserStrataFrame UserStrataFrame UserStrataFrame User

Group: StrataFrame Users
Last Login: 2 days ago @ 4:06:22 PM
Posts: 313, Visits: 1,274
I wrote a database installer DLL to deploy the role based security files, based on the installer example on the forum. (DataProgress)

In my AppMain I added some code to check if the security database exists. If not, I automatically call the installer DLL.

Everything works perfectly when I run my application within visual studio, however, When I run the exe, I get the attached error.  The error occurs at the start of the data deployment phase.  The meta data is deployed without errors.

Any idea why this is happening?

Thanks

Tim

  Post Attachments 
DeployError.png (36 views, 24.55 KB)

Post #6700
Posted 02/11/2007 3:18:09 PM
StrataFrame User

StrataFrame UserStrataFrame UserStrataFrame UserStrataFrame UserStrataFrame UserStrataFrame UserStrataFrame UserStrataFrame User

Group: StrataFrame Users
Last Login: 2 days ago @ 4:06:22 PM
Posts: 313, Visits: 1,274
I took the sample installer project on the forum to see if the same issue exists. I changed the package name  and password to match my deployment package.

Everything worked fine when I ran the project from within visual studio, however when I ran the exe the same error popped up.

Tim

Post #6701
Posted 02/12/2007 1:48:29 PM


StrataFrame Developer

StrataFrame Developer

Group: StrataFrame Developers
Last Login: 10/21/2008 9:20:58 AM
Posts: 2,685, Visits: 1,887
I have no idea why you would be getting this error at runtime and not design-time.  All of the foreign keys on the tables within the database are disabled before the data is deployed and then re-enabled after the data deployment has completed.

It is possible that this could be a timing issue between the runtime versions and the debug version through Visual Studio.  Are you waiting until the completed event has been fired after deploying the meta-data before you call DeployData()?


www.bungie.net
Post #6732
Posted 02/12/2007 2:12:28 PM
StrataFrame User

StrataFrame UserStrataFrame UserStrataFrame UserStrataFrame UserStrataFrame UserStrataFrame UserStrataFrame UserStrataFrame User

Group: StrataFrame Users
Last Login: 2 days ago @ 4:06:22 PM
Posts: 313, Visits: 1,274
Yes, the StartDataDeploymentPhase() is called after the buildcomplete event is fired.
Post #6738
Posted 02/13/2007 9:24:14 AM


StrataFrame Developer

StrataFrame Developer

Group: StrataFrame Developers
Last Login: 10/21/2008 9:20:58 AM
Posts: 2,685, Visits: 1,887
The only thing I can think to tell you is to make sure that the foreign keys are actually being turned off... since you're building the SF source code in debug, you can open the DatabaseMigrator file within the MicroFour StrataFrame DBEngine project and add a message box to the TurnOffAllForeignKeys() method to show the value of the DatabaseName parameter.  When you run, you should then get the message boxes for each database that is being included in the deployment.  If a database isn't included, then the foreign keys aren't being turned off and we have a problem somewhere.


www.bungie.net
Post #6753
Posted 02/14/2007 9:10:53 PM
StrataFrame User

StrataFrame UserStrataFrame UserStrataFrame UserStrataFrame UserStrataFrame UserStrataFrame UserStrataFrame UserStrataFrame User

Group: StrataFrame Users
Last Login: 2 days ago @ 4:06:22 PM
Posts: 313, Visits: 1,274
Ben, I haven't had time to dig into this any further but I have run my deployment routine about 20 times so far and it seems to be hit and miss, sometime it works and sometimes I get the error.  After the error, I delete the Database and run the deployment again and it works fine.  Just thought I would pass this on in case it triggers something.

Thanks,

Tim

Post #6786
« Prev Topic | Next Topic »


Reading This TopicExpand / Collapse
Active Users: 0 (0 guests, 0 members, 0 anonymous members)
No members currently viewing this topic.
Forum Moderators: Ben Chase, Trent L. Taylor, Steve L. Taylor

PermissionsExpand / Collapse

All times are GMT -6:00, Time now is 2:39am

Powered by InstantForum.NET v4.1.4 © 2008
Execution: 0.078. 12 queries. Compression Enabled.
Site Map - Home - My Account - Forum - About Us - Contact Us - Try It - Buy It

Microsoft, Visual Studio, and the Visual Studio logo are trademarks or registered trademarks of Microsoft Corporation in the United States and/or other countries.