VS 2010, XSD, Database change

Using Visual Studio 2010 and an XSD to handle data sets and table adapters.
I am moving the application's database objects to a new server (SQL 2005 to 2012). Along with moving to a new server I am taking this opportunity to put the database objects under their own database schema. Also, all of the objects will be slightly renamed.
For example: "tblEval" to "hreval.EvalPeriod", and "tblEvaluations" to "hreval.Evaluations".
How best to go about updating the XSD so as to minimize the rework? Can I just pop open the XSD file in a text editor and do a search and replace? Or am I best off biting the bullet and recreating it from scratch?
Thoughts, ideas, suggestions? Thank you.

Hi ITMn,
According to your description, we need to verify if you want to create XML schema collection via SQL Server XSD. Just like a TABLE has a schema which defines the columns, their data type, precision etc, the XML schema which is bound to a TYPED XML variable/column
specifies the structure of the XML that it can store. To facilitate this, we need to create an XML schema which specifies the required structure of the XML and bind it to the column in the table. When a column or variable is bound to an XML schema, SQL Server
will perform validations while inserting or updating data, to make sure that the value matches with the given XML schema. For more information, see:
SQL Server XSD - Typed XML and SCHEMA Collections.
Hope it can help.
Regards,
Sofiya Li
Sofiya Li
TechNet Community Support

Similar Messages

  • Using Database Change Notification instead of After Insert Trigger

    Hello guys! I have an after insert trigger that calls a procedure, which in turn is doing an update or insert on another table. Due to mutating table errors I declared the trigger and procedure as autonomously transactional. The problem is, that old values of my main tables are inserted into the subtable since the after insert/update trigger is fired before the commit.
    My question is how can I solve that and how could I use the change notification package to call my procedure? I now that this notification is only started after a DML/DDL action has been commited on a table.
    If you could show me how to carry out the following code with a Database Change Notification I'd be delighted. Furthermore I need to know if it suffices to set up this notification only once or for each client seperately?
    Many thanks for your help and expertise!
    Regards,
    Sebastian
    declare
    cnumber number (6);
    begin
    select count(*) into cnumber from (
    select case when (select date_datum
        from
          (select f.date_datum,
            row_number() over (order by f.objectid desc) rn
          from borki.fangzahlen f
          where lng_falle      = :new.lng_falle
          and int_fallennummer = :new.int_fallennummer
          and lng_schaedling   = :new.lng_schaedling
          and date_datum       > '31.03.2010'
        where rn=1) < (select date_datum
        from
          (select f.date_datum,
            row_number() over (order by f.objectid desc) rn
          from borki.fangzahlen f
          where lng_falle      = :new.lng_falle
          and int_fallennummer = :new.int_fallennummer
          and lng_schaedling   = :new.lng_schaedling
          and date_datum       > '31.03.2010'
        where rn=2) then 1 end as action from borki.fangzahlen
            where lng_falle      = :new.lng_falle
            and int_fallennummer = :new.int_fallennummer
            and lng_schaedling   = :new.lng_schaedling
            and date_datum       > '31.03.2010') where action = 1;
    if cnumber != 0 then
    delete from borki.tbl_test where lng_falle = :new.lng_falle
    and int_fallennummer = :new.int_fallennummer
    and lng_schaedling   = :new.lng_schaedling
    and date_datum       > '31.03.2010';
    commit;     
    pr_fangzahlen_tw_sync_sk(:new.lng_falle, :new.int_fallennummer, :new.lng_schaedling);

    It looks like you have an error in line 37 of your code. Once you fix that the problem should be resolved.

  • Working offline with data from Access 2010 web database

    Hello all,
    I have an Access 2010 web database that I have published to a SharePoint site. Users currently work with the data via one of several Access 2010 front end applications that simply have linked tables and client queires, forms and reports. On a couple
    of occasions, we have had issues with our SharePoint site that have left users unable to access the data. A couple of times it was due to our site collection suddenly and inexplicably becoming read only and the last time (while I was on vacation, of course)
    due to some license changes my folks were unable to access the site.
    I'm getting ready to go on vacation again. What i would like to do is have a sort of emergency back up plan should things go awry again while I'm gone.
    What I envision is a back up database that has actual data tables, rather than simply linked lists, that I can sync with my SharePoint lists on a regular basis. That way, should the SharePoint lists become inaccessible, users could continue to work with
    the data offline and any changes can be synced once a connection is restored.
    I have read through
    this article, but in each scenario I was unable to actually open tables to work with the data once offline. Is this a situation where I should simply have folks work offline with a local copy containing all of the data and then republish? Or, is there
    a way to simply sync? Any thoughts or suggestions would be appreciated. I'm really hoping to leave my laptop at home on this next trip.
    Thanks,
    Greg

    Hi,
    I am trying to involve someone familiar with this topic to further look at this issue.  There might be some time delay, appreciate your patience.
    Thanks
    Daniel Yang
    TechNet Community Support

  • Exchange 2010 SP1 database size limit?

    I have seen several posts concerning exchange 2010 Standard database limit being 50GB but can be increased by modifying the registry. We were migrated from Exchange 2003 to Exchange 2010 by a vendor. My current database is  188.1GB. I searched the registry
    for the changes to increase the database form the 50GB limit but it does not look like they made the changes. What has me baffled is how can my database be 188.1 GB if they did not modify the registry?
    Thank you,
    Cecil

    So you only use Database Size Limit in GB registry if you want to hard set the size? From some of the posts I had seen they were saying it was 50 GB by default and could be expanded to 1TB by modifying the registry. I did not understand
    why the instructions included modifying the registry if it was not needed. I am by no means trying to dispute it just trying to understand. 
    Thanks for the reply.
    Cecil

  • Reporting Services 2012 in SharePoint 2010 - SQL database edition?

    We currently have a SharePoint 2010 farm, running on a SQL Server 2008 R2 Standard database.  On one of the SharePoint 2010 servers, we have an instance of Reporting Services 2008 Enterprise running in SharePoint integrated mode.  (We require Enterprise
    for data-driven subscriptions)
    We'd like to upgrade to Reporting Services 2012 for Data Alerts and a few other new features.  However, I noticed something on
    this blog stating that the SharePoint 2010 database server edition needs to match the Reporting Services edition. My concern is that I've not seen any official mention of this in Microsoft's documentation, and would like to avoid upgrading to Enterprise
    for the SharePoint 2010 database if I can avoid it.
    So, what I'd like to run is:
    SharePoint 2010
    SharePoint database: SQL Server 2008 R2 Standard
    Reporting Services 2012 Enterprise
    Reporting Services database: same as SharePoint database, so SQL Server 2008 R2 Standard
    Is this possible?  Or do I need to upgrade the SharePoint database to SQL Server 2008 R2 Enterprise?  
    Alternatively, could I install a separate database engine just for Reporting Services to host its databases (for example, SQL Server 2012 Enterprise), so I don't have to mess around with upgrading the SP database?

    While you don't need to upgrade your SQL 2008 R2 to 2012, you will need to install an instance of SQL 2012 & SSRS 2012. They can be side-by-side and independent of each other. The following blog post provides steps to do so,
    http://www.madronasg.com/blog/how-configure-sql-server-reporting-services-2012-use-sharepoint-2010#.UuEVd2Ao74Y
    Dimitri Ayrapetov (MCSE: SharePoint)

  • How to port database changes from development to a production environment

    How do I port database changes from the development to the production environment?
    I am using v8 and have always had to redo everything using the schema manager all over in the production environment. Is there an easy way to generate a script, for example to dump the database changes on the development machine to be executed later on the production machine?

    This should already be a clearly defined change control process. Once a procedure, function, package, trigger, or whatever completes the testing rounds, it should be promoted to production.
    Forgive me if it seems I'm trivializing, but I don't see the problem, just copy the object(s) from your software library (or development) into production using whatever tool works best or has been chosen. If you are doing data copies then you have various options again including good old export/import.

  • Error  While Polling Database changes using Custom SQL

    Hi,
    I am using Oralce SOA Suite 11g DbAdapter for polling Database changes.
    My source database is DB2,I am using custom query for polling the changes in source database.
    I am using "Update an External Sequencing Table on a Different Database" polling Strategy
    Query section of the Mapping file is as follows.
    <querying xsi:type="query-policy">
    <queries>
    <query name="ReceiveF554102TXEDataSelect" xsi:type="read-all-query">
    <call xsi:type="sql-call">
    <sql><![CDATA[SELECT FILE_NAME, LIBRARY_NAME,
                   USER_NAME, SEQUENCE_NUM,
                   JOURNAL_CODE, ENTRY_TYPE, TIME_STAMP, JOB_NAME, JOB_USER,
                   JOB_NUMBER, PROGRAM_NAME, ARM_NUMBER, ADDRESS_FAMILY, RMT_ADDRESS,
                   REMOTE_PORT, SYSTEM_NAME, REL_RECORD, OTRCLN, IBMCU, IBITM, IBLITM,
                   IBAITM, IBY55ETAFR, IBY55ETATH, IBY55NUM01, IBY55NUM02, IBY55NUM03,
                   IBY55NUM04, IBY55NUM05, IBY55NUM06, IBY55NUM07, IBY55NUM08,
                   IBY55NUM09, IBY55NUM10, IBELM01, IBELM02, IBELM03, IBELM04, IBELM05, IBY55STR01,
                   IBY55STR02, IBY55STR03, IBY55STR04, IBY55STR05, IBY55CHA01,
                   IBY55CHA02, IBY55CHA03, IBY55CHA04, IBY55CHA05, IBY55DAT01, IBY55DAT02,
                   IBY55DAT03, IBY55DAT04, IBY55DAT05, IBUSER, IBPID, IBJOBN, IBUPMT,
                   IBUPMJ FROM PY_JRNMON.F554102T WHERE ((TIME_STAMP > (SELECT LAST_READ_DATE FROM SOALIB.SOASEQHDR WHERE (TABLE_NAME = 'F554102T'))) AND (TIME_STAMP < SYSDATE)) ORDER BY TIME_STAMP ASC]]> </sql>
    </call>
    <reference-class>ReceiveF554102TXEData.F554102T</reference-class>
    <lock-mode>none</lock-mode>
    <container xsi:type="list-container-policy">
    <collection-type>java.util.Vector</collection-type>
    </container>
    </query>
    </queries>
    <delete-query xsi:type="delete-object-query">
    <call xsi:type="sql-call">
    <sql>UPDATE SOALIB.SOASEQHDR SET LAST_READ_DATE = #LAST_READ_DATE WHERE (TABLE_NAME = 'F554102T')</sql>
    </call>
    </delete-query>
    </querying>
    I am getting following Error after defining the custom SQL in my mapping.xml file. (After executing the Created Process)
    Caused by: BINDING.JCA-11622
    Could not create/access the TopLink Session.
    This session is used to connect to the datastore.
    Caused by BINDING.JCA-11626
    Query Not Found Exception.
    Could not find Named Query [ReceiveSampleCustomPollSelect] with ? arguments, belonging to Descriptor [ReceiveSampleCustomPoll.F554102T] for [oracle.tip.adapter.db.DBActivationSpec@2ec733b0] inside of mappings xml file: [ReceiveSampleCustomPoll-or-mappings.xml].
    You may have changed the queryName info in either the _db.jca or toplink-mappings.xml files so that they no longer match.
    Make sure that the queryName in the activation/interactionSpec and in the Mappings.xml file match. If an old version of the descriptor has been loaded by the database adapter, you may need to bounce the app server. If the same descriptor is described in two separate Mappings.xml files, make sure both versions include this named query.
    You may need to configure the connection settings in the deployment descriptor (i.e. DbAdapter.rar#META-INF/weblogic-ra.xml) and restart the server. This exception is considered not retriable, likely due to a modelling mistake. This polling process will shut down, unless the fault is related to processing a particular row, in which case polling will continue but the row will be rejected (faulted).
         at oracle.tip.adapter.db.exceptions.DBResourceException.createNonRetriableException(DBResourceException.java:653)
         at oracle.tip.adapter.db.exceptions.DBResourceException.createEISException(DBResourceException.java:619)
         at oracle.tip.adapter.db.exceptions.DBResourceException.couldNotCreateTopLinkSessionException(DBResourceException.java:291)
         at oracle.tip.adapter.db.DBManagedConnectionFactory.acquireSession(DBManagedConnectionFactory.java:883)
         at oracle.tip.adapter.db.transaction.DBTransaction.getSession(DBTransaction.java:375)
         at oracle.tip.adapter.db.DBConnection.getSession(DBConnection.java:266)
         at oracle.tip.adapter.db.InboundWork.init(InboundWork.java:322)
         at oracle.tip.adapter.db.InboundWork.run(InboundWork.java:526)
         ... 4 more
    Caused by: BINDING.JCA-11626
    Query Not Found Exception.
    Could not find Named Query [ReceiveSampleCustomPollSelect] with ? arguments, belonging to Descriptor [ReceiveSampleCustomPoll.F554102T] for [oracle.tip.adapter.db.DBActivationSpec@2ec733b0] inside of mappings xml file: [ReceiveSampleCustomPoll-or-mappings.xml].
    You may have changed the queryName info in either the _db.jca or toplink-mappings.xml files so that they no longer match.
    Make sure that the queryName in the activation/interactionSpec and in the Mappings.xml file match. If an old version of the descriptor has been loaded by the database adapter, you may need to bounce the app server. If the same descriptor is described in two separate Mappings.xml files, make sure both versions include this named query.
         at oracle.tip.adapter.db.exceptions.DBResourceException.queryNotFoundException(DBResourceException.java:694)
         at oracle.tip.adapter.db.ox.TopLinkXMLProjectInitializer.initializeQuery(TopLinkXMLProjectInitializer.java:1238)
         at oracle.tip.adapter.db.DBManagedConnectionFactory.acquireSession(DBManagedConnectionFactory.java:728)
         ... 8 more
    Help required to fit custom SQL in mapping.xml file for complex queries.
    Thanks,
    Arun Jadhav.

    "Execuite Custom SQL" in DB adapter and you'l get it.
    But in this case you'll have to implement your own polling strategy (if you need one).
    If you want to use one of the predefined polling strategy you should use "Poll for New or Changed records" and import all the tables you use and connect them in wizard.

  • Issue in Oracle 11g Database Change Notification  for Java application

    Hi,
    I am trying to use Oracle's Database Change Notification in Java application.
    I followed the sample application (+DBChangeNotification.java+ , Example 29-2), provided in the following link:
    +[http://download.oracle.com/docs/cd/B28359_01/java.111/b31224/dbmgmnt.htm#CHDEJECF]+
    I am able to see that the Registration of the SQL query is successful.
    But, when I do changes to the table registered, notifications are not received in the Listener class (+DCNDemoListener.java+).
    Ideally, the method DCNDemoListener.onDatabaseChangeNotification() should be invoked on any insert/update to the registered table. But this method is not getting invoked.
    The execution has stopped in the following line of DBChangeNotification.java Class.
    this.wait();
    +==> The application was WAITing indefinitely in this line, as the NOTIFY() from DCNDemoListener.java was not executed.+
    I am using VPN to connect to Oracel server. Remote Oracle Server is protected my firewall. Is this the reason for not sending the notifications from Oracle server?
    The version of software used are given below:
    Oracle Client - Oracle 11.1.0
    JDK - 1.6
    Oracle JDBC Driver - ojdbc6.jar
    Can someone help me to resolve this issue?
    Thanks in Advance.
    Regards
    Sam
    Edited by: Ponsu on Apr 7, 2011 10:41 PM

    Hi,
    I am having similar issue. Where you able to resolve it.
    I am also using the same example you were using.
    I am using the following version.
    Oracle Database 11g Enterprise Edition Release 11.2.0.2.0 - 64bit Production
    Compatibility: 11.2.0.0.0
    I do not see any notification coming back from the DB.
    Appreciate your help.
    Thanks & regards,
    Ebe

  • SharePoint 2010 Content database growing too fast

    Hi,
    I have a SharePoint 2010 Content database wss_content_DB which is 197 GB BUT when I calculate my site collection I can see they have used only about 70 GB. I know there is Auditdata table which is about 27 GB. Couple of days ago my content DB was about 105
    GB and it Audit data log was set to unlimited once  I noticed that I set to 90 days since then it jumped to 197 GB.
     I have no idea what is going on.
     Now I need to know
     - why it is showing 197 GB in SQL server
     - How can I trim audit log
     -  Why suddenly it's increased to 197 GB from 105 GB
    Any help will be greatly appreciated.
     Abdul

    There is a way to deal with this table. There is an stsadm command (stsadm -o trimauditlog) as part of the infastructure update that will allow you to manage this data.
    #Powershell Script to trim old AuditData table records.
    $currentDate = Get-Date
    #Number of days we want to keep data in the table
    $NumberOfDays = -90
    $DateToDelete = $currentDate.AddDays($NumberOfDays)
    $DateString = ‘{0:yyyyMMdd}’ -f $DateToDelete
    $STSADMCMD = “stsadm -o trimauditlog -date $DateString -databasename WSS_ContentDB”
    invoke-expression “$STSADMCMD”
    WHY IT SUDDENLY INCREASED:
    Do this query on your SQL Instance: DBCC SQLPERF(logspace)
    This will show you how the size of LOGfiles (LDF) and how much is unused, if you have alot of unused space it indicates you dont have a recent DB backup - normally backup would write log data to MDF file .
    Normally you will not shrink DBs, only if you have deleted alot of data and you are not going to use space again so only do a shrink if you REALLY needs to.
    http://www.microsoft.com/en-us/download/details.aspx?id=24282

  • Best practice for tracking database changes...?

    Dear Oracle gurus,
    I'm still relatively new to database administrating, and recently I ran into a situation which I'm not sure if there's some text-book scenario analysis or practice.
    I find it hard to track all the database changes across different servers. Our company develop software that uses the Oracle database, so we have development and test servers set up here and there, with really minimal control on them. Problem arises when we make rapid design changes to our system, which required multiple and rapid changes to the databases. I find it really hard to keep track of everything, because sometimes I can't patch some server because of people still using it for development/testing/investigation/etc.
    So, is there some kind of good practices for tracking database changes (which we even write patches for), monitoring schema modifications, or maybe even versioning database objects? I've tried to find some information but I think I did not look in the right places or ask the right questions.
    Any help is appreciated.
    Best regards,
    Peter Tung

    The first thing I would start with is:
    Find a version control system that will allow you to store files and version them (PVCS for example). You could for example, store all the sql scripts. Whenever a change is needed, the user could check the program out from the version control tool and make changes and check it back in. Besides sql scripts, you could also store binary files or any type of source code files in a version control system. This would at least put some things in order. In a version control system, you could associate a number or a string with all the files within a patch.

  • How to know the database changes between different releases

    Where can I get the information of database changes, like for example new columns new tables, etc, between different releases?
    My goal to try to determine the current version, or is there a better way?
    Thank you

    For JD Edwards World or for JD Edwards EnterpriseOne - you can go to upgradejde.com Once this screen comes up, pick Resources. You will then have an option to take JD Edwards EnterpriseOne or JD Edwards World. On the next screen, you can select the tab Compare Releases. This will allow you to enter the release that you are currently on and enter the latest GA release of software. You will then see all the differences between your current release and the release you should upgrade to. You can also format this into a printed report.

  • How to use the database change notification event with an AppModule Child ?

    hi,
    I try to do the same stuff that this "How To" : [http://niallcblogs.blogspot.com/2009/06/auto-refreshing-adf-chart-objects-in.html].
    This example works fine, but I want an Application Module Root which contains the Application Module which contains the VO where there is the method processDatabaseChangeNotification.
    I have trying all the configuration possible of AppModuleRoot and AppModuleChild: Shared/Local, Local/Shared and even Local/Local ... but nothing works ...
    Can you tell me if possible, and if so ... how?
    thanks !
    (I use jdev11g)

    I don't find my reponse in the documentation....
    I have an AM Child in an AM Root like that :
    <AppModuleUsage
    Name="AppModuleChild"
    FullName="model.AppModuleChild"
    ConfigurationName="model.AppModuleChildShared"
    SharedScope="2" />
    My AM Root is Shared in the file "DataBinding.cpx" :
    <BC4JDataControl id="AppModuleRootDataControl" Package="model"
    FactoryClass="oracle.adf.model.bc4j.DataControlFactoryImpl"
    SupportsTransactions="true" SupportsFindMode="true"
    SupportsRangesize="true" SupportsResetState="true"
    SupportsSortCollection="true"
    Configuration="AppModuleRootShared" syncMode="Immediate"
    xmlns="http://xmlns.oracle.com/adfm/datacontrol"/>
    ... and the database change event notification don't work... I don't understand !

  • Database change in production system

    Hi Experts
                I have created a ztable and transported to production system.
               Now i need to delete one column, or change the data element and domain, is it possible, will it create any problems.
            if data already exists for a particular field in production system, now can i change the data element and domain without losing the data.
               Pls help me on this, and give any notes about the database changes after transported to producion system.
    Regards
    Rajarm

    Hi..
    I tried this..
    If  u rename a field or changes occuring to a paricular field means..
    The corresponding field data will be deleted..
    Post me for furthur Queries regarding this.
    Regards
    Bala..

  • How to Synchronize 2010 content database of my site (Web Application port 8080) to Sharepoint 2013 content database

    Hello,
    I am migrating Sharepoint 2010 my site content database to SharePoint 2013. First I have to create My site web application  in SharePoint 2013. How can I synchronize 2010 content database with 2013.

    Hi ghsajith,
    According to your description, my understanding is that you want to upgrade your SharePoint 2010 to SharePoint 2013.
    There is an article for your reference:
    http://blogs.msdn.com/b/alimaz/archive/2012/07/17/upgrading-from-sharepoint-2010-to-sharepoint-2013-step-by-step.aspx
    I hope this helps.
    Thanks,
    Wendy
    Wendy Li
    TechNet Community Support

  • Reduce Size or delete unwanted entries from tables AllDocStreams,AllDocVersions,EventCache,EventLog of Sharepoint 2010 content database

    Size or delete unwanted  entries from tables AllDocStreams,AllDocVersions,EventCache,EventLog  of Sharepoint 2010 content database:
    We using  powershell  scripts to migrate data between   two  sharepoint  2010 sites .
    While  doing migration  we  delete all  document libraries  & list  form  destination  site  and then run  powershell to migrate data from  source to destination. We following this  process
    twice in a week.
    But in doing  so  we found the above mention tables (AllDocStreams,AllDocVersions,EventCache,EventLog ) of destination Sharepoint Content database  are growing at an alarming rate. 
    Wish to know  how  could get rid of  unwanted  data stored in these tables.

    Hi,
    This is old thread but here is your answer for some of the tables you mentioned
    http://blogs.msdn.com/b/sowmyancs/archive/2012/06/29/alldocversions-amp-alldocstreams-table-size-after-upgrading-to-sharepoint-2010.aspx
    Cheers

Maybe you are looking for

  • Using the end routine to populate the Cubes

    Hi BI Gurus, I am having following requirement: DSO: ZODS1  - > This DSO gets all the raw data from Source system. DSO:ZODS4   - >  Updates ZCUBE4        ,ZODS5    - > Updates ZCUBE5 there is no data flow between ZODS1 and  ZODS4                     

  • EA2700 and remote accessing DVR

    Does anyone have a solution for router settings to allow remote access to DVRs both windows and Linux? Solved! Go to Solution.

  • No iframe possible after 10.8.5 update

    I have a iframe on a webserver with content of my osx server. (works fine on 10.8.4) after the update to 10.8.5 the iframe is empty. Where I can tell my server to accept iframing to this webserver. X-Frame-Options ALLOW-FROM

  • My photos have stopped uploading to my pc/photostream.

    Photos were uploading until 10/2013, then just stopped.   I have seen several posts regarding this problem and tried a few solutions.  Most recently, signing out an back into to iCloud, but no results.

  • Ability to control LabVIEW VIs through a standard Web browser

    Ability to control LabVIEW VIs through a standard Web browser? Do you know where I can get information on doing this? I want to be able to control Labview Vis through the web. Best regards, Krispiekream Solved! Go to Solution.