Apache derby 中的存储过程

发布于 2024-11-17 19:34:51 字数 118 浏览 4 评论 0 原文

我们可以在 Eclipse 的 apache derby 数据库连接中创建带有选择、插入、更新(多个 SQL 语句)的存储过程吗?

我是android开发的初学者,所以请告诉我创建和使用存储过程的正确方法。

Can we create stored procedure with select, insert, update (multiple SQL statement) in apache derby database connection with Eclipse??

I am a beginner in android development, so please show me the proper way to create and use stored procedure.

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

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

发布评论

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

评论(3

瞄了个咪的 2024-11-24 19:34:51

需要澄清的是,这些并不是熟悉 Oracle 和 MS SQL Server 的人所认为的经典意义上的“存储过程”。

根据 @Bryan 答案中的 链接 以及线程 关于Derby 存储过程,这些“存储过程”是编译的Java 代码,而不是SQL。这就是所谓的 PSM,尽管谷歌搜索“Derby PSM”会出现一些有趣的结果,但它并没有看起来还没有完全烤熟。

Just to clarify, these are not "stored procedures" in the classic sense that people familiar with Oracle and MS SQL Server would think of them.

Per the link in @Bryan 's answer, as well as the thread Regarding Derby Stored Procedures, these "stored procedures" are compiled Java code, not SQL. That's called PSM and although googling for "Derby PSM" turns up some interesting results, it doesn't look fully-baked yet.

£噩梦荏苒 2024-11-24 19:34:51

Apache Derby 当然有存储过程。从这里开始获取一些有用的信息:http://wiki.apache.org/db-derby/DerbySQLroutines< /a>

不过,我不确定“android 开发”部分。

Apache Derby certainly has stored procedures. Start here for some good information: http://wiki.apache.org/db-derby/DerbySQLroutines

I'm not sure about the "android development" part, though.

萌无敌 2024-11-24 19:34:51

在 Derby 中创建存储过程是完全可能的。
为此,您:

  1. 使用 Java 编程语言制作存储过程逻辑
  2. 打包并将 Java 逻辑部署到 Derby
  3. 创建包装/调用 Java 逻辑的存储过程。
  4. 使用 JDBC 调用存储过程。

这篇帖子提供了分步演练,准确描述了如何执行以上4步。

It is absolutely possible to create a stored procedure in Derby.
To do so, you:

  1. Craft stored procedure logic using the Java programming language
  2. Package and deploy the Java logic to Derby
  3. Create a stored procedure that wraps / calls the Java logic.
  4. Call the stored procedure using JDBC.

This post provides a step by step walkthrough describing exactly how to perform the above 4 steps.

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