Can XPe SP1 and SP2 co-exist on the same development machine?

  • Thread starter Thread starter Mark K Vallevand
  • Start date Start date
M

Mark K Vallevand

The boss says XPe SP1 for product A, and XPe SP2 for product B.

I have one workstation. Can I have both SP1 and SP2 on it?

When SP2 is installed, are the SP1 components overwritten or removed from
the database? (I don't think so.) Maybe I can be selective about upgrading
components in the product A SLX file and keep it at SP1.

Advice is greatly appreciated.
 
Mark,

Good question.

SP2 is installed on the top os SP1. It adds more Repositories.
But as we all know, there is no way from TD to choose an old version/revision of a component.
You can build your SP1 configuration with SP2 tools&db if you don't upgrade the configuration and component it it. So, basically, if
you don't plan to make any changes in SP1 configuration (like installing QFEs and etc.) you may still be ale to build it with SP2.

Also some issues that you won't be able to easy fix if you want to have both SP1 and SP2 installed separatly:
- INF importer dll was changed in SP2. Inf importer is a registered COM object so you will have to choose one version for both
SP1 and SP2.
- I don't know if it is possible to change the XPe Database name the ToolKit uses. It seems currently to be hard-coded as Mantis
db. You can rename the SP1 database (with SQL Enterprise Manager, e.g.) temporarily but it is always a pain.
- Repositories have to be maintained and renamed manually each time you switch between SP1/SP2.

Anyway, this is just thoughts. I haven't actually having both SPs on the same machine to be able to build SP1 and SP2 projects.

KM
 
Hi Mark,

1. Stop DB.
2. Duplicate SP1 folder named "Windows Embedded Data" to let say WEDBKP folder name.
3. Install SP2.

Make a batch file that will do following.
1. Stop DB.
2. Close net share on Repositories.
3. Rename "Windows Embedded Data" to let say WEDBKP2
4. Rename WEDBKP to "Windows Embedded Data"
6. Rename WEDBKP2 to WEDBKP
7. Start net share on Repositories.
8. Start DB.

Regards,
Slobodan
 
Hi Mark,

1. Stop DB.
2. Duplicate SP1 folder named "Windows Embedded Data" to let say WEDBKP folder name.
3. Install SP2.

Make a batch file that will do following.
1. Stop DB.
2. Close net share on Repositories.
3. Rename "Windows Embedded Data" to let say WEDBKP2
4. Rename WEDBKP to "Windows Embedded Data"
6. Rename WEDBKP2 to WEDBKP
7. Start net share on Repositories.
8. Start DB.


Hi, Slobodan

There is some information about the database in the system databases too,
so maybe instead of stopping the server and swapping the .mdf and .ldf
files underneath it, it could be safer to detach one version and attach the
other.

This can be done from a batch file too, through oqsl.exe (in the SQL Server
installation path, .\80\Tools\binn subdirectory).

osql -E -Q "sp_detach_db 'MantisSQLDB'"
2. Close net share on Repositories.
3. Rename "Windows Embedded Data" to let say WEDBKP2
4. Rename WEDBKP to "Windows Embedded Data"
6. Rename WEDBKP2 to WEDBKP
7. Start net share on Repositories.
set f1=X:\Windows Embedded Data\MantisSQLDB_Data.mdf
set f2=X:\Windows Embedded Data\MantisSQLDB_Log.ldf
osql -E -Q "sp_attach_db 'MantisSQLDB', '%f1%', '%f2%'"

I used environment variables for the filenames only to shorten the last
command line, so it's not broken in this post by the time you read it.



There's one drawback: sp_detach_db will fail if the database is still open
somewhere, and checking the return value in a single line sounds easier
than it is.

I thought executing the command as

osql -E -Q "exit(exec sp_detach_db 'MantisSQLDB')"

should store the result in %errorlevel%, but it looks like that doesn't
work with stored procedures (I always get errorlevel = -100).

Maybe we could ask for help in one of the SQL server groups ;)
 
Hi Lucvdv,

You are right that this look like better approach. But my DB knowledge is very limited and I'm not too eager to improve it soon.
(too high level for my taste).

Regards,
Slobodan
 
I just noticed this in the SP2 Rel.Notes: "Dual installations of the database are not supported, whether on the same or different
drives or partitions."

KM
 
Back
Top