On Sun, Jan 20, 2013 at 11:12 AM, Staffan Tylen <staffan.ty...@gmail.com>wrote:

>
> I think it's important that whatever method is chosen, the
>>> stringValueForNil option be included in one way or another.
>>>
>>
>> It could just be the empty string always.
>>
>>
> Well, it could, but the documentation for SQLite is very specific when it
> comes to the NULL value, which is translated to .NIL by ooSQLite. NULL is
> NOT the same as the empty string, rather NULL means 'undefined'.
>

That's true about SQLite and SQL in general.


> So by always setting the empty string one looses the possibility
> to differentiate between NULL and an empty string.
>

In a list-view you have to set the item text to some text.  If you always
set the empty string to NULL in your database, then the empty string in
your list-view would always represent NULL.

Anyway, I'm not really arguing against having an argument to specify what
string to use for the list-view if an array index is .nil, I'm just saying
if you are looking for a way to optimize list-view insertion time for a
large number of items, then you will get better performance by not being
able to specify alternate strings to use.  You will get better performance
by having a standard string that is always used.

For the specific case you brought up, the optimal thing would be for the
string to be "The NIL object"  There would be 0 extra machine instructions
for that.

--
Mark Miesfeld
------------------------------------------------------------------------------
Master Visual Studio, SharePoint, SQL, ASP.NET, C# 2012, HTML5, CSS,
MVC, Windows 8 Apps, JavaScript and much more. Keep your skills current
with LearnDevNow - 3,200 step-by-step video tutorials by Microsoft
MVPs and experts. ON SALE this month only -- learn more at:
http://p.sf.net/sfu/learnmore_123012
_______________________________________________
Oorexx-users mailing list
Oorexx-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/oorexx-users

Reply via email to