There appears to be a bug with the .setHidden() method of the GridEditor fluid API. When updating a record the value of the hidden column is not remembered and therefore NULL is used.
Here is a sample table:
create table customers (
id INT primary key,
first_name VARCHAR(50),
last_name VARCHAR(50),
email VARCHAR(50),
city VARCHAR(50)
);
insert into customers (id, first_name, last_name, email, city) values (1, 'Ruth', 'Walker', 'rwalker0@ezinearticles.com', 'Kyaiklat');
insert into customers (id, first_name, last_name, email, city) values (2, 'Stephanie', 'Black', 'sblack1@com.com', 'Risaralda');
insert into customers (id, first_name, last_name, email, city) values (3, 'Ruby', 'Murphy', 'rmurphy2@phoca.cz', 'Nanger');
insert into customers (id, first_name, last_name, email, city) values (4, 'Arthur', 'Lewis', 'alewis3@furl.net', 'Makilala');
insert into customers (id, first_name, last_name, email, city) values (5, 'Jeremy', 'Robertson', 'jrobertson4@biglobe.ne.jp', 'Káto Miliá');
And here is a a sample report:
def adapter = gridHelper.initDbGridEditor()
adapter.configure(report, "customers")
.setPk("id")
.columns()
.add("id")
.add("first_name", "First Name")
.add("last_name", "Last Name")
.add("email", "Email").setHidden(true)
.add("city", "City")
.done()
return adapter
And here is a workflow:
- Current state of data
select * from customers
id first_name last_name email city
--- ------------ ------------ ---------------------------- -----------
1 Ruth Walker rwalker0@ezinearticles.com Kyaiklat
2 Stephanie Black sblack1@com.com Risaralda
3 Ruby Murphy rmurphy2@phoca.cz Nanger
4 Arthur Lewis alewis3@furl.net Makilala
5 Jeremy Robertson jrobertson4@biglobe.ne.jp Káto Miliá
-
Edit a row

-
The email is now NULL
select * from customers
id first_name last_name email city
--- ------------ ------------ --------------------------- -------------
1 Ruth QQQQQ NULL Kyaiklat
2 Stephanie Black sblack1@com.com Risaralda
3 Ruby Murphy rmurphy2@phoca.cz Nanger
4 Arthur Lewis alewis3@furl.net Makilala
5 Jeremy Robertson jrobertson4@biglobe.ne.jp Káto Miliá
This does not seem to happen if you use the “Edit” button to open the window to change the row.
You can prevent data loss by using .setEditable(false).setWidth(0), but it looks a little weird in the UI:

Versions
SQL Server 2008 SP3
ReportServer RS3.0.2-5855 (2016-05-29-17-55-24)