database - Oracle:LONG 还是 CLOB?

标签 database oracle clob

从这两个线程,

LONG 已过时且已弃用。 Oracle says ,

Do not create tables with LONG columns. Use LOB columns (CLOB, NCLOB) instead. LONG columns are supported only for backward compatibility.

Oracle also recommends that you convert existing LONG columns to LOB columns. LOB columns are subject to far fewer restrictions than LONG columns. Further, LOB functionality is enhanced in every release, whereas LONG functionality has been static for several releases.

但是如果没有 the workarounds mentioned here,您将无法从远程数据库中读取 CLOB .

我应该选择哪一个来在我的表格中存储一些文本?或者有比这两个更好的解决方案吗?

最佳答案

使用 CLOB。 LONG 的局限性之一是无法从 SQL - PL/SQL 正确处理 LONG。

有关差异的更详细说明,请参阅 http://www.comp.dit.ie/btierney/oracle11gdoc/appdev.111/b28393/adlob_tables.htm#insertedID2

关于database - Oracle:LONG 还是 CLOB?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/3599211/

相关文章:

mysql - 为每个页面加载查询我的数据库是否安全?

database - Web 服务器前端或数据库服务器后端的 Redis

database - 如何使用 oracle-10g 在层次结构查询中获取根祖先?

java - 如何扩展由 Liquibase 实现的数据库模式?

database - Oracle Clob 内部是如何处理的?

database - DB2:从表中清除大量记录

mysql - 一张表为其他表提供 id : good or bad?

oracle - 如何解决 SP2-0552 : Bind variable not declared?

sql - 如何在 Oracle 中查询 CLOB 列

java - 使用 SQLite JDBC 适配器处理 CLOB