Group by in Spring data rest - spring-data-rest

Does spring data rest provide default support for group by or having clauses using query dsl ? I know it allows filtering and sorting but does it allow aggregation by default?

Related

What is the difference between graphql and sql

What is the difference between graphql and sql.
If in graphql we select all the tables and all the columns of each table.
And sql in the endpoint serve we evaluate the query that does not have sql injected for prevent update or delete.
Performance is better whit graphql?
Really safety if it is extremely safe with graphql?
GraphQL is not related to database, it's about the presentation layer, You can implement an API with that. for more information check the link bellow:
https://en.m.wikipedia.org/wiki/GraphQL

Implementing Pagination in Database connector

Is there anyway to set pagination using configurations in select statement of in-built database connector of AnyPoint studio in mule?
I have tried reading the doc and I could not find any configurations to achieve pagination. If not should I write my own custom connector to achieve the same?
You need to implement this yourself.
Best way is to take in the query params you use for pagination, store them as variables and use those flowVariables in your select statement.
Depending on the DB you are connecting to you can then use mechanism such as LIMIT and OFFSET for MySQL as explained here
Another option would be to filter a specific range in DataWeave, but in terms of performance that is unnecessary data fetching, that may not be the nicest option because you still fetch all the data and filter it to a range later.

Difference between #multitenant(SINGLE_TABLE) and #multitenant(VPD) in EclipseLink

Despite the fact I searched a lot in the internet and read many articles, I still be unable to get the difference between the Single_Table strategy and the VPD strategy of EclipseLink.
At first I thought that the "VPD" is the implementation of the "Separate database strategy" but then I discovered that we use the same table for all tenants in both strategies.
Could anyone clarify the difference between the two strategies please?
The main difference is the level where the filtering is done.
When using SINGLE_TABLE multitenancy, EclipseLink is responsible for including tenant_id in all generated queries.
When using VPD, filtering is done on database level. So, EclipseLink will generate SQL queries which don't include tenant_id, and database will take care of the filtering.
Quote from the documentation
VPD allows users to identify themselves as a specific user, and will be able to 'see' data specific to that user. All result limiting is done at the database level, removing the need to send special SQL containing an additional comparison.

OData with a plain SQL (odbc) data source

I have an oracle data source that i would like to expose using odata.
The reason i need to use odata is that there are many parameters and it is hard to write a query for each combination.
How can i connect my oracle database to odata to achieve this given that the database is version 10.2g which as i have read does not support Entity framework.
Thanks
One of the solutions is using NHibernate, and here is a sample: http://aspnet.codeplex.com/SourceControl/latest#Samples/WebApi/OData/v4/NHibernateQueryableSample/.

WCF Data services or something else?

For a WPF client and Sql Server database application, I plan to use WCF data services for passing data between client and the database but I find the WCF client too limited in its abilities. Complex LINQ queries with JOINS etc. cannot be sent over to the server.
Is there another techonology that I should use here which supports complex LINQ queries from client to the server?
It's not entirely correct that you can't join data using OData (a.k.a. WCF Data Services). It's just that LINQ to OData does not support join syntax. However you can still retrive results from intersection of multiple tables using either Expand method or simply by specifying a relationship in a select clause. For example, if you have a table User with relationship to Phone table, you can write "from u in ctx.User.Expand("Phone")...", or you can write "from u in ctx.User select new { u.Name, u.Phone }", and it will retrive Phone collection.
I am not aware of any other RESTful LINQ provider that would support querying SQL data.