SQL Server Forums
Profile | Register | Active Topics | Members | Search | Forum FAQ
 
Register Now and get your question answered!
Username:
Password:
Save Password
Forgot your Password?

 All Forums
 General SQL Server Forums
 New to SQL Server Programming
 Importing ms access databse
 New Topic  Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic  

kulfi
Starting Member

Saudi Arabia
33 Posts

Posted - 02/01/2011 :  04:10:00  Show Profile  Reply with Quote
hi,
when i import a MS Access Data base from remote area like \\10.0.0.155\V-Schedule\CAD_Data_Base.mdf to mdb file why the destination place of the file is changed i want the file to stay in the same place.
thanks


Ehsan

SwePeso
Patron Saint of Lost Yaks

Sweden
30276 Posts

Posted - 02/01/2011 :  04:33:46  Show Profile  Visit SwePeso's Homepage  Reply with Quote
Because SQL Server has no artificial intelligence to guess where you want to save your files.



N 56°04'39.26"
E 12°55'05.63"
Go to Top of Page

kulfi
Starting Member

Saudi Arabia
33 Posts

Posted - 02/01/2011 :  06:11:11  Show Profile  Reply with Quote
OK than if i go to C:\Program Files\Microsoft SQL Server\MSSQL10.SQLEXPRESS\MSSQL\DATA\*.mdf the saved file
can i copy or move the file to the remote area where i want this file to be, i tried several times the file can not be copied due to a permission denied please can u tell me how can i solve this problem and put the files the required folder.
thanks

Ehsan
Go to Top of Page

SwePeso
Patron Saint of Lost Yaks

Sweden
30276 Posts

Posted - 02/01/2011 :  07:01:12  Show Profile  Visit SwePeso's Homepage  Reply with Quote
Give your user access/permissions to create files in "C:\Program Files\Microsoft SQL Server\MSSQL10.SQLEXPRESS\MSSQL\DATA\".


N 56°04'39.26"
E 12°55'05.63"
Go to Top of Page

kulfi
Starting Member

Saudi Arabia
33 Posts

Posted - 02/01/2011 :  07:08:26  Show Profile  Reply with Quote
Hi, Please try to understand there is no usetname and password for the file, windows authenification is used and what i want to know is that why the file is saved on this address i did not provided this address.
thanks

Ehsan
Go to Top of Page

SwePeso
Patron Saint of Lost Yaks

Sweden
30276 Posts

Posted - 02/01/2011 :  07:31:09  Show Profile  Visit SwePeso's Homepage  Reply with Quote
Please try to understand this is not a database-related problem. It is an operating system problem where all users are denied access to create files on the system partition.



N 56°04'39.26"
E 12°55'05.63"
Go to Top of Page

kulfi
Starting Member

Saudi Arabia
33 Posts

Posted - 02/01/2011 :  23:34:09  Show Profile  Reply with Quote
No i have full access on that remote Area i can copy, edit atc what i want to know is that why the file when transfered is automatically transfered to the local path sql server path while i am accessing the file from the remote area and want to save on the same remote area after importing.
thanks

Ehsan
Go to Top of Page

SwePeso
Patron Saint of Lost Yaks

Sweden
30276 Posts

Posted - 02/02/2011 :  02:06:23  Show Profile  Visit SwePeso's Homepage  Reply with Quote
Can you please post the full error message? I am guessing it includes error number 5.



N 56°04'39.26"
E 12°55'05.63"
Go to Top of Page

Ifor
Aged Yak Warrior

592 Posts

Posted - 02/02/2011 :  07:53:56  Show Profile  Reply with Quote
quote:
Originally posted by kulfi

No i have full access on that remote Area i can copy, edit atc what i want to know is that why the file when transfered is automatically transfered to the local path sql server path while i am accessing the file from the remote area and want to save on the same remote area after importing.
thanks

Ehsan



If you are connected to a local version of SQL and import remote data, the data will be placed in the local database.

If you connect to a remote version of SQL and import remote data, the data will be placed in the remote database.

ie. The data is imported into the database you are connected to.

If you want to move a SQL database, do not copy the mdf files etc, run the BACKUP command, copy the resulting .BAK file and then RESTORE the .BAK file.

Go to Top of Page

kulfi
Starting Member

Saudi Arabia
33 Posts

Posted - 02/02/2011 :  11:04:39  Show Profile  Reply with Quote
OK LET ME TELL YOU THAT THE SQL SERVER WAS RUNNING WHERE THE FILE IS BUT THE FILE IS COPIED TO LOCAL COMPUTER AFTER IMPORTING.
PLEASE LET ME KNOW WHY?

Ehsan
Go to Top of Page

Ifor
Aged Yak Warrior

592 Posts

Posted - 02/02/2011 :  11:25:49  Show Profile  Reply with Quote
You must be attached to a version of SQL on the Local computer.
Go to Top of Page

RickD
Slow But Sure Yak Herding Master

United Kingdom
3608 Posts

Posted - 02/03/2011 :  05:14:35  Show Profile  Reply with Quote
quote:
Originally posted by kulfi

OK LET ME TELL YOU THAT THE SQL SERVER WAS RUNNING WHERE THE FILE IS BUT THE FILE IS COPIED TO LOCAL COMPUTER AFTER IMPORTING.
PLEASE LET ME KNOW WHY?

Ehsan




Please read up on SQL Server and how to access the database, also read up on why you can't move the physical files while the database is attached to a SQL Server instance.
Go to Top of Page
  Previous Topic Topic Next Topic  
 New Topic  Reply to Topic
 Printer Friendly
Jump To:
SQL Server Forums © 2000-2009 SQLTeam Publishing, LLC Go To Top Of Page
This page was generated in 0.09 seconds. Powered By: Snitz Forums 2000