rcdmk / aspJSON

A fast classic ASP JSON parser and encoder for easy JSON manipulation to work with the new JavaScript MV* libraries and frameworks.
MIT License
203 stars 89 forks source link

Type mismatch: 'char' #59

Closed nuclearsiloman closed 6 years ago

nuclearsiloman commented 6 years ago

Hi, I've used your parser before without any issues but I'm scratching my head on this one. I have LCID=1033 and the query below runs fine by itself.

set JSON = New JSONobject
query="SELECT top(1) TABLE_NAME FROM db1.INFORMATION_SCHEMA.TABLES WHERE TABLE_TYPE = 'BASE TABLE' order by table_name asc"
set connTemp = server.createobject("adodb.connection")
connTemp.Open scDSN  
set rs=server.CreateObject("ADODB.RecordSet")
set rs=connTemp.execute(query)
JSON.LoadRecordset rs

set rs=nothing response.clear() JSON.Write()

I get: Microsoft VBScript runtime error '800a000d' Type mismatch: 'char' /store/boomerrang/jsonObject.class.asp, line 915

What do you think the issue may be?

nuclearsiloman commented 6 years ago

If I comment out: 'result = replace(result, char(8), "\t") works beautifully! Of course I don't want to do that though....

rcdmk commented 6 years ago

Hi. I've introduced this bug in the current release. Sorry.

A fix is already ongoing. I will publish it soon.

nuclearsiloman commented 6 years ago

Ah thanks! I'll keep an eye out for it. Great work.

rcdmk commented 6 years ago

This is fixed with #56.

Thanks.