Why Use XML while Schema is same ??

Discussion in 'XML' started by Atif, Apr 4, 2004.

  1. Atif

    Atif Guest

    Hi
    I have read about XML and its use for transferring data. I have alot
    of mis conceptions. Let's take an example
    I have database at two locations L1 and L2, both locations are using
    different DBMSs but having same schema(datatypes and other rules). If
    i want to transfer data from L1 to L2, it 's not a web based
    application. More precisely, i would make connection with L2 and will
    request data through SQL query into the recordset. Would using XML
    make any sense here that first the data will be converted into xml
    from L2 and then this XML will be sent to L1, then L1 will retrieve
    the data from XML file, why not directly transfer the data?? If i
    would have different Schemas on L1 and L2, how XML will work here??
    please clear my concepts, if don't have time try to give suggestions
    atleast.
    Thanks
     
    Atif, Apr 4, 2004
    #1
    1. Advertising

  2. In article <>,
    Atif <> wrote:

    % I have database at two locations L1 and L2, both locations are using
    % different DBMSs but having same schema(datatypes and other rules). If
    % i want to transfer data from L1 to L2, it 's not a web based
    % application. More precisely, i would make connection with L2 and will
    % request data through SQL query into the recordset. Would using XML
    % make any sense here that first the data will be converted into xml

    If you are writing the software that connects to L1 and the software
    that connects to L2, then there's nothing to be gained from using XML in
    this process. You might as well use the data structures and message
    structures that are most efficient and have a promotion strategy which
    keeps both pieces of software in synch (assuming it's more than one
    program).

    If you have different people writing the software for L1 than are
    writing the software for L2, then you need to agree on the way you'll
    encode the data when handing it off. XML provides a framework which will
    make this simpler. That is, rather than saying `a message begins with a
    10 byte header of which the first four bytes are the length as a two's
    complement integer in network byte order ...' you can say `a message is
    an XML document with the following elements ...' and never worry about
    they syntactic details.

    It doesn't make any difference whether the schemas are the same or
    different. In general, you'll have both situations, and will need to
    handle both within a single application. I'm not convinced that XML
    makes it easier to define the mappings between two structures, but you
    can use XSLT if your data is XML, and you can't use XSLT if your data is
    not XML.

    There are canned applications for performing this kind of operation.
    --

    Patrick TJ McPhee
    East York Canada
     
    Patrick TJ McPhee, Apr 5, 2004
    #2
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Markus
    Replies:
    1
    Views:
    1,537
    Markus
    Nov 23, 2005
  2. Fred Smith
    Replies:
    1
    Views:
    946
    Martin Honnen
    Feb 5, 2004
  3. Stanimir Stamenkov
    Replies:
    3
    Views:
    1,261
    Stanimir Stamenkov
    Apr 25, 2005
  4. Mr. SweatyFinger
    Replies:
    2
    Views:
    1,948
    Smokey Grindel
    Dec 2, 2006
  5. Replies:
    3
    Views:
    2,863
Loading...

Share This Page