Exploring, predicting and reporting with SAS Visual Analytics and SAS Visual Statistics

Wrong format in building Star Schema

Reply
Occasional Contributor
Posts: 6

Wrong format in building Star Schema

Dear all,

I have a problem with the default format sas chooses when I create a Star Schema.
All the fileds with character data type are included with format $100 / $40 even if the type is right, character(100) or character(40).
First I didn't mind but when I tried to build a formula in Analytics Explorer it gave my wrong type error in confronting a character category with a text value. I include an image of my star schema along with the formula I try to build in Analytics Explorer:
IF ( 'DESC_SCENARIO'n = ('BUDGET VERSIONE 1') )
RETURN 'BDG_NET_EUR'n
ELSE 0

Star schema.png

As you can see in the above formula the DESC_SCENARIO is considered as a number type column even if it is a character type column.
I tried to change the format, but there is no way to do this.
What can I do? Why SAS Visual Data Builder choose this format, how can I change this behaviour?
I appreciate any help that you can provide,
Adelaida

SAS Super FREQ
Posts: 76

Re: Wrong format in building Star Schema

Hi @Adelaida,

 

What makes you think that DESC_SCENARIO is considered a number?

 

If the reason is because you see the letter n in the expression (e.g. 'DESC_SCENARIO'n), this doesn't mean a number. This n indicates a named data item, which could be calculated or not. These are valid syntax in expressions:

'DESC_SCENARIO'n --> a data item (numeric or character)

'DESC_SCENARIO'p --> a parameter (numeric or character)

'DESC_SCENARIO' --> a string

 

Best,

Renato

 

Ask a Question
Discussion stats
  • 1 reply
  • 244 views
  • 0 likes
  • 2 in conversation