Coldfusion 中的 ORM,现有的 cfqueries

发布于 2024-12-22 19:31:50 字数 184 浏览 1 评论 0原文

我正在开发一个使用 Coldfusion(cfquery 标签和存储过程)构建的网站。

我正在考虑学习/将网站转移到 ORM,但我想知道这会涉及多复杂。

例如,我可以使用 ORM 来构建新页面来检索数据,然后慢慢将旧页面转换为 ORM 吗?

或者打开 ORM 是否会破坏我的网站上当前使用的查询和存储过程?

I'm working on a site built with Coldfusion (cfquery tags and stored procedures).

I'm considering learning / moving the site over to ORM, but I was wondering how involved / complicated this would be.

For example, can I build new pages going forward using ORM to retrieve my data, and then slowly convert my older pages to ORM?

Or does turning on ORM break the queries and stored procedures currently being used on my site?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(2

笑梦风尘 2024-12-29 19:31:50

是的,您可以“使用 ORM 构建新页面来检索(您的)数据,然后慢慢将(您的)旧页面转换为 ORM?”

对于复杂的查询,继续使用现有的东西,ORM 不会对你有太大帮助。

无需进行完整的 OO,您可以使用 ORM 来帮助您进行 CRUD,而无需编写一行 SQL。

yes, you may "build new pages going forward using ORM to retrieve (your) data, and then slowly convert (your) older pages to ORM?"

For complex query, keep using what you had, ORM will not help you much.

Without doing full OO, you can use ORM to help you do CRUD without coding a line of SQL.

空心↖ 2024-12-29 19:31:50

Henry 的回答很好,但我想到了一个问题:如果您有一个已经可以工作的网站,为什么要对其进行修改以将其转换为使用 Hibernate?您在这里感受到的好处是什么?我并不是说没有(〜根本没有。我并不是说没有充分的理由:这不是一个加载的问题),但我会犹豫是否要在没有良好的情况下弄乱网站的工作代码原因。

如果您确实决定进行更改,我会大量负载测试“更改​​之前”和“之后”。

Henry's answer is a good 'un, but one question occurs to me: if you have an already working site, why would you mess with it to convert it to using Hibernate? What's the benefit you're perceiving here? I'm not saying there isn't one (~ at all. I don't mean to suggest there is no good reason: this is not a loaded question), but I would be hesitant to mess with a site's working code without good reason.

And if you do decide to make the change, I would heavily load test the "before" and "after" change.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文