Quantcast
Channel: SCN: Message List - SAP HANA Developer Center
Viewing all articles
Browse latest Browse all 9165

Re: XSJS Charset problem on SP9

$
0
0

You are using the wrong get function. 

JSDoc: Class: ResultSet

 

getString(columnIndex)→ {string}

Returns a string value of the specified column. getString is used for CHAR and VARCHAR column types. ASCII only, not suitable for strings containing Unicode characters.

 

getNString(columnIndex)→ {string}

Returns a string value of the specified column. getNString is used for NCHAR, NVARCHAR, SHORTTEXT column types.

 

I'm not sure why it even worked on SPS 08.  It really shouldn't have.

 

I might point out that if you are on SPS 09, you can use the new database interface which directly returns JSON and doesn't require the use of any type specific get or set functions.  This would also avoid your problem.

JSDoc: Namespace: hdb

 

http://scn.sap.com/community/developer-center/hana/blog/2014/12/02/sap-hana-sps-09-new-developer-features-new-xsjs-database-interface


Viewing all articles
Browse latest Browse all 9165

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>