테이블생성, 마크다운 형태의 데이터는 Blob이 아닌 Clob으로 그리고 varchar2 4000이 넘을 수 있으니 Clob으로.
create table x230303_markdown (
fid number generated by default on null as identity
constraint x230303_markdown_id_pk primary key,
md_vc varchar2(4000 char),
md_clob clob,
md_blob blob
)
;
-- load data
-- Generated by Quick SQL Sunday March 05, 2023 10:07:00
/*
x230303_markdown
fid /pk
md_vc
md_clob clob
md_blob blob
# settings = { semantics: "CHAR", language: "EN", APEX: true }
*/
Dynamic Content
declare
l_clob x230303_markdown.md_clob%type;
c_embedded_html_escape constant APEX_MARKDOWN.t_embedded_html_mode := 'ESCAPE'; -- escapes HTML
c_embedded_html_preserve constant APEX_MARKDOWN.t_embedded_html_mode := 'PRESERVE'; -- leaves HTML content as-is
begin
select md_clob
into l_clob
from x230303_markdown where fid = (select max(fid) from x230303_markdown);
return apex_markdown.to_html(p_markdown => l_clob
, p_embedded_html_mode => c_embedded_html_escape
, p_softbreak => '<br />'
, p_extra_link_attributes=> apex_t_varchar2()
);
end;
APEX_MARKDOWN.TO_HTML
참고
https://inasie.github.io/it%EC%9D%BC%EB%B0%98/%EB%A7%88%ED%81%AC%EB%8B%A4%EC%9A%B4-%ED%91%9C-%EB%A7%8C%EB%93%A4%EA%B8%B0/
https://blogs.oracle.com/apex/post/native-markdown-support-in-apex-211
https://blogs.oracle.com/apex/post/whats-new-for-report-regions-apex-212
https://apex.oracle.com/pls/apex/r/gamma_dev/demo/markdown
https://apexapplab.dev/2021/04/27/apex-markdown-the-story-continues/
https://theorydb.github.io/envops/2019/05/22/envops-blog-how-to-use-md/#markdown-%EB%AC%B8%EB%B2%951%EB%B0%98%EB%93%9C%EC%8B%9C-%EC%95%8C%EC%95%84%EC%95%BC-%ED%95%98%EB%8A%94
댓글 없음:
댓글 쓰기