Copy database Structure

Hello, I am hoping that someone out there can help me.  In my windows application I create a copy of my database using SMO. I am hoping to convert my application to be SQL version independent and not use the SMO objects in my code. I have seen several
responses to this question all say to use SSMS or SMO. Does anyone know how to do this using plain old T-SQL?
Any and all help is greatly appreciated.

Check this http://stackoverflow.com/questions/13040563/how-to-export-database-schema-in-visual-studio-2012 You should be able to do that
from the Visual Studio.
In our system we use Red Gates SQL Compare tools to generate the schema changes scripts.
For every expert, there is an equal and opposite expert. - Becker's Law
My blog
My TechNet articles

Similar Messages

  • Copy database structure but not the data

    I'm looking to create a new version of a database but with completely reloaded data - so I want to retain the database structure but none of the data.
    Is there an easy way (read: without a DBA on staff) to copy an existing database structure - preferably with views and stored procedures - and not take the data along for the ride?
    Thanks in advance for suggestions...!

    My mistake Judith.
    Using Object Explorer, [Right Click] on the database,
    Select [Tasks],
    Then [Generate Scripts...]
    On the first screen, check the 'Script all objects' checkbox.
    You can either save to a file or into a window. When the scripts are finished, go to the top and change the name of the database, then run the scripts.
    That 'should' get you what you want.

  • Acitivites  R/3 quality and BW qualilty in case of System copy(database )

    Hi,
    We have carried out system copy (database copy )  to refresh r/3 qualtiy server from r/3 production server.
    client no of r3/ qulaity is same (earlier it was 500 and and after system copy also it is ketp same ie 500).
    Now we want to know what are the acitivites that are required to be carried out in  R/3 quality and BW quality as we want to refesh data in  bw quality.
    we already have source system RQ1CLNT500  in BW under SAP node and on running check connection option it show message "source system connection RQ1CLNT500 OK.
    But still when we want to fetch data in PSA it shows following message
    "No transfer structure is available for InfoSource 0FS_PORTFOL_TEXT in the source system"
    can anybody guide us to solve the problem
    Thanks and Regards
    Deepak Deshpande
    LIC of India,

    Hi ,
    This is common issue comes due to upgrade /system copy .
          This is caused because table ROOSGEN does not contain an entry for the erroneous Datasource.
          The entries in ROOSGEN table are generated in $TMP (Temporary package) and sometimes after upgrade, they disappear.
          It happen if the extract structure of a DataSource gets a new timestamp we often enhance DataSources between different releases,upgrades .
         so the normal procedure should be to replicate the DataSources into BW in order to get the currently valid set of metadata. Solution:
    In case of 7.0 DataSources, you need to reactivate them by using the program RSZ_DATASOURCES_ACTIVATE_ALL and if the issue occurs for few datasources, they can be activated manually also.
    regards,
    Jaya Tiwari

  • Use same report with same database structure to different database server.

    Hi,
    I have standard crystal reports which needs to be copied to another database server.
    The origin database has exactly same database structure with the data base in other server.
    My only question is how to change the connection of the crystal report file from old database server to new one without affecting the linked tables in the report. Would it be possible?
    Note: origin database and new database has same structure, tables and columns but differ in data on it. and both has different server. (MS SQL)
    Thanks,

    Hi Mark,
    Open the report in the CR Designer > select Database option on the top > select Set Datasource location.
    The pane on the top shows the current connection. Go ahead and create a new connection to the target database from the pane at the bottom. Once created, highlight one table from the top, highlight the corresponding table from the bottom pane and click Update. Do this for each table.
    -Abhilash

  • Refresh database structure

    Hello !
    I'm using VB.net 2013 , Entity Framework 6 , SQL server 2008R2 and SMO.
    I have the application that use the database.
    But sometime I make changes to database structure , and I want to add to my application a "Refresh Database" command.
    Let's say that I have a database model called "Model" ( as a .bak file). The refresh command should compare the current database with this model and after make all the changes needed to make the current database up to date according to model.
    How this can be done using SMO ?
    Thank you !

    Do you think that creating a new database and migrating data it's more easy ?
    Let's get an example :
    The new Model.bak contains only a new field in one of the tables comparing with the current database.
    Do you think that only for 1 field , I should create a new database and migrate thousand of records ? After that of course I should make additional work to make this "New database" connect with my program because I use Entity framework that
    is created with wizard on design time with the database ( that have a specific name ) , and the new database have another name.
    So I think is more easy to add this new field to the current database ( so make a "Refresh" )  and end of the story.
    what do you think ?
    thank you !
    Hi dcode25,
    For such a scenario adding only one more field, what you should do in the upgrade is neither to restore nor to "refresh", the only approach is to run the ALTER table script to add the column when your upgrade wizard fires. This approach should be
    applied to the cases that there's not much modification in your "model". For the cases which are more complex, the restore and migration is the option.
    If you have any question, feel free to let me know.
    Eric Zhang
    TechNet Community Support
    Hello !
    I think that the conversion now is transformed in how we  should call this process.
    Why you don't like the word "Refresh". I like to call this process refresh , but we can call how we want.
    The point is that I want to do this process within my application . I don't know what do you mean with "When your upgrade wizard fire ?"
    Is possible to use the Alter table script in vb.net inside my application and what are the steps ? But of course I want to make this process general so regardless of how many field are added , this process should work. But how can I compare first the
    current database with new model to find out what are the changes that I should made ?
    And what you consider  "too much modification "
    The modifications on new "Model.Bak" may  be :
    - One (or some ) field(s) are added to one (or several )  existing table(s).
    - One (or some ) field(s) are deleted to one (or several )  existing table (s).
    - One (or some ) field(s) in one (or several )  existing table (s) have a different type.
    - A new table is added to database
    - A new table is added that have a new relationship with an existing table
    - 2 or more new tables are added that may have relationship between each other.
    On your opinion , which of these modifications can be done without migration and inside my application ?
    For the others , why do you think that cannot be done without migrating ? Because it's impossible to do , or is difficult ?
    In my opinion ( of course I can be wrong because I don't know ) these may be the steps :
    1) Get one by one the tables in "Model.Bak"
    2) With each table , first detect if this exist in the current database
    3) If not exist , create the table ( or copy from Model ???? I don't know if can be done ).
    4) If exist , compare one by one the fields , and if a field doesn't exist , add the new field. If a field exist but has a different type , change the type. After detect if one of fields in current database doesn't exist on model. If so , delete that field.
    5) If a new relationship exist , add the new relationship
    If you agree with these steps , which of them may be impossible to be done ?
    Or if can be done , how can I realize each of these steps inside my program in vb.net ?
    Thank you !

  • Message: "The database structure has been modified" every time I log to SAP

    Hello,
    "The database structure has been modified. In order to resume this process, all open windows will be closed". Every time I log to one of my companies in SAP Business One this message appears.
    I haven't installed any new addons and made no changes in database structure (and any other user hasn't done any changes), but this message appears always when I log to company for the first time (when I try to log on another user or log to another company there is no message). Can anyone help me with this problem?
    Best regards
    Ela Świderska

    Hi Ela Świderska,
    You may check this thread first:
    UDFs disappeared
    Thanks,
    Gordon

  • DATABASE STRUCTURE HAS BEEN MODIFIED PROBLEM...

    Hi
    I am getting the message " The database structure has been modified " after every 5 minutes.
    Regards

    Hi,
    You may check this thread:
    Message: "The database structure has been modified" every time I log to SAP
    Thanks,
    Gordon

  • The Database Structure Has Been Modified

    Good Day!
    Just want to ask what is the probable reason why upon using SAP, there is a system message " The database structure has been modified. In order to resume the process, all open windows will be closed. Continue?"  Even upon user log in , this system message appear affecting other user's data entry. Upon adding of the document (of other users when this system message appear), all the UDFs are missing, causing their data entry to be inaccurate since you cannot update row level once the document has been added.
    Hope to hear from you soon.
    Thanks
    Sandra

    Hello ...
    This error message appears every time that has altered the structure of the database, either by creating a new field of user or user table, so it is inevitable that appear the same.
    Now, it is necessary as a measure, to control who has access to make these changes, and that they are made without users.
    I hope it will help
    Best regards,

  • The database structure has been modified - how to check if it happend?

    Hello,
    I have a question. How to check if the database structure has been modified? I know that there is shown a messagebox after creating table and adding some fields, but sometimes this message appear after some seconds. The problem is that I want to create table and UDO for this table, and until database structure is not modified I got an error message. If I wait and DB strucuture modifies then UDO is creating correctly.
    My question is - does anyone know how to check if database structure has been modified?
    Regards,
    Hmg

    Hi Szymon,
    I guess you are stuck up in a kinda scenario, where in, you will be populating a form with values, before the structure modifies, if this is going to be your problem, I can help you out with a work around.
    In the beginning of the process, before the creation of the UDO or tables, set a boolean value to false, and once all UDO's and Tables are created, only then, should you make it true and only after the boolean becomes true, you should proceed with populating the values from the screen.
    I really ament sure what your problem is, but one of my guys faced this problem, I then, thought even you might have a similar problem.
    Satish.

  • Is it possible to change selection screen of logical database structure?

    I have to create a z report for a standard transaction FBL01N which is extracting data according to the vendor account number(LIFNR) at the selection screen. Now as per the requirement the system should extract details according to 'vendor name' keeping the same functionality.
    But the standard program is using some logical database structure KDB and the include for the selection screen is DBKDFSEL.So can I modify the selection screen of this transaction replacing Vendor No with Vendor Name.

    Hi..
    Refer this links
    http://help.sap.com/saphelp_46c/helpdata/en/9f/db9b8535c111d1829f0000e829fbfe/content.htm
    http://help.sap.com/saphelp_nw70/helpdata/en/9f/db9b8535c111d1829f0000e829fbfe/content.htm
    Hope this may b very helpful to u
    Sravani
    Plz reward points

  • Error in last step of copy database wizard

    Hi All,
    I am getting below mentioned error in copy database wizard. I am using SSMS 2012 to copy a database from one server to another server using attach and detach method. Been stuck in this issue for quite sometime. Please provide your insights...
    Event Name: OnError
     Message: An error occurred while transferring data. See the inner exception for details.
    StackTrace:    at Microsoft.SqlServer.Management.Smo.Transfer.TransferData()
       at Microsoft.SqlServer.Dts.Tasks.TransferObjectsTask.TransferObjectsTask.TransferExtraObjectsViaSmoTransfer()
    InnerException-->There is already an object named 'spt_values' in the database.
    StackTrace:    at System.Data.SqlClient.SqlConnection.OnError(SqlException exception, Boolean breakConnection, Action`1 wrapCloseInAction)
       at System.Data.SqlClient.TdsParser.ThrowExceptionAndWarning(TdsParserStateObject stateObj, Boolean callerHasConnectionLock, Boolean asyncClose)
       at System.Data.SqlClient.TdsParser.TryRun(RunBehavior runBehavior, SqlCommand cmdHandler, SqlDataReader dataStream, BulkCopySimpleResultSet bulkCopyHandler, TdsParserStateObject stateObj, Boolean& dataReady)
       at System.Data.SqlClient.SqlCommand.RunExecuteNonQueryTds(String methodName, Boolean async, Int32 timeout, Boolean asyncWrite)
       at System.Data.SqlClient.SqlCommand.InternalExecuteNonQuery(TaskCompletionSource`1 completion, String methodName, Boolean sendToPipe, Int32 timeout, Boolean asyncWrite)
       at System.Data.SqlClient.SqlCommand.ExecuteNonQuery()
       at Microsoft.SqlServer.Management.Smo.Transfer.ExecuteStatements(SqlConnection destinationConnection, IEnumerable`1 statements, SqlTransaction transaction)
       at Microsoft.SqlServer.Management.Smo.Transfer.TransferData()
     Operator: EMEA\INCHEJAI
     Source Name: CDW_BIE-WV200_xxxx_xxxx_35
     Source ID: {xxx-xxx-xxx-xxx-xxx}
     Execution ID: {xxx-xxx-xxx-xxx-xxx}
     Start Time: 24.09.2014 10:38:37
     End Time: 24.09.2014 10:38:37
     Data Code: 0
    P.S - I am able to query and fetch the results for "select * from master.dbo.spt_values;"
    in both my SOURCE and DESTINATION databases. 
    But the table name is not visible under System databases--> master --> Tables --> System Tables in my DESTINATION database alone.
    Thanks,
    DeeJay007

    Hi,
    Thanks for your response :). When I tried to attach the the database (.mdf and .ldf) and create a new database in DESTINATION server, it works fine. Only using "Copy database wizard" I face this problem. I am attempting this functionality from
    the SQL Server 2012 instance
    The Instances are not in same version. Find the specific details below for @@Version.
    SOURCE Server Instance
    Microsoft SQL Server 2008 (SP3) - 10.0.5500.0 (X64) 
    Sep 21 2011 22:45:45 
    Copyright (c) 1988-2008 Microsoft Corporation
    Standard Edition (64-bit) on Windows NT 6.0 <X64> (Build 6002: Service Pack 2) (VM)
    DESTINATION Server Instance
    Microsoft SQL Server 2012 (SP1) - 11.0.3000.0 (X64) 
    Oct 19 2012 13:38:57 
    Copyright (c) Microsoft Corporation
    Standard Edition (64-bit) on Windows NT 6.2 <X64> (Build 9200: ) (Hypervisor)
    When you use the copy database functionality, your database gets upgraded to match the destination server version. The database cannot be downgraded, which is fine in your case. It could be a bug in the upgrade process between these two specific sql server
    versions though.
    Can you make a test with another destination instance, with the same version as the original destination (2012 SP1) just to rule out the possibility of system database corruption?
    Does this happen with only a single database, or does the wizzard fail for any database you try to copy?
    I have the "u_tables.sql" file which has the scripts for some master database tables. In the process of trying to rebuild the system database and if I lose the master DB contents, will executing the "u_tables.sql" be sufficient to restore
    the details?? Many DB's are available in the server, so the risk is very high.
    No. However, your application databases won't be affected. You'll lose all your server objects, including but not limited to logins, linked servers, backup triggers, server roles, etc. You'll also lose the contents of the msdb database (jobs, database mail
    configurations, backup history, maintenance plans, etc). Please refer to the article I sent you for more information. It contains safety instructions on how to backup most of these objects.
    Try to do the tests I suggested above before rebuilding your system databases.
    Is there any restrictions for "Copy database wizard" which I am missing here?
    No I dont think so. Based on the information you provided, it should be working.

  • COPY DATABASE ON THE SAME UNIX MACHINE

    제품 : ORACLE SERVER
    작성날짜 : 1997-10-10
    INTRODUCTION
    The following article deals with creating a copy of a database on the same
    unix machine. A database might need to be copied in order to duplicate the
    production system, for example for testing purposes. It is recommended that
    the reader refer also to the following documentation:
    -Oracle 7 Server Administrators Guide
    Performing full backups: Chapter 18 page 18-7
    OVERVIEW OF PROCEDURE
    Before copying the database to a new location, it is necessary to perform
    a full cold backup of the database, whilst the database is shutdown. This
    will ensure that no data will be lost if the copying of the database is
    unsuccessful.
    WARNING
    Creating a copy of a database involves usage of the CREATE CONTROLFILE command
    (explained below). If this command is not executed correctly it could corrupt
    the production database. If this happens, and if the files in question are
    important, this will mean that the original database will need to be restored
    from a backup.
    Note: If you are using Oracle 7.1.6 on Sun Solaris 2.X there is a serious
    bug with CREATE CONTROLFILE. Call Oracle Worldwide Support asking for
    details of <Bug:274054> before proceeding.
    1. OBTAIN DATABASE INFORMATION FROM CONTROLFILE
    In order to move the database, it is necessary to create a script containing
    information about the files of the database.
    This is done by executing the following commands.
    a. SQLDBA
    b. CONNECT INTERNAL, STARTUP MOUNT
    c. ALTER DATABASE BACKUP CONTROLFILE TO TRACE RESETLOGS;
    This will create a trace file in the trace file directory. The file
    will have the extension .trc, and is located either in the directory
    defined by the initialization parameter 'user_dump_dest', or, if
    this is not defined, in ORACLE_HOME/rdbms/log. The file should be
    copied to a name such as ccf<NEW_SID>.sql, where <NEW_SID> is to be
    the ORACLE_SID of the copied database.
    2. IDENTIFY FILES TO BACKUP/COPY
    a. Identify database and log files
    The CREATE CONTROLFILE command in the file ccf<NEW_SID>.sql can then be
    used to identify the various database files and redo log files that need
    to be backed up. The file names will be in single quotes and separated
    by commas after the words LOGFILE and DATAFILE, e.g:
    CREATE CONTROLFILE REUSE DATABASE "FRITZ" RESETLOGS ARCHIVELOG
    MAXLOGFILES 6
    MAXLOGMEMBERS 2
    MAXDATAFILES 10
    MAXINSTANCES 1
    MAXLOGHISTORY 100
    LOGFILE
    GROUP 1 (
    '/oracle/tberryha/fritz/log_disk1/fritzlog1v713.dbf',
    '/oracle/tberryha/fritz/log_disk2/fritzlog1v713.dbf'
    ) SIZE 50K,
    GROUP 2 (
    '/oracle/tberryha/fritz/log_disk1/fritzlog2v713.dbf',
    '/oracle/tberryha/fritz/log_disk2/fritzlog2v713.dbf'
    ) SIZE 50K
    DATAFILE
    '/oracle/tberryha/fritz/fritz_system/fritz_system01.dbf' SIZE 8M,
    '/oracle/tberryha/fritz/fritz_data/fritz_data01.dbf' SIZE 20M,
    '/oracle/tberryha/fritz/fritz_rollback/fritz_rollback01.dbf' SIZE 20M,
    '/oracle/tberryha/fritz/fritz_temp/fritz_temp01.dbf' SIZE 20M,
    '/oracle/tberryha/fritz/fritz_data/fritz_data02.dbf' SIZE 5M,
    '/oracle/d2/V7141/dbs/x' SIZE 1M
    It is also possible to obtain a listing of the files of the database
    by executing the following sql commands:
    SQLPLUS username/password
    Note: The user must have sufficient privileges to be able to see
    the dba views 'sys.dba_data_files', 'sys.v$logfile' and in addition
    the database must be open.
    SPOOL files.log
    SELECT file_name FROM sys.dba_data_files ORDER BY tablespace_name;
    SELECT member FROM sys.v$logfile
    SPOOL OFF
    Note: This will create a spool file called 'files.log' which
    will record the results of the previous commands.
    b. Identify controlfiles
    This can be done either by referring to the init<SID>.ora
    'control_files' parameter, or from 7.0.16 onwards, the table
    sys.v$controlfile can be used to identify the controlfiles of the
    database via the following statement:
    SPOOL control.log
    SELECT name FROM v$controlfile;
    SPOOL OFF
    This will create a file called control.log in the current directory
    which will contain the names of the controlfiles for the database.
    3. BACKUP EXISTING DATABASE
    Shutdown instance via SQLDBA, SHUTDOWN NORMAL, and then take full cold
    backup of:
    a. All the files identified in step 2 above.
    b. All parameter files.
    Note: the main parameter file will usually be called init<SID>.ora, in
    addition to which there may also be other parameter files. These will
    be identified by 'ifile' (included file) parameters in the init<SID>.ora.
    These additional parameter files are usually called config<SID>.ora.
    4. MAKE A COPY OF THE DATABASE
    Copy all parameter files, controlfiles, and all files noted in step 1 above
    to their new location taking care to preserve ownership and permissions.
    When the database has been copied, it will not be possible to use the same
    SID and therefore the ORACLE_SID environment variable must
    be changed to a new SID, and the copied init<SID>.ora must be
    renamed to init<NEW_SID>.ora, and any parameter files pointed to by an
    'ifile' parameter (e.g. parameter files such as config<SID>.ora) should be
    renamed to incorporate the NEW_SID (i.e. config<NEW_SID>.ora).
    5. SET UP PARAMETER FILES FOR THE COPIED DATABASE
    Edit the value of the control_files parameter in the init<NEW_SID>.ora to be
    the name and location that you want to use for the new control files.
    The controlfiles should be given a different name to distinguish them from
    the old database. In addition, change the DB_NAME parameter in the
    init<NEW_SID>.ora to be an appropriate name for the new database. Any
    'ifile' parameters of the parameter file will need to be edited to point to
    the new name of the include file in the new location.
    6. PREPARE THE 'CREATE CONTROLFILE COMMAND' FOR THE COPIED DATABASE
    In order to establish the new database in the new location, the CREATE
    CONTROLFILE command in the file ccf<NEW_SID>.sql should be executed. The
    following steps illustrate how CREATE CONTROLFILE command is prepared.
    a. The file ccf<NEW_SID>.sql must be edited before use. The CREATE
    CONTROLFILE command will be preceded by a series of comments and a
    STARTUP NOMOUNT command. These need to be stripped out of the file. In
    addition, after the create controlfile command, there will be a number
    of comments and the commands RECOVER DATABASE and ALTER DATABASE OPEN,
    which should also be stripped out, leaving just the create controlfile
    command itself.
    b. The CREATE CONTROLFILE command itself should also be edited. Change
    the CREATE CONTROLFILE command in 'ccf<NEW_SID>.sql' to have the new
    database name, and add the word 'SET', e.g:
    CREATE CONTROLFILE REUSE DATABASE "olddbname" RESETLOGS
    becomes
    CREATE CONTROLFILE REUSE set DATABASE "newdbname" RESETLOGS
    c. The CREATE CONTROLFILE command also specifies the files which make up
    the database, and these must also be changed to name the files of the
    new database in the new location, e.g:
    LOGFILE
    GROUP 1 (
    '/old_path/old_logfile_name1',
    '/old_path/old_logfile_name2'
    ) SIZE 50k
    would become:
    LOGFILE
    GROUP 1 (
    '/new_path/new_logfile_name1',
    '/new_path/new_logfile_name2'
    ) SIZE 50k
    and
    DATAFILE
    '/old_path/old_file_name1' SIZE 5M,
    '/old_path/old_file_name2' SIZE 10M
    would become:
    DATAFILE
    '/new_path/new_file_name1' SIZE 5M,
    '/new_path/new_file_name2' SIZE 10M
    7. EXECUTE THE 'CREATE CONTROLFILE' COMMAND FOR THE COPIED DATABASE
    Having prepared the create controlfile script, it is now necessary to run
    the script from within the new instance. This is done by executing the
    following:
    a. at the operating system prompt, change the value of the environment
    variable ORACLE_SID from OLD_SID to NEW_SID. This can be done by using
    the following unix command from within the C shell:
    %setenv ORACLE_SID NEW_SID
    b. SQLDBA
    c. CONNECT INTERNAL, STARTUP NOMOUNT PFILE=/<full path>/init<NEW_SID>.ora
    d. @ccf<NEW_SID>
    Note: if any files which should be specified in the CREATE CONTROLFILE
    command are omitted, these files cannot be added to the new database
    at a later date. In addition, if any of the files specified in the
    CREATE CONTROLFILE command are NOT changed from their original names,
    then the corresponding files of the original database will become part
    of the copied database, and it will not be possible to restore them to
    the original database. If this happens, and if the files in question
    are important, this will mean that the original database will need to
    be restored from a backup.
    e. ALTER DATABASE OPEN RESETLOGS
    8. MAKE A FULL COLD BACKUP OF THE COPIED DATABASE
    SHUTDOWN and take a full cold backup of the database in the new location.
    The full cold backup can be done as detailed in steps 2 and 3.

    Yes.
    vipul wrote:
    >
    Thanks Peter,
    But in such a case do we need to configure the WSL in the ubb file and set environment
    variables like WSNADDR, WSENVFILE etc .etc. for the WS client.
    Regards
    Vipul.
    Peter Holditch <[email protected]> wrote:
    vipul,
    Yes.
    In fact, you don't even need 2 installs. If you do a server installation
    of
    Tuxedo onto your UNIX machine, and build all the clients with the buildlcient
    -w
    option, then the clients will use /WS libraries, instead of the native
    ones, to
    contact Tuxedo.
    Regards,
    Peter.
    vipul wrote:
    Can I install Tuxedo/T server and Tuxedo/WS on the same UNIX machinein different
    directories
    and make the application behave like a client-server. In such a casecan we make
    the clients act
    like WS clients and not native clients.

  • Copy Database Wizard error: Enumerate subsystems failed for JobServer

    Hi, non-SQL person looking for some guidance. I'm trying to copy databases with permissions from a Win2008 server with SQL2008R2 to a Win2012 server with SQL2012. I'm running SSMS on the 2012 instance, and intiating the Copy Wizard from there. I'm getting
    the following error. Thanks.
    TITLE: Copy Database Wizard
    Enumerate subsystems failed for JobServer 'Win2012serverSQL2012'.
    For help, click:
    http://go.microsoft.com/fwlink?ProdName=Microsoft+SQL+Server&ProdVer=11.0.3401.0+((SQL11_SP1_QFE-CU).140109-1303+)&EvtSrc=Microsoft.SqlServer.Management.Smo.ExceptionTemplates.FailedOperationExceptionText&EvtID=Enumerate+subsystems+JobServer&LinkId=20476
    ADDITIONAL INFORMATION:
    An exception occurred while executing a Transact-SQL statement or batch. (Microsoft.SqlServer.ConnectionInfo)
    The EXECUTE permission was denied on the object 'sp_enum_sqlagent_subsystems', database 'msdb', schema 'dbo'. (Microsoft SQL Server, Error: 229)
    For help, click:
    http://go.microsoft.com/fwlink?ProdName=Microsoft%20SQL%20Server&ProdVer=11.00.3401&EvtSrc=MSSQLServer&EvtID=229&LinkId=20476

    TITLE: Copy Database Wizard
    Create failed for JobStep 'NAME_CDW_2008ServerName_Win2012serverSQL2012'.
    For help, click:
    http://go.microsoft.com/fwlink?ProdName=Microsoft+SQL+Server&ProdVer=10.50.4000.0+((KJ_PCU_Main).120628-0827+)&EvtSrc=Microsoft.SqlServer.Management.Smo.ExceptionTemplates.FailedOperationExceptionText&EvtID=Create+JobStep&LinkId=20476
    ADDITIONAL INFORMATION:
    An exception occurred while executing a Transact-SQL statement or batch. (Microsoft.SqlServer.ConnectionInfo)
    The @flags parameter is not valid for a job step of type 'SSIS'. (Microsoft SQL Server, Error: 14545)
    For help, click:
    http://go.microsoft.com/fwlink?ProdName=Microsoft+SQL+Server&ProdVer=11.00.3401&EvtSrc=MSSQLServer&EvtID=14545&LinkId=20476
    BUTTONS:
    OK
    Hi scogordo,
    From your description, are you using SSMS 2008 R2 to perform the copy action?  I make a test on my computer, and get the same error as yours. To work around this issue, please use SSMS 2012 to copy database from SQL Server 2008 R2 to SQL Server 2012.
    There is a feedback to Microsoft about the issue for your reference.
    https://connect.microsoft.com/SQLServer/feedback/details/810037/copy-database-fails-when-copying-database-from-sql-server-2008-r2-sp2-to-sql-server-2012-sp1 
    Thanks,
    Lydia Zhang

  • SQL 2012 Copy Database Wizard fails

    I am trying to use the Copy Database Wizard in SQL Server 2012
    The host is running SQL Server 2000 (8.00.2066 (SP4)) on a Windows 2003 server
    The destination is SQL Server 2012 running on Windows Server 2012 Standard.
    Its gets to Execute SQL Server Agent Job and fails with this error:
    The job failed. Check the event log on the destination server for details
    Fails at – Execute SQL Server Agent Job
    I've looked at the application log and not sure which errors are relevant. Here are two of them:
    the first is an error, the second a warning.
    Log Name:      Application
    Source:        SQLISPackage110
    Date:          1/9/2015 11:39:24 AM
    Event ID:      12291
    Task Category: None
    Level:         Error
    Keywords:      Classic
    User:          NT SERVICE\SQLSERVERAGENT
    Computer:      SQL2013
    Description:
    Package "CDW_SQL_SQL2013_7" failed.
    Event Xml:
    <Event xmlns="http://schemas.microsoft.com/win/2004/08/events/event">
      <System>
        <Provider Name="SQLISPackage110" />
        <EventID Qualifiers="16385">12291</EventID>
        <Level>2</Level>
        <Task>0</Task>
        <Keywords>0x80000000000000</Keywords>
        <TimeCreated SystemTime="2015-01-09T16:39:24.000000000Z" />
        <EventRecordID>456924</EventRecordID>
        <Channel>Application</Channel>
        <Computer>SQL2013</Computer>
        <Security UserID="S-1-5-80-344959196-2060754871-2302487193-2804545603-1466107430" />
      </System>
      <EventData>
        <Data>CDW_SQL_SQL2013_7</Data>
      </EventData>
    </Event>
    Log Name:      Application
    Source:        SQLSERVERAGENT
    Date:          1/9/2015 11:39:26 AM
    Event ID:      208
    Task Category: Job Engine
    Level:         Warning
    Keywords:      Classic
    User:          N/A
    Computer:      SQL2013
    Description:
    SQL Server Scheduled Job 'CDW_SQL_SQL2013_7_1' (0xDFA5EEDDB2D53A4FB3C7CED04563896E) - Status: Failed - Invoked on: 2015-01-09 11:39:18 - Message: The job failed.  The Job was invoked by User VGBtR3r0WgKjvthk.  The last step to run was step 1 (CDW_SQL_SQL2013_7_1_Step).
    Event Xml:
    <Event xmlns="http://schemas.microsoft.com/win/2004/08/events/event">
      <System>
        <Provider Name="SQLSERVERAGENT" />
        <EventID Qualifiers="16384">208</EventID>
        <Level>3</Level>
        <Task>3</Task>
        <Keywords>0x80000000000000</Keywords>
        <TimeCreated SystemTime="2015-01-09T16:39:26.000000000Z" />
        <EventRecordID>456927</EventRecordID>
        <Channel>Application</Channel>
        <Computer>SQL2013</Computer>
        <Security />
      </System>
      <EventData>
        <Data>CDW_SQL_SQL2013_7_1</Data>
        <Data>0xDFA5EEDDB2D53A4FB3C7CED04563896E</Data>
        <Data>Failed</Data>
        <Data>2015-01-09 11:39:18</Data>
        <Data>The job failed.  The Job was invoked by User VGBtR3r0WgKjvthk.  The last step to run was step 1 (CDW_SQL_SQL2013_7_1_Step).</Data>
      </EventData>
    </Event>
    Any ideas would be appreciated. I'm anxious to retire this old SQL 2000 server!
    Mike

    Thanks David.
    is this the log you are looking for:
    Date  1/9/2015 11:39:18 AM
    Log  Job History (CDW_SQL_SQL2013_7_1)
    Step ID  1
    Server  SQL2013
    Job Name  CDW_SQL_SQL2013_7_1
    Step Name  CDW_SQL_SQL2013_7_1_Step
    Duration  00:00:08
    Sql Severity 0
    Sql Message ID 0
    Operator Emailed 
    Operator Net sent 
    Operator Paged 
    Retries Attempted 0
    Message
    Executed as user: NT Service\SQLSERVERAGENT. Microsoft (R) SQL Server Execute Package Utility  Version 11.0.2100.60 for 64-bit  Copyright (C) Microsoft Corporation. All rights reserved.    Started:  11:39:18 AM  Progress:
    2015-01-09 11:39:18.61     Source: sql_SQL2013_Transfer Objects Task      Task just started the execution.: 0% complete  End Progress  Error: 2015-01-09 11:39:24.50     Code: 0x00000000    
    Source: sql_SQL2013_Transfer Objects Task      Description: An error occurred while transferring data. See the inner exception for details.  StackTrace:    at Microsoft.SqlServer.Management.Smo.Transfer.TransferData()    
    at Microsoft.SqlServer.Dts.Tasks.TransferObjectsTask.TransferObjectsTask.TransferExtraObjectsViaSmoTransfer()  InnerException-->The specified schema name "INFORMATION_SCHEMA" either does not exist or you do not have permission to use it. 
    StackTrace:    at System.Data.SqlClient.SqlConnection.OnError(SqlException exception, Boolean breakConnection, Action`1 wrapCloseInAction)     at System.Data.SqlClient.TdsParser.ThrowExceptionAndWarning(TdsParserStateObject
    stateObj, Boolean callerHasConnectionLock, Boolean asyncClose)     at System.Data.SqlClient.TdsParser.TryRun(RunBehavior runBehavior, SqlCommand cmdHandler, SqlDataReader dataStream, BulkCopySimpleResultSet bulkCopyHandler, TdsParserStateObject
    stateObj, Boolean& dataReady)     at System.Data.SqlClient.SqlCommand.RunExecuteNonQueryTds(String methodName, Boolean async, Int32 timeout, Boolean asyncWrite)     at System.Data.SqlClient.SqlCommand.InternalExecuteNonQuery(TaskCompletionSource`1
    completion, String methodName, Boolean sendToPipe, Int32 timeout, Boolean asyncWrite)     at System.Data.SqlClient.SqlCommand.ExecuteNonQuery()     at Microsoft.SqlServer.Management.Smo.Transfer.ExecuteStatements(SqlConnection
    destinationConnection, IEnumerable`1 statements, SqlTransaction transaction)     at Microsoft.SqlServer.Management.Smo.Transfer.TransferData()  End Error  Progress: 2015-01-09 11:39:24.50     Source: sql_SQL2013_Transfer
    Objects Task      Database transfer failed for one or more extra objects.: 0% complete  End Progress  Progress: 2015-01-09 11:39:24.50     Source: sql_SQL2013_Transfer Objects Task     
    Transfer objects finished execution.: 100% complete  End Progress  Warning: 2015-01-09 11:39:24.52     Code: 0x80019002     Source: CDW_SQL_SQL2013_7      Description: SSIS Warning
    Code DTS_W_MAXIMUMERRORCOUNTREACHED.  The Execution method succeeded, but the number of errors raised (1) reached the maximum allowed (1); resulting in failure. This occurs when the number of errors reaches the number specified in MaximumErrorCount. Change
    the MaximumErrorCount or fix the errors.  End Warning  DTExec: The package execution returned DTSER_FAILURE (1).  Started:  11:39:18 AM  Finished: 11:39:24 AM  Elapsed:  6.062 seconds.  The package execution failed. 
    The step failed.
    I will also look into backup/restore. Will that work between 2000 and 2012?

  • Short Dump while copying Org structure from ERP to CRM

    Hello Experts:
    We are trying to copy the Org structure from ECC to CRM.
    We have a standard transaction 'CRMC_R3_ORG_GENERATE' to copy the the org structure from ECC or the IMG path:
    SPRO->CRM->Master Data->Organization Management->Data Transfer->Coppy ECC Sales Structure
    We have a multiple assignment scenario where each sales groups are assigned to multiple sales offices and likewise,each sales office is assigned to multiple sales org unit in ECC.
    This can be achieved by turning on the enhanced version.
    In our current business,even though the sales offices and groups are created,but are not having relavance in the business,hence while running in the sandbox system, we ran the program to copy the structures in the standard mode(default) and we could copy it without issues and create the org units for every entity in CRM based on how the number ranges are defined.
    What happens when enhanced version switch is turned on ::
    While we turn the mode to enhanced version, The system automatically::
    - enhances the Function tab page in the ppoma_crm  transaction to include a grid table, in which you maintain multiple assignments of organizational units
    - generates an extra dialog box to the Organization tab page in business transactions for you to select the relevant assignment path for the organizational unit
    - adapts the consistency check in business transactions to take into account organizational units that have been multiple assigned
    Risk factor :
    Once you have switched to the enhanced backend integration version of the organizational model you cannot return to the standard backend integration version. The system will also automatically make changes to the organizational model version in CRM Mobile Sales.
    Also this structure will happen across all the clients in the system,so unfortunately cannot try in a sandbox client also of the new environment.
    We are building our development box,so while running the above step in standard mode,the program gives a short dump due to long execution time even though we have the same amount of data as in our prototype system.
    Also, we increased the idle time value to a very high value.
    When I approached SAP OSS,I was told that it is due to the multiple assignment scenario,hence we need to switch to enhanced version in CRM before we run the copy program ( CRMC_ORG_R3_GENERATE )
    I am not quite sure if the mismatch of the scenarios between CRM and ECC could be causing this short dump as we could run it in standard mode in our prototype/sandbox environment without issues even  with the same data volume as in the new development system .
    I am looking for help from all the experts if they have come across similar issue and your recommendations/feedback if this can be corrected.
    Appreciate your guidance/recommendation on this issue.
    thanks!!

    In CRM Best Practices Building block C05 is the step by step description how to replicate Org. structure and some of employee's master data.
    Follow link - http://help.sap.com/bp_crmv12007/CRM_DE/BBLibrary/html/C05_EN_DE.htm

Maybe you are looking for

  • Bb msn only works with wifi

    Hi, i have a BB Pearl 8120 and it has a problem! I can send BB messages, but i can't receive them if I don't have wifi connection! (but i do send without wifi connection) Sometimes I can connect with internet (browser icon) sometimes I can't I alread

  • Changing fonts in web galleries....

    there is still no way to change the text font in the web galleries in lightroom correct? for me that is the biggest issue with the software and i really hope they address this asap. i cant imagine what they were thinking when they were coding the web

  • Imovie stopframe

    so im trying to make this stopframe animation in imovie. i have used a series of screenshots each with the object moving a fraction to create this stop frame. ive uploaded it to imvie and when i play it, the clip before the transition into the stop f

  • MacBook Pro OS X 10.7.5 Computer hangs after about 5 minutes

    After about 5 minutes of use, the multi-colored ball shows up and the computer hangs.  It keeps coming and going after the initial 5 minutes of use.

  • No sound on internal speakers (pavilion dv7 6c66rn ) windows 7 64 bits

    need help please! I have already try, resetting, and reinstalling drivers nothing work.