Given the following test setup:
create table shtest (
a int,
b int
);
insert into shtest values (0, null);
insert into shtest values (1, 1);
insert into shtest values (2, null);
insert into shtest values (3, null);
insert into shtest values (4, 4);
insert into shtest values (5, null);
The command:
shsql $HANDLE "select * from shtest";
...returns the following:
"0" ""
"1" "1"
"2" "1"
"3" "1"
"4" "4"
"5" "4"
So what's happening is that when it encounters a null
in the second column AFTER having previously returned a
value in that column, it's simply returning the value
it had for that column in the previous row for EVERY
row until it has a new value. More to the point, some
value isn't getting zeroed out in the loop.
I'm currently using ms-sql, so connecting through
freetds. I have not yet had an opportunity to test
against other data sources. Nor do I have the time
now, though I'm curious to try, to work through
debugging this. If I manage, I will submit a patch,
but I'm not sure how soon I'll be able to do that.
Nobody/Anonymous
None
None
Public
|
Date: 2006-03-24 12:52 Logged In: YES |
| Field | Old Value | Date | By |
|---|---|---|---|
| status_id | Open | 2006-03-24 12:52 | jfouse |
| resolution_id | None | 2006-03-24 12:52 | jfouse |
| close_date | - | 2006-03-24 12:52 | jfouse |