{ "id": "62867", "key": "TIMOB-2235", "fields": { "issuetype": { "id": "1", "description": "A problem which impairs or prevents the functions of the product.", "name": "Bug", "subtask": false }, "project": { "id": "10153", "key": "TIMOB", "name": "Titanium SDK/CLI", "projectCategory": { "id": "10100", "description": "Titanium and related SDKs used in application development", "name": "Client" } }, "fixVersions": [ { "id": "11229", "name": "Release 1.5.0 M04", "archived": true, "released": true, "releaseDate": "2010-12-06" } ], "resolution": { "id": "1", "description": "A fix for this issue is checked into the tree and tested.", "name": "Fixed" }, "resolutiondate": "2011-04-17T01:58:29.000+0000", "created": "2011-04-15T03:14:23.000+0000", "priority": { "name": "Low", "id": "4" }, "labels": [ "database", "defect", "ios", "iphone" ], "versions": [], "issuelinks": [], "assignee": { "name": "rseagraves", "key": "rseagraves", "displayName": "Reggie Seagraves", "active": true, "timeZone": "America/Los_Angeles" }, "updated": "2011-04-17T01:58:29.000+0000", "status": { "description": "The issue is considered finished, the resolution is correct. Issues which are closed can be reopened.", "name": "Closed", "id": "6", "statusCategory": { "id": 3, "key": "done", "colorName": "green", "name": "Done" } }, "components": [ { "id": "10206", "name": "iOS", "description": "iOS Platform" } ], "description": "{html}

CREATE TABLE foo (myColumn INT);

\n

var rs = db.execute(\"SELECT myColumn FROM foo\");
\nalert(rs.fieldName(0));

\n

On android, the output is 'myColumn'.
\nOn iphone, the output is 'mycolumn'. This is wrong.

\n

The root cause is logic which provides case-insensitive matching\nfor rs.fieldByName('mycolumn'). This behavior is correct, but the\nrs.fieldName(0) behavior is not (on iphone only).

\n

I've already fixed this in my titanium branch. I've created a\nmerge request here: http://github.com/appcelerator/titanium_mobile/pull/11

{html}", "attachment": [], "flagged": false, "summary": "Ti.Database.ResultSet.fieldName() mangles the database column names", "creator": { "name": "nathanielmccallum", "key": "nathanielmccallum", "displayName": "Nathaniel McCallum", "active": true, "timeZone": "America/Los_Angeles" }, "subtasks": [], "reporter": { "name": "nathanielmccallum", "key": "nathanielmccallum", "displayName": "Nathaniel McCallum", "active": true, "timeZone": "America/Los_Angeles" }, "environment": null, "comment": { "comments": [ { "id": "127903", "author": { "name": "jhaynie", "key": "jhaynie", "displayName": "Jeff Haynie", "active": false, "timeZone": "America/Los_Angeles" }, "body": "{html}

(from [555db6980b222bb3a24074e4d1fad28564f3c885])\n[#2235 state:open] (Requires test before sending\nto QA) don't mange sql column names for ResultSet.fieldName(), but\nstill preserve case insensitive search for\nResultSet.fieldByName()
\n\nhttp://github.com/appcelerator/titanium_mobile/commit/555db6980b222...

{html}", "updateAuthor": { "name": "jhaynie", "key": "jhaynie", "displayName": "Jeff Haynie", "active": false, "timeZone": "America/Los_Angeles" }, "created": "2011-04-15T03:14:24.000+0000", "updated": "2011-04-15T03:14:24.000+0000" }, { "id": "127904", "author": { "name": "dthorp", "key": "dthorp", "displayName": "Don Thorp", "active": true, "timeZone": "America/Los_Angeles" }, "body": "{html}

Merge complete. Assigning to Blain for test.

{html}", "updateAuthor": { "name": "dthorp", "key": "dthorp", "displayName": "Don Thorp", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2011-04-15T03:14:24.000+0000", "updated": "2011-04-15T03:14:24.000+0000" }, { "id": "127905", "author": { "name": "blainhamon", "key": "blainhamon", "displayName": "Blain Hamon", "active": true, "timeZone": "America/Los_Angeles" }, "body": "{html}

Didn't we fix this? Shouldn't it be fixed-in-qa?

{html}", "updateAuthor": { "name": "blainhamon", "key": "blainhamon", "displayName": "Blain Hamon", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2011-04-15T03:14:24.000+0000", "updated": "2011-04-15T03:14:24.000+0000" }, { "id": "127906", "author": { "name": "nathanielmccallum", "key": "nathanielmccallum", "displayName": "Nathaniel McCallum", "active": true, "timeZone": "America/Los_Angeles" }, "body": "{html}

yup.

{html}", "updateAuthor": { "name": "nathanielmccallum", "key": "nathanielmccallum", "displayName": "Nathaniel McCallum", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2011-04-15T03:14:25.000+0000", "updated": "2011-04-15T03:14:25.000+0000" }, { "id": "127907", "author": { "name": "stephentramer", "key": "stephentramer", "displayName": "Stephen Tramer", "active": true, "timeZone": "America/Los_Angeles" }, "body": "{html}

iPod 3GT 4.2.1, 1.5.0.a899d42

{html}", "updateAuthor": { "name": "stephentramer", "key": "stephentramer", "displayName": "Stephen Tramer", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2011-04-15T03:14:25.000+0000", "updated": "2011-04-15T03:14:25.000+0000" } ], "maxResults": 5, "total": 5, "startAt": 0 } } }