Monday, March 19, 2012

Connecting to MSDE w/read only file?

Hi,
Does anyone know how I can connect to an MSDE db using VB with a
read-only file? The file will be on a CD, and is actually just archived
data off a SQL server. I would like to package my app on a CD along
with the data file and allow users to pop in the CD and run the app,
assuming they already have MSDE running. Any help?

Thanks,
Jasonhi Jason,
"Jason" <jnorsworthy@.etrade.com> ha scritto nel messaggio
news:1104275382.477692.322310@.z14g2000cwz.googlegr oups.com
> Hi,
> Does anyone know how I can connect to an MSDE db using VB with a
> read-only file? The file will be on a CD, and is actually just
> archived data off a SQL server. I would like to package my app on a
> CD along with the data file and allow users to pop in the CD and run
> the app, assuming they already have MSDE running. Any help?
> Thanks,
> Jason

actually this is possible, providing you mark the database as available on
CD using system stored procedure sp_create_removable and
sp_certify_removable...
this method requires at least 3 physical files, 1 database system data file
that MUST reside on read/write device, 1 data file that will contain all
application's data and that will reside on the removable device, and 1
transaction log file...

please have a look at
http://msdn.microsoft.com/library/d...des_03_92hx.asp
--
Andrea Montanari (Microsoft MVP - SQL Server)
http://www.asql.biz/DbaMgr.shtm http://italy.mvps.org
DbaMgr2k ver 0.9.1 - DbaMgr ver 0.55.1
(my vb6+sql-dmo little try to provide MS MSDE 1.0 and MSDE 2000 a visual
interface)
--- remove DMO to reply

No comments:

Post a Comment