MS SSDE
From a command prompt, type
> Osql -S servername\instancename -E
where servername is your server's name and instancename is the database instance such as "sharepoint" (without the quotes).
Next, In order to 'detach' a database physical file, you have to disconnect the database from the database engine. Make sure the database is not in use. At the client prompt, type
1> EXEC sp_detach_db "databasename"
2> Go
Now, move the physical files to the new location. Move both the databasename.MDF and databasename_log.LDF files. Now to reattach the physical file to the database engine, and make the database available again, at the same client prompt, type
1> EXEC sp_attach_db 'databasename','C:\path\to\databasename.MDF','C:\path\to\databasename_log.LDF'
2> Go
That's it. Restart your database engine if necessary.
The sp_attach_db syntax is slightly different for the Enterprise Server version.