Creating Databases On Network Drives?

Jul 11, 2001

Is this possible? I seem to remember doing it with SQL Server 7 a long time ago. The Microsoft Knowledgebase says it's not possible with 4.2 through 6.5, but nothing about 7.0 and up.

View 2 Replies


ADVERTISEMENT

Problem With Xp_cmdshell ,BCP And Network Drives

Sep 27, 1999

Basically what I am trying to do is run bcp from within a stored procedure in SQL 6.5.
It allows me to dynamically assign the destination filename (the legacy application expects to see a file for each picking slip) I want to store the file on another server/shared directory on the LAN

Here is the code
DECLARE @ship_no varchar(16)
SELECT @ship_no = '1234567'
DECLARE @SQL_SYNT varchar(255)
SELECT @SQL_SYNT = "master.dbo.xp_cmdshell " + '"BCP AUSTCHAR..armaster out servernameBECpsqlout'+@ship_no+'.cba /c /t , /r /Sservername /Uuser /Ppassword"'
EXEC( @SQL_SYNT)

However I get the following output:

(1 row(s) affected)


(1 row(s) affected)

output
---------------------------------------------------------------------------------------------------------------------------------------------
DB-LIBRARY error:
Bcp: Unable to open host data-file.

The destination file is not created.
I have tried:
making the path the local HDD that works:
Using a mapped drive, that does not work
Running the same bcp command from the command line. That works.
Using UNC's (as above) You can see the result.
I have also checked security and made SQLexecutive ran as the domain admin. Did not work.


Can Anyone help?

Thanking you in advance

View 1 Replies View Related

Writing To Network Drives From SQLServer

Apr 23, 2008

I am having difficulty getting both xp_cmdshell and the Scripting.FileSystem to work via sp_OACreate/sp_OAMethod with files residing on network drives . I am able to create/move/copy/delete files on local drives through both of these methods, but when I specify a network drive as the target an operation requiring write access I get an "Access is Denied" error. I recognize that the SQLServer service account is being used to perform these operations, and I have granted Full control permissions to this user on the directory I'm trying to perform the operation on. Is there some other permission either on the SQLServer or Windows account that is required to enable write access from T-SQL?

--Listing of network directory works fine:

EXEC xp_cmdshell 'dir \Gol-devftprootgolsolgolEngMaint';
GO
Volume in drive \Gol-devftproot has no label.
Volume Serial Number is 5493-88CD
NULL
Directory of \Gol-devftprootgolsolgolEngMaint
NULL
04/23/2008 12:37 PM <DIR> .
04/23/2008 12:37 PM <DIR> ..
03/28/2008 01:56 PM <DIR> 40083388
04/23/2008 12:37 PM <DIR> 4008343A
04/23/2008 11:05 AM 230 4008343a.task
12/18/2007 12:15 PM <DIR> 4008CE92
04/23/2008 08:41 AM <DIR> 4008D108
04/22/2008 06:40 PM <DIR> 4008D134
04/21/2008 02:46 PM <DIR> 4008D15D
03/05/2008 10:14 PM <DIR> 4008D1BA
02/12/2008 04:41 PM <DIR> 4008D1FA
10/29/2007 11:06 PM <DIR> 4008D583
04/21/2008 02:41 PM <DIR> CMU
04/22/2008 02:25 PM 313 ESN_All.task
09/05/2007 11:22 AM <DIR> HotSpot
04/23/2008 07:25 AM <DIR> M4008CEC7
04/23/2008 07:56 AM <DIR> M4008D1BC
04/22/2008 05:24 PM <DIR> M4008D1CF
04/21/2008 02:43 PM <DIR> MEU3
04/21/2008 02:43 PM <DIR> Tools
2 File(s) 543 bytes
18 Dir(s) 25,083,801,600 bytes free


-- Local copy works fine...
EXEC xp_cmdshell 'COPY C:TestLoad4008D1FA4008D1FA.TASK C:Temp';
GO
1 file(s) copied.


-- Copy to network drive fails
EXEC xp_cmdshell 'COPY C:TestLoad4008D1FA4008D1FA.TASK \Gol-devftprootgolsolgolEngMaint';
GO

Access is denied.
0 file(s) copied.

View 8 Replies View Related

Setup And Upgrade :: Users With Sysadmin Role Can't Access Network Drives

Oct 12, 2015

When I create logins for SQL Server 2012, something strange happens. When I assign the sysadmin role to a login, the login loses the access to the network drives (for example when creating or attaching databases). The only possible place is the c:drive of the computer that is running SQL Server.

View 11 Replies View Related

Installing Databases To Different Hard Drives.

Apr 24, 2006

Can't find anything on how to install to drives other than sys. I'm brand new to Servers and Databases in general and trying to learn. How do I get databases to install on drive partitions other than my main system drive?

View 5 Replies View Related

Creating Indexes On Physically Separate Drives

Apr 25, 2000

I'll be running SQL v7.0 with raid level 0. The DB will have approx. 250 tables and 1200 indexes.
Can you have the indexes located on a physically separate drive with SQL v7.0 and would this be the best practice?

View 1 Replies View Related

Synchronize Databases Over Network

May 8, 2008

Hi,

I have the following scenario:
There are 3 web applications in a local network which all have a local copy of the same database. Each of them can alter their local database (just the data, not the structure), and every time that happens the databases of the other applications should be updated immediately.
Are there any solutions out there for that? I found that most tools like slony only mirror one master database to multiple slaves, but I want every database to be able to be the starting point.
There could also be a central sync server, like in subversion..

Greets,
Patrick

View 3 Replies View Related

Synchronize Databases Over Network

May 13, 2008

Hi,

I have a scenario which I need to implement at my work.

I need to maintain one Central SQL Server DB and multiple non central SQL Server DBs at different locations. Here the same DB schema is maintained at Center & non Central SQL Servers. The requirement is: each non central DB has to synchronize with the central DB and has to update the Central DB with the changes made locally.

Here the challenge is the intermittent connectivity between the DBs. The connection is not guaranteed to be alive 24 hours a day. It may go down frequently also. I would like to know the possible ways to handle my situation (i.e. synchronization). And also please suggest me if there is any support with the SQL Server DB itself.

Thanks,
Kishore

View 3 Replies View Related

Listing SQL Server Databases On A Network

Dec 7, 2005

I would like to provide users of a client program a list of databases on thenetwork that match a certain pattern, like "%frp%". I have seen a list ofdatabases in the Windows XP ODBC configuration tool. What I would like toknow is can I get that information through a query to one of the databases,or is there a control or application on the client machine that I can callto get the list?Does the thread "Databases not showing up in Enterprise Manager" refer towhat I am trying to do?Best regards,Steve Caldwell

View 5 Replies View Related

Copying Detached Databases Over The Network With T-SQL

Jul 25, 2006

I have a T-SQL script which deataches and attaches the database. Now here is what I want to do:
I
want to create a SQL Server Job and schedule it to run at a particular
time of the month to Detach all the databases on my local machine and
*Copy all the deatched databases over a network machine* and then
Attach those Database.

All this should be done in T-SQL. I
already have the T-SQLs for Attaching and Detaching. All I need is to
know the T-SQL (example) which will copy the *Detached Databases* from
mu local computer to my Network Computer. How do I achieve that?

Thanks

View 7 Replies View Related

Creating A Database On A Network Path

Aug 9, 2006

When I try to create a new database on a network path, I get the following error:

"\server est estdatabase.mdf" is on a network path that is not supported for database files.

Am I trying something that isn't possible? Should databases always be stored on the server PC running SQL (Express)?
I'm using Visual Basic Express and SQL Express (installed on a local PC not the server, so the connectionstring is ".SQLEXPRESS"), TCP/IP is enabled.


Regards, EBA

View 4 Replies View Related

Creating A Semaphore File On A Network Drive

Jul 11, 2007

Good Morning,



I'm hoping that someone can help me. I have a SQL 2005 SSIS package that will run Friday mornings to empty/load a table with data from another database. On Friday evenings I'll need to run another package, but want to make sure the table load completed prior to launch. For this I planned to use a file watcher task, however I cannot for the life of me figure out how to output a 'done' semaphore, from the morning job, to a networked drive.



A file system task will not work because there is not a 'create file' option. I do not have an existing file that I can rename either.



I tried an execute process task running cmd.exe with the following argument:


Code Snippetecho Done> \NetworkedServerftprootLoad.Done

This fails because UNC paths are not recognized. (The package executes from another server so I cannot use a local path, nor am I allowed to set-up a local share.)



Can someone offer an alternative suggestion? I'm really hoping this is easier than I'm making it.



Thank you in advance,

Roger



View 3 Replies View Related

Trouble Backing-up All Databases To Network Folder Using A Maintenance Plan

Oct 10, 2006

I have set up a Database Maintenance Plan that does a nightly backup of all of my databases (about 12 of them) to a network folder. The plan works for about 95% of the job, but most nights there will be at least 1 database which will fail with the following error...
BackupDiskFile::RequestDurableMedia: failure on backup device '\myfileserverBackupSQLDatabaseDatabaseNameD atabaseName_db_200610081749.BAK'. Operating system error 64(The specified network name is no longer available.).
I know that this is not a permission or storage problem, because it works for most of the job. And a database that fails one night, may work fine the next night only to have a DIFFERENT database fail that night, and sometimes all databases work 100%.

Is there a way to fix this problem? And if not, is there a way to be notified of which specific database in the maintenance plan is failing. The message on the job itsself is very non-descriptive and I have to manually search the logs to find out which databases were successful & which where not. It is very time consuming. Any help with this would be greatly appreciated.

View 5 Replies View Related

Can't Map Other Sql Servers Without Creating Alias With Port Number On Client Network

Aug 24, 2005

I can't map other sql servers without creating alias with proper port number on client network utility. Other users using same version of the client tools, MMC, SQL DMF etc. I need to map 70 sql servers on using my client tools.
Any help is appreciated.

thanks,

View 3 Replies View Related

Creating Databases

Nov 2, 2004

Ok I have the Sql all written and I was going to use MYSql but it wasn't working. I was told that MSSQL worked with the files but I can't for the life of me figure out how to use it. I installed the desktop version so it is running but now how do I create and edit databases and tables and so forth. Help is greatly apprieciated as the only other sql I have done is for php forums. Thanks and If you could tell me if I need to download another program to do it graphically or something that would be awesome.

EDIT: I am using Windows Server 2003 Enterprise if that makes any difference. ISS 6.0 (kind of understand some of it)

View 1 Replies View Related

Creating Databases On The Fly

Jun 29, 2006

hello,

i am trying to create a database by using a store procedure. This stored procedure takes two input parameters. i want to assign these parameters to the 'Filename' attributes when i'm creating the database both for the .mdf and .ldf files. However i keep getting an error.

These work -------
FILENAME ='c:program filesmicrosoft sql servermssql$sardonyxinstancedataSardonyxrioctes tdblog.mdf',

FILENAME ='c:program filesmicrosoft sql servermssql$sardonyxinstancedataSardonyxrioctes tdblog.ldf',

These do'nt work--------
FILENAME = @Databasepath,
FILENAME = @Databaselogpath,

Here is my code:
---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
CREATE PROCEDURE rico_dbasescript
@Databasepath varchar(100) = 'c:program filesmicrosoft sql servermssql$sardonyxinstancedataSardonyxrioctes tdb.mdf' , @Databaselogpath varchar(100)= 'c:program filesmicrosoft sql servermssql$sardonyxinstancedataSardonyxrioctes tdblog.ldf'
AS
IF EXISTS (SELECT name FROM master.dbo.sysdatabases WHERE name = N'Sardonyxrioctestdb')
DROP DATABASE [Sardonyxrioctestdb]



CREATE DATABASE Sardonyxrioctestdb
ON
( NAME = 'Sardonyxrioctestdb_dat',
FILENAME = @Databasepath,
--FILENAME ='c:program filesmicrosoft sql servermssql$sardonyxinstancedataSardonyxrioctes tdb.mdf',
SIZE = 10,
MAXSIZE = 50,
FILEGROWTH = 5 )
LOG ON
( NAME = 'Sardonyxrioctestdb_log',
FILENAME = @Databaselogpath,
--FILENAME ='c:program filesmicrosoft sql servermssql$sardonyxinstancedataSardonyxrioctes tdblog.ldf',
SIZE = 5MB,
MAXSIZE = 25MB,
FILEGROWTH = 5MB )
GO


I am still researching my problem but i would appreciate any help. Thanks guys.

JamaicanGuy
**I am a newbie .net developer.
Jah Bless!!!!!!!!!!!!

View 1 Replies View Related

Creating Databases

Oct 13, 2007

When i create a database and later on want to add a file in it

Alter database db1
Add File
(Size = 2MB,
Maxsize = 5MB,
Filegrowth = 20%)

this gives me an error because there's no filename.
I would like to know if filename is mandatory?
Thanks as i got an error when running saying no filename.

View 2 Replies View Related

Creating Over 100-databases.

Apr 21, 2007

Hi,

I'm using SQL Server 2005 Express for an application.



SQL Server 2005 Express supports 4GB user data per database. Because need over 4GB(may be 20GB ~ 30GB) data space, I should split database which each max size up to 200 MB. And create 100 databases.



Is it reasonable? If true, what about the performance or system's overhead?



Thank you.

View 1 Replies View Related

Creating Databases Under Master

Mar 20, 2007

 When creating databases is it a good idea to use the master.dbo.sysdatabases database and then create databases under this.

View 4 Replies View Related

Creating Databases From .mdf File?

Apr 23, 2001

how do you create a database from an .mdf file?

View 2 Replies View Related

Creating Reporting Databases

Sep 11, 2002

I have a reporting server with 5 databases which are currently being updated via log shipping. These databases need to be (read) accessed by the users. All users have System Admin perms due in order to access the databases. I need to tighten security on the server and remove SA perms from the users. The largest database is about 8gb and is growing slowly. What is the best way to move the databases efficiently from the source server to the reporting server? The log shipped databases can't be backed up and restored due to the standby mode. DTS is an option but may pose time issues due to database size especially as the databases grow in the future. Replication is another option but i have heard it has alot of issues. Any help is welcome. Thanks.

View 2 Replies View Related

Creating Duplicate Databases Daily

Nov 6, 2005

I want to be able to create a duplicate database and update / refresh it daily automatically. This database copy would be used for testing purposes so I don't want it to write back to the original database. Is replication of some kind the answer?

View 4 Replies View Related

Changing 'Filename' Attri. When Creating Databases

Jul 13, 2006

Obadiah writes "hello,

I am a newbie to developing .net applications unfortunately my boss and my colleaques think i am a pro (interview went too well) and i would like to get at least this months paycheck before am fired....so i here's my dumb question:

I want to create a SQL database from my vb.net application using stored procedures, however i want to be able to set the Filename attribute ('Filename = C:Program FilesMicrosoft SQL ServerMSSQL$SARDONYXINSTANCEData estdb.mdf') by means of a input parameter to the stored procedure. like so...
Filename = @databasepath.

HERE is what i have:
------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
CREATE PROCEDURE rico_dbasescript
@Databasepath varchar(100) = 'c:program filesmicrosoft sql servermssql$sardonyxinstancedataSardonyxrioctestdb.mdf' , @Databaselogpath varchar(100)= 'c:program filesmicrosoft sql servermssql$sardonyxinstancedataSardonyxrioctestdblog.ldf'
AS

IF EXISTS (SELECT name FROM master.dbo.sysdatabases WHERE name = N'Sardonyxrioctestdb')
DROP DATABASE [Sardonyxrioctestdb]



CREATE DATABASE Sardonyxrioctestdb
ON
( NAME = 'Sardonyxrioctestdb_dat',
FILENAME = @Databasepath,
--FILENAME ='c:program filesmicrosoft sql servermssql$sardonyxinstancedataSardonyxrioctestdb.mdf',
SIZE = 10,
MAXSIZE = 50,
FILEGROWTH = 5 )
LOG ON
( NAME = 'Sardonyxrioctestdb_log',
FILENAME = @Databaselogpath,
--FILENAME ='c:program filesmicrosoft sql servermssql$sardonyxinstancedataSardonyxrioctestdblog.ldf',
SIZE = 5MB,
MAXSIZE = 25MB,
FILEGROWTH = 5MB )
GO


The above procedure works fine when Filename = 'c:program filesmicrosoft sql servermssql$sardonyxinstancedataSardonyxrioctestdb.mdf'
but bombs out when Filename = @Databaselogpath.

Thank you in advance."

View 2 Replies View Related

Creating Multiple Databases From A Single Backup F

Nov 9, 2006

Hi,
I want to create two databases by restoring from a
single backup file in sql server. I am using 2005-sqlexpress .Is it possible?

Thanx in advance..

View 3 Replies View Related

Alternative To Creating View With Union In Two Databases?

Jul 20, 2005

I attempted to create a view in SQL Server 2000 that Unions twoqueries. The first part of the query gets data from the local server,the second part gets info from a linked server. (The query works finein Query Analyzer.)I received this error when I tried to save the query:ODBC error: [Microsoft][ODBC SQL Server Driver] The operation couldnot be performed because the OLE DB provider 'SQLOLEDB' was unable tobegin a distributed transaction.[Microsft][ODBC SQL Server Driver][SQL Server][OLE/DB providerreturned message: New transaction cannot enlist in the specifiedtransaction coordinator.]After a little reading I discovered the "Database limitation":"A view can be created on a table only in the database the viewcreator is accessing".That's my problem... is there a simple solution or alternative tocreating a view?Thanks,Matt

View 2 Replies View Related

Creating A Query That Access Multiply Databases

Dec 10, 2007


Dear Readers,
Is it possible to create a query that access multiple sql express databases? Or is it possible to link a table in one database from another?

View 1 Replies View Related

Errors Creating Databases (visual Studios)

Apr 14, 2008

I have VB2008 express edition and SQL server 2005. When i try to create a new local datasource in my project, the datasource seems to be created just fine however an error message comes up. If i try to create the datasource by selecting it on the 'add new item' menu, an error message says

"The data provider required to connect to the local data file could not be found. The file will be added to the project but the typed Dataset associated with the project will not be created."

If I try to create the datasource by selecting 'add new datasource' from the datasources pane, i can create the connection to a new or existing database but when i click next to proceed to the page defining the dataset, an error message says

"An error occured while converting this connection:
Data provided identified by guid ' 7c602b5b-accb-4acd-9dc0-ca66388c1533 ' could not be loaded"

PLEASE HELP!!
I have no idea how to fix it

thanks,
jordan

View 3 Replies View Related

Creating User And Giving Permission To All Databases

Feb 27, 2008



Hi,

Any body please give me some TSQL Stored procedure for

creating an SQL user and to give db access permission to all the databases available on a the server.

Mujeeb

View 5 Replies View Related

Creating Databases On WinXP SP2 With SQL Server 2005 CE RC

Nov 28, 2006

Hi,

For various reasons a new desktop application I am developing is using the SQL Server 2005 Compact Edition Release Candidate to store local data. On my development machine (XP SP2, VS2005, SQL Server 2005 Developer Edition) the software is able to create the database file, and read and write to it fine.

However on our test machine, which does not have any of the development tools the software is unable to create the database. A System.Data.SqlServerCe.SqlCeException is thrown. The message is: "SQL Mobile usage is restricted on this platform. To use SQL Mobile, you must install SQL Server 2005, Visual Studio 2005, or the Tablet PC SKU." Obviously this goes somewhat against the blurb for SQL Server CE.

Is this something that will be fixed shortly? Or is it the intention that databases can't be created on machines that do not SQL Server or Visual Studio installed? (Incidentally the reason for creating the database on the fly is that we are encrypting it, using the users credentials, so that only they can open the database.)

Thanks, Steve

View 4 Replies View Related

Creating Report Based On Multiple Databases?

May 6, 2008

My application uses 2 databases from 2 different server. When i create a report model in business intellegence development studio I can only create 1 datasource for each database, and 1 datasource view for each datasource. Then when I create a new report, I can only use one datasource.

Is it possible that my report can be built on more than one databases?

thanks in advance

View 4 Replies View Related

Creating Relational Databases(Primary/Foreign Key?)

Jul 16, 2007

Hey everyone,
I have just started getting into to SQL and am completely brand new to the whole concepts of relational databases. Someone on this forum pointed to the MSDN videos on LEARNVISUALSTUDIO.NET which have been very helpful. Unfortunately while learning about relational databases and looking at the program that I want to design and make using them, I have run into a pretty big wall, concerning the primary key and foreign key.
For my program, I am trying to save an object, and lets say the base class is SLIDE. Now SLIDE will store basically most of the information that I will ever want to store, such as timeCreated and mainText and slideID(primarykey). But there are other classes that derive from slide that will store just a bit more information than that because of what they are. Lets say there is a class derived from SLIDE called PERSON that stores its parentNode, which is to say something that this slide specifically belongs to and has a reference to. Now the tricky part is that in this program, every single slide can have a reference to another slide, that you would see displayed and that you could just click on and view if you wanted to.
Now relating what I just told about the classes in my program to a relation database standpoint is what confuses me. If I make a table SLIDE, it would hold incomplete data about the PERSON object, because that object has more data than SLIDE has. The answer to this was to make another table called PERSON, which would have more columns. But now we arrive at the big problem: The primary key called maybe SLIDEID would be different in this new PERSON table than in the other table called SLIDE (or any other derived class). Therefore the link between these tables is messed up. In my object orientated mind I am thinking of static class variables that would still stay constant for derived classes, so that when I make a PERSON slide it will increment off of the primary key of the SLIDE table. In other words, is there some sort of super TABLE that you can derive from, like an abstract class, where the primary keys of other tables can build off of because they will be used as the same type of reference to eachother.
If none of this made sense to the reader, I am greatly sorry. I do not really know what else I can say to convey to you the problem I have. Maybe its because I am so used to object orientated languages that this is making it so difficult to explain. If however you do understand what I am talking about, please think about it and help me find a solution to this problem. I am not an experienced programmer, but I do very much enjoy it and I am very excited about starting to make this program, and I have learned that before I start coding it is very important to have a very firm design in mind first.
Thank your for reading,
Jeremy

View 5 Replies View Related

Creating Multiple Databases Running Off The Same Data Engine

Aug 23, 2005

Hi, I have looked and loked for the answer to this question and made no progress.  I want to install MSDE on one of our servers, however, when I went to install it, I found that there was another MSDE already installed and running (it was an agent running with our backup software Veritas).  Is it alright to create another database and have 2 running simultaneous on the same data engine?  Is there any type of limitations that I sould know about - such as number of allowed accesses at one time?  Any help is greatly appreicated.

View 1 Replies View Related

Creating Databases Under MS SQL 2005 Server (SP-2): Dbo User Role

Jun 9, 2007

Good Day,



I am having a problem with creating databases in MS SQL 2005 Server. When I attempt to assign an User Mapping for my SQL user account to the newly created database, the "dbo" user and schema is already assigned. When I try to drop this user in favor of my own, I receive an error message: Cannot alter the user "dbo" (Microsoft SQL Server, Error: 15150). I am connected to my database engine through the "sa" account.



Regards,

Keith

View 6 Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved