Author Topic: Dragging "Structured Data into a List  (Read 790 times)

Offline Cognos_Jan2017

  • Statesman
  • ******
  • Join Date: Jan 2017
  • Posts: 459
  • Forum Citizenship: +3/-1
Dragging "Structured Data into a List
« on: 09 Jan 2020 02:17:35 pm »
Running Cognos 10.2.2

Description also in attached Excel file.

The Vendor's relational DB includes MANY Fields of "Structured Data Name" and "Structured Data Value."

Sample data from Package as shown in attached Excel file ...
The Fields ID, City, And State can be dragged into a List.

Vendor has NOT explained to us how to get (drag) "Structured Data Name" Fields into a List
(so we can utilize "Structured Data Value"s.

=============================================
Is there a way to "drag" the "Structured Data Name"s into a List so "Structured Data Value"s
can be part of a List?

TIA, Bob

Offline Andrei I

  • Community Leader
  • *****
  • Join Date: Jan 2006
  • Posts: 193
  • Forum Citizenship: +7/-0
Re: Dragging "Structured Data into a List
« Reply #1 on: 10 Jan 2020 10:08:20 am »
Can you post a screenshot of the Cognos Package with these data items?

Offline Cognos_Jan2017

  • Statesman
  • ******
  • Join Date: Jan 2017
  • Posts: 459
  • Forum Citizenship: +3/-1
Re: Dragging "Structured Data into a List
« Reply #2 on: 10 Jan 2020 10:54:48 am »
Thank you Andrei I.

I will be back at the office next Monday.  I will attach your request then.

Someone else built the Query so I will need to probably have 2 screenshots of the Package.  As I recall, the Query Subject "Structured Data" is a good distance from the Query Subject which contains the Query Items ID, City, and State.

Offline Cognos_Jan2017

  • Statesman
  • ******
  • Join Date: Jan 2017
  • Posts: 459
  • Forum Citizenship: +3/-1
Re: Dragging "Structured Data into a List
« Reply #3 on: 10 Jan 2020 09:55:20 pm »
Thinking out loud.

"Field Names" from "Structured Data Name" are  revealed from a Filter on the Data Item "Structured Table Name."  Adding "Structured Data Value" to the Query brings in Values of the Filter.

On Monday I will examing its Lineage.  I have never used Cognos Arrays.  I  wonder if all the possible Field Names available in "Structured Data Name" are part of an array.  Maybe ...

Offline Cognos_Jan2017

  • Statesman
  • ******
  • Join Date: Jan 2017
  • Posts: 459
  • Forum Citizenship: +3/-1
Re: Dragging "Structured Data into a List
« Reply #4 on: 13 Jan 2020 11:48:49 am »
Andrei I - Attachment shows Pacakage info.

Offline Andrei I

  • Community Leader
  • *****
  • Join Date: Jan 2006
  • Posts: 193
  • Forum Citizenship: +7/-0
Re: Dragging "Structured Data into a List
« Reply #5 on: 13 Jan 2020 03:57:23 pm »
if you have a small predefined number of [Structured Data Name] fields then you can add each field as a calculation:
[DateAssessed] :=
Code: [Select]
CASE [Structured Data Name]  WHEN 'DateAssessed' THEN [Structured Data Value] END
with Default Aggregation := Maximum

See attached screenshot and report (C11, Cognos Samples) for details
Implementation would be the same for C10

Please let me know if it works for you.

Offline Cognos_Jan2017

  • Statesman
  • ******
  • Join Date: Jan 2017
  • Posts: 459
  • Forum Citizenship: +3/-1
Re: Dragging "Structured Data into a List
« Reply #6 on: 13 Jan 2020 04:04:37 pm »
THANK you Andre I.

It is that easy?  Just add Data Items as you describe in your zip file?

Workday just over.  Will think on this tonight, and test tomorrow.  We have MANY Reports to write
to utilize Structured Data.  Will test writing Data Items for both the "Name" and "Value."

Will report back here tomorrow how this helps.

Offline Cognos_Jan2017

  • Statesman
  • ******
  • Join Date: Jan 2017
  • Posts: 459
  • Forum Citizenship: +3/-1
Re: Dragging "Structured Data into a List
« Reply #7 on: 13 Jan 2020 04:06:20 pm »
I just added an "Applaud" for you.

THANK you again, Bob

Offline Andrei I

  • Community Leader
  • *****
  • Join Date: Jan 2006
  • Posts: 193
  • Forum Citizenship: +7/-0
Re: Dragging "Structured Data into a List
« Reply #8 on: 13 Jan 2020 04:13:23 pm »
Quote
It is that easy?  Just add Data Items as you describe in your zip file?

Actually it depends how these data is populated.
I assumed that you have only one Structured Data Value for each ID, Structured Data Name pair.
It will work even if you have more but Aggregation rule Maximum will return MAX value

Offline Cognos_Jan2017

  • Statesman
  • ******
  • Join Date: Jan 2017
  • Posts: 459
  • Forum Citizenship: +3/-1
Re: Dragging "Structured Data" into a List
« Reply #9 on: 14 Jan 2020 02:14:33 pm »
Andrei I - It took awhile to find the Query Items I needed from the MANY Structured Data Folders.

It WORKS !!!

My prior experience of 23-months (18 months Cognos Analytics), in another Vendor's App,
did NOT use 'Structured Data' like the current Vendor App.

With your assistance, I learned a new way of writing Cognos Queries and Reports.

THANK you again.  Some call me Jan, but I am Bob.