I have a database with regular full-text catalogs. I want to detach this database, copy it to a different server and attach it under a different name (same name but with '_BAK' appended to it). I am using SQL Server 2005.
Here is the error trying to attach DATABASE with full-text catalogs under the name DATABASE_BAK
Warning: Identity or last population complete time of full-text catalog in
directory 'E:\DATABASE\Name_FullText' does not match database 'DATABASE'.
The full-text catalog cannot be attached.
Is there a way to attach a database w/ full-text under a different name?
If not what other options do I have?
Attach without fulltext?
Drop the full-text at detach and recreate it?
Why not just attach the database and then rename it once attached?
Related
I have an Azure SQL database and am trying to drop a full text catalog. I get an error that says "Cannot drop full-text catalog because it contains a full-text index.
I've gone in and deleted every full-text index from the db, yet the error persists. Is there a T-SQL statement I can run to see the exact index that this catalog supposedly contains? Note that right-clicking on the full text catalog in SSMS has very limited options (not even Properties) when working in an Azure SQL database, hence the need for doing this in T-SQL.
I have been told an entity called table_loader in a database, database_1 in SSMS (version 2008 R2) exists and needs to be fixed. It is not obviously a stored proc. It's purpose is to convert an excel spreadsheet to table data. Is there any easy way to search a database for an entity name in SSMS.
The find function appears to work only with text SQL files as opened in SSMS.
Since originally posting I have found out from a colleague that this entity is a DTS package; however, I believe searching a database for a name is still a useful thing to be able to do, especially if you don't know what "layer" the entity is in with respect to the database folder structure.
Thanks.
A great, free, tool is Red-Gate SQL Search. It lets you search for just about any object from SSMS in a very user-friendly manner. http://www.red-gate.com/products/sql-development/sql-search/. You just type in the object name and it will search across databases and object types and display what it finds. I like it because it also searches within sproc text and such which can be very helpful, depending on what you're looking for.
If you open up a query window in SSMS you can use the below SQL to do a wildcard search:
USE [dbname]
SELECT * FROM sysobjects WHERE name like '%table_loader%'
This thread has got some good queries and lists the xtype meanings (sproc, table, key etc):
How do I get list of all tables in a database using TSQL?
I have exported a number of Microsoft Access database tables to a SQL Server 2012 using ODBC. Subsequently, I have linked to the data sources by creating linked tables.
Now here's the issue.
When I verify the tables in SQL Server itself, I notice only the database tables, columns and their respective datatypes are present. There are no key or indexes to be found. Still, in my Access database they were all defined. Also, I noticed that Access requests to choose a field(s) that uniquele identify each record to ensure data integrity and to update records. These then become the Primary Keys I understand, but why not use the PK that are already present?
What would be the easiest and most efficient way to also migrate the other field properties like indexes, keys, constraints? As otherwise, I would need to define all those manually and this would be very time-intensive.
Many thanks for your help!
As you have discovered, the keys and indexes and not copied over if you simply export an Access table to SQL Server using External Data > Export > More > ODBC Database:
However, the indexes, keys, and relationships are copied over to SQL Server if you use the "Upsizing Wizard", which is invoked via Database Tools > Move Data > SQL Server:
Note: The "Upsizing Wizard" was removed from Access 2013, so users of Access 2013 (and newer) will need to use the "SQL Server Migration Assistant for Access" instead. For more information look here.
I tried to export a database using the wizard in SQL Server Management Studio. It exported all the tables but with no primary keys or identity keys.
I realized I need to save SSIS Package. How do I exactly export a database using SSIS? I am actually on the Save and Run Package but I don't know if I should choose SQL Server or File system.
Is there a nice tutorial on exporting SQL Server database with identity keys and all?
What's happening is, I cannot insert new records on some table that just got exported. I found that Enable identity insert has something to do with it but I am not sure if I should enable them all while exporting.
I assume that you are using Restore Database dialog user interface available on SQL Server Management Studio.
On the Restore Database dialog, click Options page and then check Overwrite the existing database (WITH REPLACE). Click OK to restore the database.
CAUTION:
Selecting WITH REPLACE option will overwrite the database files on the destination server that are using the same name as the database file names in the backup. Read more about WITH REPLACE option on MSDN Restore Database (Options Page) before selecting this option.
I am attempting to setup a full text search catalog in SQL Server 2008 is there a way to make this catalog contain data from multiple tables?
In SSMS, you can select as many tables as fields as you like. They just have to be all in the same database.