Announcement

Migration of this forum

Dear users of this forum,

we are pleased to inform you that we will be updating the software behind this forum in the near future.

Existing posts, users and categories will remain untouched.

Important:

  • Each user will need to reset their password.
  • Please select "I forgot my password".
  • Enter the email address you used to register in this forum.
  • You will receive an email with a link to set a new password.
  • Please choose a new (secure) password and confirm the process.

We will keep you informed in the pinned thread.

Kind regards,
Your ReportServer Team


Migration des Forums

Liebe Nutzer dieses Forums,

wir freuen uns, euch mitteilen zu können, dass wir in naher Zukunft die Software hinter diesem Forum aktualisieren werden.

Existierende Beiträge, Nutzer und Kategorien bleiben weiterhin bestehen!

Wichtig:

  • Jeder Nutzer muss sein Passwort neu vergeben.
  • Wählt dazu einfach "Ich habe mein Passwort vergessen".
  • Gebt die E-Mail-Adresse ein, mit der ihr registriert seid.
  • Ihr erhaltet eine E-Mail mit einem Link zur Passwortvergabe.
  • Bitte wählt ein neues (sicheres) Passwort und bestätigt den Vorgang.

Wir halten euch im angepinnten Beitrag auf dem Laufenden!

Mit vielen Grüßen
Euer ReportServer Team

#1 2016-11-03 20:58:15

phillipjohnson
Member
From: Columbus, OH, USA
Registered: 2016-11-03
Website

Support for NVARCHAR in GridEditor

It appears that the NVARCHAR datatype may not be supported in the grid editor report. When specifying an NVARCHAR column, the data does not appear in the UI.

z2lY2vn.png

Here is my SQL:

create table customers (
	id INT primary key,
	first_name VARCHAR(50),
	last_name VARCHAR(50),
	email VARCHAR(50),
	city NVARCHAR(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á');

Here is my report code:

def adapter = gridHelper.initDbGridEditor()

adapter.configure(report, "customers")
    .setPk("id")
    .columns()
        .add("first_name", "First Name")
        .add("last_name", "Last Name")
        .add("email", "Email")
        .add("city", "City")
    .done()

return adapter

If I change the datatype of the city column to VARCHAR, it works correctly.

30sB4bg.png

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

Offline

#2 2016-11-04 13:45:57

IF_Eduardo
Administrator
Registered: 2016-11-01
Website

Re: Support for NVARCHAR in GridEditor

Hello phillipjohnson,

you can try changing the report query to return a varchar instead of an nvarchar:

select ...,
CONVERT(VARCHAR(50), [city])
, ...
from table customers

In such a way, reportServer would get a varchar and should work normally.

Offline

#3 2016-11-04 15:06:04

phillipjohnson
Member
From: Columbus, OH, USA
Registered: 2016-11-03
Website

Re: Support for NVARCHAR in GridEditor

edulid wrote:

Hello phillipjohnson,

you can try changing the report query to return a varchar instead of an nvarchar:

select ...,
CONVERT(VARCHAR(50), [city])
, ...
from table customers

In such a way, reportServer would get a varchar and should work normally.

Since this is GridEditor report, I'm not actually specifying the SQL. The documentation says you can do formatting for foreign keyed columns, but is it possible for the columns of the main table?

Also, converting to VARCHAR will cause any unicode characters to not display properly.

It also looks like the "real" datatype is not supported. Is there a list of supported and unsupported datatypes?

Offline

#4 2016-11-08 18:20:16

jalbrecht
Administrator
Registered: 2016-10-21

Re: Support for NVARCHAR in GridEditor

Hi phillipjohnson,

thx for the remark, pls. remember :

Remark. The grid editor is an experimental feature at the moment and its API might change in future versions. We are also very interested to hear your feedback in order to make the editor better fit your needs.

see: https://reportserver.net/en/guides/admi … r-Reports/

We are using it ourselfs and have some funny errors as well. We look into it and get back to you

wbr jan

Offline

#5 2016-11-17 09:19:09

IF_Eduardo
Administrator
Registered: 2016-11-01
Website

Re: Support for NVARCHAR in GridEditor

Hi phillipjohnson,

we corrected the NVARCHAR bug, indeed, it was only not working for Grid Reports. This will be fixed in the next reportserver release.

Greets,
Eduardo

Offline

Board footer

Powered by FluxBB