Simple Database Copy?
Aug 26, 2007
I've looked over the "how do I" stuff but not found a simple, straightforward to simply make a complete snapshot of a relatively small development database (perhaps 2 to 3 meg at this point) so that I can bring it to my local system (from a hosting provider) or vice-versa.
I see the info on "SQL Server Import and Export Wizard" but I don't find the functionality in SQL Server Management Studio Express -- or am I missing it?
Such a process seems obvious. It's not "replication" is it? I don't need it on an on-going basis -- just an occasional one-time thing.
Mahalos (thanks) in advance for any guidance ... :) KevInKauai
View 5 Replies
ADVERTISEMENT
Nov 18, 2005
This is the error I get with a simple Data Reader Source (SELECT * FROM A) to SQL Server Destination copy between identical tables from a linked to a local server:
View 6 Replies
View Related
May 11, 2006
Hi,
I set up DB mirror between a primary (SQL1) and a mirror (SQL2); no witness. I have a problem when I issue command:
alter database DBmirrorTest
Set Partner = N'TCP://SQL2.mycom.com:5022';
go
The error message is:
The remote copy of database "DBmirrorTest" has not been rolled forward to a point in time that is encompassed in the local copy of the database log.
I have the steps below prior to the command. (Note that both servers' service accounts use the same domain account. The domain account I login to do db mirror setup is a member of the local admin group.)
1. backup database DBmirrorTest on SQL1
2. backup database log
3. copy db and log backup files to SQL2
4. restore db with norecovery
5. restore log with norecovery
6. create endpoints on both SQL1 and SQL2
CREATE ENDPOINT [Mirroring]
STATE=STARTED
AS TCP (LISTENER_PORT = 5022, LISTENER_IP = ALL)
FOR DATA_MIRRORING (ROLE = PARTNER)
7. enable mirror on mirror server SQL2
:connect SQL2
alter database DBmirrorTest
Set Partner = N'TCP://SQL1.mycom.com:5022';
go
8. Enable mirror on primary server SQL1
:connect SQL1
alter database DBmirrorTest
Set Partner = N'TCP://SQL2.mycom.com:5022';
go
This is where I got the error.
The remote copy of database "DBmirrorTest" has not been rolled forward to a point in time that is encompassed in the local copy
Thanks for any help,
KT
View 8 Replies
View Related
Dec 26, 2007
Why isn't there some documentation on how to do this. This should be really simple and it has taken me 2 weeks and I still haven't gotten an answer. Please Help Does anyone know the answner or some place where there is some documentation!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
I get the following error when I try to substitute the strings in the databasedetails collection with variables:
Error: Object reference not set to an instance of an object. StackTrace: at Microsoft.SqlServer.Dts.Tasks.TransferObjectsTask.TransferObjectsTask.CheckLocalandDestinationStatus(Database srcDatabase, DatabaseInfo dbDetail) at Microsoft.SqlServer.Dts.Tasks.TransferObjectsTask.TransferObjectsTask.TransferDatabasesUsingSpAttachDetach()
I created the following variables:
strDestinationDB = AirCL2Exp_new3
strDestinationDBPath = C:Program FilesMicrosoft SQL ServerMSSQL.2MSSQLDATAAirCL2Exp_new3_Data.mdf
strDestinationLGPath = C:Program FilesMicrosoft SQL ServerMSSQL.2MSSQLDATAAirCL2Exp_new3_Data.ldf
strSourceDB = AirCL2Exp
strSourceDBPath = C:Program FilesMicrosoft SQL ServerMSSQL.2MSSQLDataDataNewAirCL2Exp_Data.mdf
strSourceLGPath = C:Program FilesMicrosoft SQL ServerMSSQL.2MSSQLDataDataNewAirCL2Exp_Log.ldf
I then assigned those variable to DatabaseDetails Collection:
DatabaseName = @strSourceDB
DestinationDatabaseName = @strDestinationDB
Inaddtion I also assigned the following to the two DatabaseFiles Collection:
for 0:
DatabaseFileSize = 0
DestinationFilePath = @strDestinationDBPath
FileType = DatabaseFile
SourceFilePath = @strSourceDBPath
SourceSharePath = @strSourceDBPath
for 1:
DatabaseFileSize = 0
DestinationFilePath = @strDestinationLGPath
FileType = LogFile
SourceFilePath = @strSourceLGPath
SourceSharePath = @strSourceLGPath
View 13 Replies
View Related
Nov 4, 2006
Hello,
if i have a given database (a model) and i want to copy this database in the same database instance. Is it ok to copy the mdf and ldf file and attach the files with a new database name in the same instance.
Or is the datebase name part of the .mdf file?
Regards
Markus
View 6 Replies
View Related
Oct 28, 2006
Hello I am a software developer with minimal SQL server administration skills. Currently I am using SQL Server 2000.I need to know if there is a way to copy a particular table from a database, and to copy the table into a different database.Basically on a project I am working on we are using a table named "Customers" from a database named QTR. We need to copy this database table into a different database named "Research". How can this be done? Is if very complicated?
View 1 Replies
View Related
Aug 16, 2007
Hi All,Can u please suggest me some books for relational database design ordatabase modelling(Knowledgeable yet simple) i.e. from which we couldlearn database relationships(one to many,many to oneetc.....),building ER diagrams,proper usage of ER diagrams in ourdatabase(Primary key foreign key relations),designing smallmodules,relating tables and everything that relates about databasedesign....Coz I think database design is the crucial part of databaseand we must know the design part very first before starting up withdatabases.....Thanks and very grateful to all of you....Vikas
View 3 Replies
View Related
Sep 24, 2007
Hi guys,
I've been assigned the task of setting up access to our SQL Server 2005 box. A consultant developing for us has accessing to 2 databases and I've set this up fine. It appears however that one of these databases is re-copied over to the server every night to keep data reasonably current.
I'm not interesting in changing this method as I'm not the maintainer (as yet).
Basically I would like to know if I've setup access to this database (it works fine), when the database is updated (with an SSIS package) the account seems to get deleted. Do the original permissions from the source database overwrite those of its destination?
Cheers
View 1 Replies
View Related
Nov 1, 2006
I'm using SQL Server Management Studio Express and I'm trying to figure out how to copy a table(s) from my local database to my web hosting database. I know how to do it in 2000, but it's completely different now. Is this feature not allowed on SSMSE? If so, then how do I deploy database tables to a web host?Also, how do you add local database(s) to SSMSE? I tried to use 'attach database' in SSMSE and it wouldn't allow me to navigate to My Documents folder where the database resides. Thanks...
View 8 Replies
View Related
Dec 29, 2004
If I want to copy the data from Table1 in Database A to Table2 in
Database B but Table1 column name is code , Table 2 column name is
vesselcode.
(Code = vesselcode)
How to copy all data from Table1 in Database A to Table2 in Database B ?
Do I need to write the SQL statment ? and Can I use Server Enterprise
Manager Tool?Thx a lot.
View 1 Replies
View Related
Jul 20, 2005
Hello,I need to copy a table from an 8i oracle database to a sqlserver 2000 database.Is it possible to use the command "COPY FROM ... TO ..." ?So, what is the correct syntax ?Thanks for your helpCyril
View 1 Replies
View Related
Jan 6, 2008
Hi,
I have a complicated sql server mobile database (.sdf) and need to create a SQL SERVER database with the same tables. How can I do it without scripting the whole thing? I thought of using the views.information_schema databases, but it is still a lot of coding.
thanks
View 3 Replies
View Related
Jan 31, 2006
Hi,
I am writing a simple program which runs on users xp machines and accesses a simple table on an NT Server.
In otherwords, the database consists of just a single table with perhaps 4 fields and a maximum of 200 records, with low transaction activity (users periodically update their status or check on other users' statuses).
Do I need to use SQL????
What is my best option for such a simple table / database.
Your help would be appreciated.
View 6 Replies
View Related
May 23, 2007
I thought I would start learning how to backup my SQL Server 2005 database using the simple recovery method. Using the SQL Server Management Studio I started the backup task. In the Back Up Database dialog box the Recovery Model is set to Full and disabled (grayed out). It does not give me the option to switch to the Simple Recovery Model. Is there a setting I need to adjust that will allow me to switch to the Simple Recover Model?
View 4 Replies
View Related
Dec 7, 2004
Hello,
I have a search form in an ASP.NET/VB page. The form has the input text box and the button "search". The keywords are passed in the URL to results.aspx.
Here is an example of what I get in the URL, when I write the keywords "asp", "book" and "london" in the input text box and click "search":
results.aspx?search=asp%20book%20london
The database table has 3 fields: "id", "title" and "description".
I want to display all the records where at least one of the keywords is found in any of the 2 fields "title" and "description".
1. I suppose I need to get the words out of the URL to be used by SQL.
Maybe: string[] searchString = request.queryString("search").split('search'); ???
How can i make this run when page loads? I supose i need it. Right?
2. How should the SQL look? I supose i need to use the "Like" command
SELECT * FROM books WHERE title LIKE ...
But how to I use it if I can have 1, 2, 3, ... keywords?
Can someone help me?
Thanks,
Miguel
View 1 Replies
View Related
May 13, 2008
How can I connect to another sqlserver instances using a SQL Query Analyzer command? I mean, something like this:
connect (server1.instance1, user, pass) ??
SELECT * FROM MYTABLE;
connect (server1.instance2, user, pass) ??
SELECT * FROM MYTABLE;
connect (server1.instance3, user, pass) ??
SELECT * FROM MYTABLE;
PD: I know I can click in File-->Connect-->etc..., but I want to do this with a T-SQL command
View 5 Replies
View Related
Aug 8, 2007
Hi- I have questions about mobile database limits. The application is entirely C# / Compact Framework 2.0, using VS2005. Devices we support are all running WM5. We're trying to incorporate what seems to be a large database that the application needs to talk to offline from any network, so it needs to be stored & hosted within the database and hence we started working with the various generations of what is now SQL Server Compact Edition.
In order to profile the responsiveness I worked up a test database with the general collection of fields we are interested in. The main table has 80,000 rows with one primary key and one of the numeric fields indexed. There is a 'nickname' table which contains about 150,000 items with just a string for a nickname and the key that nickname goes with. With all the rows and an alpha index for the nickname field the database is about 42 mb. Which is pushing the amount of storage on the handheld, but of our two models one is fine and one still has about 30 mb free with the DB on the handheld.
My problem seems to be that one kind of device can work with this database and one cannot. The device I was using the prototype the application is a HP iPAC hx2490b. On that device more than once I have corrupted the database, but not yet as a reproducible process.
My other device is a Dell Axim X51. On that device I seem to corrupt the database with very simple actions. Just now I tried a query like (From the Query Analyzer 3.0)
Code Snippet
Select * from ReagentNicknamesTable where alt_names like 'alpha%'
Which should hit 2099 of the 150,000 records. I got about 400 back and then the table was corrupted. On this device I cannot recover the database as there isn't enough disk space for two copies of the DB. So corruption in the field would be a showstopper. But getting corruption from a simple query like this means I really can't use SSCE.
This problem with the dell showed up when I was using the original device sql that came with VS2005. (SQL Server Mobile?) The cabs & dll's were dated from 2005 and had a build number of 3.0.5206.0. I have since updated to the current version of SQL Server Compact Edition and the dlls have build number 3.0.5300.0. The IDE is set to Compact Framwork 2.0, sp1: cgacutil reports CF 2.0.6129.0.
So help! Have I hit some listed or unlisted limits to SSCE on the Compact Framework? thanks.
View 6 Replies
View Related
Apr 24, 2008
Hi,
I tried to create a simple application based on the Sql Server CE samples and, as is typical when I play with databases, the program failed. In this case it failed to even load. The program has a form and a data source that I dropped onto the form. When I run the program the program breaks at this line:
Code Snippetthis._connection = new global::System.Data.SqlServerCe.SqlCeConnection();
The error is:
An unhandled exception of type 'System.DllNotFoundException' occurred in System.Data.SqlServerCe.dll
Additional information: Unable to load DLL 'sqlceme35.dll': The specified module could not be found. (Exception from HRESULT: 0x8007007E)
My first attempt at 'fixing' this was simply to copy the requisite DLLs to my bindebug folder. I found the DLLs here:
C:Program Files (x86)Microsoft SQL Server Compact Editionv3.5 and copied these - sqlcecompact35.dll, sqlceca35.dll, sqlceme35.dll, sqlceoledb35.dll, sqlceqp35.dll and sqlcese35.dll, sqlceer35EN.dll - to my bindebug folder.
Now instead of the first error, I get this error:
An unhandled exception of type 'System.BadImageFormatException' occurred in System.Data.SqlServerCe.dll
Additional information: An attempt was made to load a program with an incorrect format. (Exception from HRESULT: 0x8007000B)
I am running Vista Business (x64) and using (the desktop version of) Sql Server Compact Edition 3.5 with Visual Studio 2008 Standard Edition. The test 'program' is written in C#. (Incidentally I can play with the database with no problems in Visual Studio 2008's server explorer. I can look at data, add data, etc.)
Can anyone please help?
Thanks.
View 3 Replies
View Related
Oct 30, 2007
Hi all,
I am a sysadmin (not a DBA by any means!), so just keep that in mind when answering
I was thinking to set up a database mirror with a manual failover for my Business Objects server. The question I have here, is the database name.. how is it kept?
I have three servers right now, all pointing to the same database. Let's call it DatabaseA. If I set up database mirroring (the links I've seen make it seem simple enough), and I fail over, what happens to the servers that have an ODBC entry to DatabaseA? Do I have to repoint them? Or is the identity of the server transferred over as well?
A little information on this would be greatly appreciated. Right now, we are using doubletake to copy over the database dumps on a constant basis, and I thought that database mirroring would be a better solution to my problem. Please let me know! I am quite new to database mirroring, so take it easy with me
View 4 Replies
View Related
Oct 22, 2007
Hi,
I am beginner developer, Creating simple application which will create, handle small database of genral store products (like adding products and substracting no. of products) . I am creating application with native win32 APIs in VS 2005.
Please suggest , how to create such data base , and suggest me link where i will get step by step knowledge to do (learn) it.
Do i need to learn ODBC or OLEDB or SQL server
Thanks
View 4 Replies
View Related
Jan 18, 2008
I'm designing a database with 3 tables called Function, Test and Scene.
A Function has multiple Tests, but a Test has only one Function. A many to many relationship exists between Test and Scene therefore I need a junction table between these two tables - giving 4 tables in total. The Test table would store a foreign key, the primary key of the Function table.
There is a problem with design though and that is that Functions and Scenes are actually defined before the Test is defined. Therefore it should be possible to create a Function and add to id its Scenes, before Tests have been defined. In other words, Scenes are as much a part of a Function as they are of Tests. Tests are in fact only of relavence to testers. Anyway, to satisfy this scenario, a Junction box is also needed beween Function and Scene. This creates a loop between all tables.
Is this a good approach? Any other suggestions or advice on the matter? Any advice regarding data integrity?
Thanks,
Barry
View 1 Replies
View Related
May 13, 2008
How can I connect to another sqlserver instances using a SQL Query Analyzer command? I mean, something like this:
connect (server1.instance1, user, pass) ??
SELECT * FROM MYTABLE;
connect (server1.instance2, user, pass) ??
SELECT * FROM MYTABLE;
connect (server1.instance3, user, pass) ??
SELECT * FROM MYTABLE;
PD: I know I can click in File-->Connect-->etc..., but I want to do this with a T-SQL command
View 7 Replies
View Related
Mar 27, 2007
hii want to copy one database table to onther database table using script?my database is ms-sql server 2000
View 4 Replies
View Related
Apr 8, 2005
i have an database created with MSDE using the windows authentication,
and now i want to send this database to someone, can i just backup this
database and send it,
can other people access my database with windows authenticaiton in his computer ??? or i need to do some extra stuff???
View 3 Replies
View Related
Jul 25, 2001
Running SQL 2000 and need to copy an entire database (structure and data) from our inhouse development server to our 'live' server at our hosting co. What's the best solution? I can't do it directly because both machines are behind firewalls or course.
Thanks in advance!
Jim
View 1 Replies
View Related
Sep 12, 2001
I am pretty new to SQL Server 7.0 and am having a problem. I have two databases, both on seperate SQL Servers. The problem I am having is I have a copy of one and a backup of the other. I need both of these to be restored into a third SQL Server I have locally. None of these Servers see each other so I can't register them. All I have to work with is the Backup and the copy. Can someone tell me how to accomplish this. I have tried to do restore and import.
Thanks so much in advance for any help.
View 2 Replies
View Related
Sep 26, 2001
What is the best method to copy databases among all the options.
* bcp
* sp_detach and attach
* DTS
* Back up from source restore to destination
View 1 Replies
View Related
Jul 12, 2000
Hi,
What is the quickest and easiest way to make a copy of an entire database ie. create a test environment from production?
Thanks in advance,
Darrin
View 1 Replies
View Related
Feb 27, 2001
Hi,
I have to make a copy of my db with all users/passowrds/views/sp...etc to same server with diff.name.
What is the best way to do this and how long will it take to transfer around 5gb of data.
Thanks
View 1 Replies
View Related
Apr 28, 2008
How can you copy a database from one server to another without taking it down?
I know I can detach the database and then copy it thru the file system, but how can it be done with the database running?
Thanks
View 1 Replies
View Related
Jun 28, 2004
what would be the best way to copy a database from one server to another.
Thanks.
View 1 Replies
View Related
Jul 12, 2004
I wanted copy a database from one server to another server.So far I'm doing this is by detaching and attaching the DB.But when i tried to restore the DB on the new server its giving some error. Is't a good process to detach and attach.PLease let me know if there is any better way of doing this.
View 5 Replies
View Related
Mar 18, 2007
I need to move a database from sql 2000 to sql 2005. My research suggests that I can backup a sql 2000 db from enterprise manager and restore it with sql 2005 management studio. Are there step by step directions for this or can someone tell me how to do this?
what about logins? Are they transfered in this process. My research also suggests the I use copy database wizard by this failed on me and I can't find anything in the event log or anywhere else to tell me why. Please help. Thanks
View 3 Replies
View Related