通过 Web 服务发送 MySQL 查询结果的好方法? [英] A good way to send the results from a MySQL query over a Web Service?

查看:37
本文介绍了通过 Web 服务发送 MySQL 查询结果的好方法?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我一直在尝试找出一种简单的好方法,通过我的网络服务发送 MySQL 查询的结果.

I've been trying to figure out a good and easy way to send the results of a MySQL Query over my Web Service.

我研究了很多很好的方法,比如数据传输对象,但我希望它尽可能简单.在这一点上,简单地让它工作具有更高的优先级.:)

There is a lot of good methods that I've looked into, like Data Transfer Object, but I would like to keep it as simple as possible. At this point simply getting this to work has a higher priority. :)

欢迎任何帮助或文档,即使是在更困难的主题上,但如上所述,此时越简单越好.

Any help or documentation is welcome, even on more difficult topics, but as mentioned above the simpler the better at this point.

推荐答案

当你说公开你的结果时,你是否也意味着动态查询?例如 Wcf 数据服务

when you say expose your results, do you also mean dynamic querying? such as Wcf Data Services

但是,请注意您公开信息的内容和方式.回去修复它很痛苦.

However be careful on what and how you expose information. It is a pain to go back and fix it.

对于 SOA 或 3 个物理层,我会考虑使用

for SOA or a 3 physical Tier I would consider using

  • 服务层
  • 数据传输对象,它们很棒,直接暴露数据可能会导致可维护性/可变性问题

为了帮助 DTO 了解 AutoMapper,它是为它而设计的.

to help with DTO's look at AutoMapper, it was designed for it.

如果我错过了一点,请添加评论

if I have missed a point, add a comment

ps 这里有一个很棒的有用模式列表PoEAA Catalogue

ps here is a great list of helpful patterns PoEAA Catalogue

这篇关于通过 Web 服务发送 MySQL 查询结果的好方法?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆