View and adjust your enterprise and business systems (Ⅱ: COM +, ASP) (ccBoy original)

Source: Internet
Author: User
Tags dotnet error code soap wsdl
And adjust your business and business systems (Ⅱ: COM +, ASP)
Stingy gods
The first step starts in the three procedures mentioned in the previous article. The environment requires two machines, one for SQL Server, the other for App and IIS installation. Simulate the common Windows DNA structure and call the Biz component in ASP. I omitted the Client of VB. I chose IE as the Client. The only thing I want to verify is that the architecture and components are OK.
This article has nothing to do with dotNET, because there was no dotNET technology at that time, in order to simulate a more realistic reality, such as a complicated logic with transaction requirements, I decided to put SQL Server and components on two machines.
Content I chose the Author table of the Pub database that comes with SQL Server as the prototype. When I look at some of the original application code and components, I find that the entire code is generally divided into two types: one is to complete a business and business logic operation, bringing necessary parameters to the Biz component, the Biz component calls other Biz components or DB components to complete the required operations, and then returns a simple data type back to the presentation layer. For example, a String (error description), a Long type (indicating a serial number, serial number, or error code), and a large amount of data returned after a query or an operation, fortunately, I am used to using ADODB. the Recordset is used to return a large amount of data. Therefore, this type of data is very uniform and generally is ADODB. the return value of the Recordset type. In addition, Variant is rarely connected. The structure type defined by myself is almost zero in the return value of the Biz layer.
For WebService, data is unified into XML format. I began to imagine what the ADODB. Recordset will look like in XML? How does the client use ADO data in XML format? Almost the first reaction was to use Microsoft SOAP Toolkit to solve this problem, so I was curious about the WSDL file generated by the SOAP Toolkit. I wanted to know what kind of WSDL would be returned for this kind of ADODB. Recordset. In fact, the results of future tests are frustrating. However, the problem was exposed earlier, that is, how the custom or non-SOAP-supported data types are processed. Currently, the problem is concentrated on the data types such as ADODB. Recorset. These problems determine the db and Biz components to be generated.
The DB component is not special. I decided to directly call these DB components without any logic. In fact, Biz may be very complicated and call many other Biz or DB components, however, it usually has only one result at the end: Success or failure, or a group of data, that is, the two types I have classified above. So I started to use a similar Update and Delete functions:
Public Function DeleteAuthor (ByVal au_id As String) As Long
To simulate the first type to return a single data type supported by SOAP. The actual application may be:
Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.