Bring back the CTRL + drag and drop entity

Aggregates & Queries
On our radar

In the 4.1 or 4.2 version of the platform we had a feature of dragging an entity to an advanced query while pressing the CTRL key, that would expand all it's fields when droped. It was a great feature.

Created on 31 Jan 2013
Comments (11)
what is the real value of this ?

I'm curious as well.

do you mean that you instantly see in the edit field

{FOO}.Attribute1, {FOO}.Attribute2, {FOO}.AttributeN ?

so you can fix it faster?
There is more than one use case where this kind of fuctionality is useful.

This has more to do with entities that have many columns. Denormalized data for db performance for instance.

One use case is when you have columns that have been deleted and a simple {Entity}.* would make your query crash because you would be getting more columns that the ones referenced in the entity. And you can't always delete it from the database.

Another use case: you're doing an advanced query with a lot of columns to group by. With this functionality you could save a lot of work and time, and error-prone-ness by doing it automatically. 

It might not be used a lot but it's really helpful when you do need it. And since it was a feature that was already present, it's kind of hard to see it gone.

@Statler & Waldorf: no. With this functionality you would drag an entity to an advanced query, while pressing the CTRL key, and all of it's fields would appear.

For instance, if you have an entity named Entity1 with the columns Col1, Col2 and Col3, when you drop it inside the advanced query the result would be:
{Entity1}.[Col1], {Entity1}.[Col2], {Entity1}.[Col3].

Even more helpful would be to be able to select multiple columns and drag and drop them to the advanced query. Just like we can do with a single one.

Hi André. the {Entity}.* expands in runtime to {Entity}.A1, {Entity}.A2, {Entity}.An and doesn't matter if there are attributes on the database side.
The advantage of this syntax over the expanded one is that the query is more maintainable, and if someone alters the entity, it does not break the query.
Has that behaviour changed in recent releases? It was normal for a {Entity}.* query on a database table that has more columns than the ones referenced on the table to break the query.
I'm having a ORA-01791 error for an {Entity}.* distinct query with order by parameters in that entity. So I'm guessing that the parameters don't get expanded, otherwise this would not happen.

Hi André, the parameters are expanded.  You're  probably misinterpreting the ORA-01791. What it says is "The query is a SELECT DISTINCT query with an ORDER BY clause. In this context, all ORDER BY items must be constants" - reference http://ora-01791.ora-code.com/
Well if the Oracle database is throwing that error when I'm doing an advanced query, with the following code: 
SELECT DISTINCT {Entity1}.* FROM {Entity1} ORDER BY {Entity1}.[Value1], and it's not throwing it when I put all the parameters that I want to output like SELECT DISTINCT {Entity1}.[Value1],  {Entity1}.[Value2] FROM {Entity1} ORDER BY  {Entity1}.[Value1]. How can the parameters be expanded? If they were shouldn't the database see the same query as the end result?
Hi André. Can you please report that problem to support, that behavior is not expected.
I could not reproduce the problem and I'm seeing the correct expansion.


Changed the category to Aggregates & Queries