oracle to_char()不同语言显示垃圾

时间:2016-02-12 10:57:26

标签: sql oracle

在我的oracle函数中,有一个查询用于生成具有所需值的XML输出。一切正常。如果我将一个孟加拉语/孟加拉语名称存储在一个列中,那么它会完美地返回我的网站,但是当我想在孟加拉语/孟加拉语中查看日期时会出现问题。以下查询有2列作为日期。我用to_char()来格式化它们。

SELECT XMLAGG(XMLElement("employee", 
                           XMLForest(bp.ebasp_id AS "ebasp_id",
                                     bp.b_ebasp_name AS "ebasp_name",
                                     bp.ebasp_gender AS "ebasp_gender",
                                     bp.ebasp_category AS "ebasp_category",
                                     bp.ebasp_region_type AS "ebasp_region_type",
                                     bp.ebasp_region_name AS "ebasp_region_name",
                                     bp.ebasp_sub_region AS "ebasp_sub_region",
                                     bp.ebasp_location AS "ebasp_location",
                                     bp.b_ebasp_designation AS "ebasp_designation",
                                     to_char(bp.ebasp_date_of_joining,'DD-MM-YYYY','NLS_DATE_LANGUAGE=bangla') AS "ebasp_date_of_joining",
                                     bp.ebasp_grade AS "ebasp_grade",
                                     bp.ebasp_slab AS "ebasp_slab",
                                     bp.ebasp_basic AS "ebasp_basic",
                                     bp.ebasp_photo_upload AS "ebasp_photo_upload",
                                     to_char(bp.ebasp_created_on, 'DD-MM-YYYY HH:MI:SS AM','NLS_DATE_LANGUAGE=bangla') AS "ebasp_created_on",
                                     bp.ebasp_created_by AS "ebasp_created_by")))
  INTO xmlReturn
  FROM tbl_emp_basic_profile bp
  WHERE bp.ebasp_designation=sent_designation

返回的日期值为:07-02-2016 03:43:29
该值显示在Mozilla中。但名字在孟加拉完美展现。问题是什么?此外,我尝试使用to_nchar();

0 个答案:

没有答案