Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi All,
As per heading of the discussion, I want to concatenate string values in two different columns of Measures in Direct Query.
How Can I achieve the same.
I am using Postgresql.
I am using -
DIRECT QUERY
DIMENSION
1 As Flag
MEASURE
col1,
col2,
col3
From demo;
And I want something like -
DIRECT QUERY
DIMENSION
1 As Flag
MEASURE
col1,
col2 || col3 as test
From demo;
Please assist.
Thanks & Regards,
MK
I see no documentation where it says that you cannot use NATIVE in Measures. But there is no way for me to test this because I don't have access to Direct Discovery application. But just so we are sure, did you add single quotes around your function?
NATIVE( 'col2 || col3' ) as test
Can you preceeding load a direct query?
Load *,col2 & col3 as test;
DIRECT QUERY
DIMENSION
1 As Flag
MEASURE
col1,
col2,
col3
From demo;
I tried this, it says, col2 not found, throws an error.
sack off the direct query and just use normal SQL?
I never really understood the benefit of direct query myself
anyone please assist
Sorry I was being serious, I don't think you can expect to achieve this using DIRECT Query as it doesn't give you this kind of flexibility
I have to use Direct Discovery approach only
Can you try this:
DIRECT QUERY
DIMENSION
1 As Flag
MEASURE
col1,
NATIVE(col2 || col3) as test
From demo;
Here are some example of how NATIVE is used. It basically allows you to do SQL manipulations to the Direct Discovery
Forgot to add single quotes....
DIRECT QUERY
DIMENSION
1 As Flag
MEASURE
col1,
NATIVE( 'col2 || col3' ) as test
From demo;