silvioprog wrote / napísal(a):
2013/9/11 LacaK <la...@zoznam.sk <mailto:la...@zoznam.sk>>
silvioprog wrote / napísal(a): Now doing more tests. I see, that
in pgAdmin when I use right click on table and use "View Data"
then '' (two single quotes) are shown in TEXT column, but when I
use SQL and type:
select * from <table name> then empty fields are shown ... so it
seems to me, that bug is in pgAdmin, does not ?
-Laco.
The bug is in FCL. Please see the steps in my comparison:
1. first I inserted a record via pgAdmin: insert into test (id,
fieldtext) values (1, null);
Try in pgAdmin do:
insert into test (id, fieldtext) values (1, '');
Then use "View Data" and you will see two single quotes instead of empty
cell.
2. after, I executed this demo: http://pastebin.com/HS8DZkDV;
3. finally, I made this selection in pgAdmin:
select * from test
where fieldtext is null;
And the result is:
id | fieldtext
-----------------
1 |
But, when I select so:
select * from test
where fieldtext = ''
The result is:
id | fieldtext
-----------------
2 |
Then SQLdb is saving an empty string instead of null. :o
Yes it is true for your version of bufdataset.pas, but it is fixed in trunk.
L.
_______________________________________________
fpc-pascal maillist - fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal