on 01-23-2014 6:36 PM
Hi, I'm using Predictive Analysis with HANA online. In my prediction, I'm using algorithm: HANA Apriori. When i click in execute, it appears an error that says: insufficient privilege: Not authorized action. Did anyone ever had this problem? Why it's happening?
Regards,
Jürgen Mollo
I had faced a similar issue. In that case I went to HANA System Privileges, and assigned “Create R Script” permission granted. I stopped getting the above error after that.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Thanks for your help. I have done exactly what you had suggest. But it still doesn't works. Just for curiosity, in wich format were the data you used in your prediction? In mine, Item Column (list of products) are in NVARCHAR and Transaction ID (purchase) are in INTEGER. Might this be the problem? Regards!
Hi Jugren,
Can you check if the table/view you are trying to access has sufficient privileges?
Also check the schema privileges.
Check if below privileges are in place:
I think it should work after that.
Coming to table, the table had INT and NVARCHAR values. I was having issues with INT values. Hence made all numeric values double.
See below forum for details. Your problem is with privileges and not with data type as I see.
This was very helpful. I could not find a comprehensive "official" looking document enumerating all of the SAP HANA privileges that are required by SAP Predictive Analysis 1.14; however, with this post and this post http://scn.sap.com/message/14726142#14726142, I was able to finally get things working in "online mode".
I realized that when I select the table I want to analyse, and click to prepare the data, I just openned 20 lines, and not the whole table (that contains more than 27 million lines).
Does anyone knows what might be happening?
regards
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I just tried to execute it with HANA, first I executed the one that removes duplicates, than it worked, after that I executed HANA A-priori and it also worked. but when i clicked to switch to the results, it appears the following error
than I clicked in the results from the "remove duplicates", and it gave me the same error, but without the last part "Please check lines: 1"
Does anyone knows what might be happening? My HANA is full, might this be the problem?
Than I tried to execute it again, and it gave me the following error:
Do I need to re-execute wrapper generator?
Regards!
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Bimal, thanks for your help!
i'll run it inside HANA, I'm justi waitting the company finalize the purchase of more memory, because the one we got is full.
I got a different problem yet, the Algorithm that you sended me (remove duplicates) only work in a database that has only the ID, and the product name.
But I need to use a table that contains the store where that purchase was made. And when I run that algorithm it excludes lines from the store, and not from the products!
Sorry this kind of problem, I'm asking you because I don't know ANYTHING about R configuration and programing.
I need to do any changes to the algorithm, or I need to create a new one?
regards
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hello all, I'm trying to run a "fake" database that I've create on excel, but it gives several different errors, one of then is this one.
Another error is this one:
And also this, but with different sizes many times:
Does anyone knows what might be happening?
My excel has only 120.000 lines, 2 collumns and 3,1 MB.
Regards
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Bimal, I donwloaded the table, and tried to execute it again, but it gives the same error. Than i've reduced the number of lines, and it worked, but when I runned the APRIORI, it didn't show any results. I've also created a fake table with 1.500 lines, and it worked perfectly, the component that remove duplicates and the APRIORI.
Do you know what might be?
I'm sending you the CSV file with the data, I'm using column number 4 (named column_3) as the purchase ID. And column number 5 (named column 4) as the products inside it purchase.
I'm sending it to your email.
Regards
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hello, If Apriori does not return any results, it can help to change the Apriori configuration.
The default values for Support (0.1) and Confidence (0.8) might be too high for your data. The support for instance means it will only produce rules that apply to at least 10% of your shopping baskets (if that's your use case). If no such combination is found, then no data will be returned.
You could try with 0.1 / 0.1. If there are still no results reduce the values further.
To avoid the duplicate records it would be nice to use HANA for this. Can you create an analytical view or calculation view that aggregates the duplicates?
Greetings
Andreas
Hi, the error persists, at the R configuration that you sended me, I needed to change anything for the real name of the collumns that I'm using?
I've exported 3 collumns from the HANA, but in this analysis I'm using only 2, might this be the problem?
Regards
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Please samplee some data and save the data in CSV and send it to me with the details of what exactly you are trying to do. I will run it from my side and come back to you on this.
Send me a Personal Message and I will send you my email id there where you can mail me the file and scenario you are trying to cover.
Connect with me by following me. I sent you a request already.
Hi Bimal, I tried to run the algorithm OFFLINE on HANA. It got a long time to download, and then I tried to execute the component, but it gives and error that says something like: the result of the principal component is invalid or there is an error in the processing of the result of the current component.
I checked the component several times, but I don't know what is wrong.
I'm sending how I configure the component, and the error.
Do you know what might had happened?
Regards
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
All your steps are correct.
That error occurs because you are executing the R component on HANA server in online mode
To execute R Script on HANA server you need the R server (RServe) installed and integrated with HANA server
See details here:
help.sap.com/hana/SAP_HANA_R_Integration_Guide_en.pdf
In case you don't have a separate server to install R-Serve you can do the below ( a bit painful) work around:
1. I would say work in offline mode. Get the data in SAP PA. Run the algorithm in SAP PA. Save the data with duplicates removed to an excel file.
2. Load this excel file to your HANA table.
3. Connect in online mode. Run the APRIORI on the new data from step 2.
The size of this thread in increasing. As your original query has been resolved, I would recommend closing this thread and start a new one in case you have any other issue. This will help newcomers in future also.
Thanks
I'll study with the tutorials and then I give you me results.
Thank you!!
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Bimal, does exist and easy way to delete the duplicates? Because I have almost 30 million lines in my database...
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You can do it using the below R script. You will have to create a custom R component with below code:
packagerunner <- function (mydata)
{
#Remove duplicates for Apriori Analysis.
output <-unique(mydata)
return(list(out=output))
}
See the tutorials here on how to create a custom R component.
Use the output of above to run the Apriori algorithm.
Hi Kevin, I've created a new user, with all the permissions from SYSTEM and following the steps that you and Bimal told me. Then I executed the algorithm and it worked!
But after executing, I've changed to the results, but unfortunately it didn't show any results!
Do anyone know why it's happening?
In my data, I have the purchase number, and the products that are on this purchase.
For example:
Purchase Number Products
1 Bread
1 Milk
1 Coke
1 Bread
2 Cheese
2 Water
2 Beer
As you could see, there is repeated products in the same purchase. For example in Purchase 1, we have 2 lines that contains Bread.
Maybe this could be the problem? Repeated products in the same purchase?
I've configurated the algorithm this way: in the transaction ID, I've used the Purchase Number. and in Item Collumn, I've used the list of Products. But this product are numbers, and not products name. For example, Bread is 1234, milk is 4321....
I need to change this numbers to names?
Regards and thanks again for your help!
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Thanks! I'll see tomorrow if it works, if not, I'm going to follow exactly the same you are suggesting me, and I'll create a new user for me.
Hope it works!
And then I'll give you the feedback.
Once again, thank you so much for your commitment and help!
Regards
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Thank you again for your help. I'm having some problems when I try to save the changes in privileges that I have done before. It appears an error that says I can't modify the SYSTEM becaus grantor and grantee are identical. So I'll try to modify this privileges with another logon. So then, I'll ask some tomorrow morning to do this for me in my Studio, or send me the login and password, so than I can do this changes.
I also tryied to logon at the PA with another user name and password, but it gives an error that says I can't connect to the server. I think it happens because that user don't have permission to do that.
When I finish doing the changes at privileges, I must click on DEPLOY, or just save and close?
I have just tryied running my analysis again, and the error of privileges persist.
I'll talk with someone here in the office tomorrow morning, so than I'll ask him to check the privileges.
And then I'll post here my results.
Regards!
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Kevin, I have acces to the SYSTEM logon and when I use the PA, I work with the system login, so in this case I need to assign this privileges to the SYSTEM?
I also tryied to open your JAM link, but it says that my email (ID) wasn't registered in the system, so then I can't access the page.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi, Jürgen. I think you should probably use a user besides SYSTEM, which you can easily create when you have the SYSTEM system added, go to Security --> Users --> Right Click + New Users and enter a name and password. You can probably add these privileges to SYSTEM, but I imagine you shouldn't. Besides what Brimal mentioned, I found that I needed to add the following privileges, mentioned by Ashok on http://scn.sap.com/message/14726142#14726142
Here are the screenshots of each tab of privileges that are needed:
Wow, thank you so much, Kevin!
your screenshots were very helpfull!
But I got 2 problems: one is that I can't edit the right bottom part from Studio, this might be happening because of the privileges my user have? But all the things that need to be selected, are selected. So I think this is not a problem.
When I go to add the Object Privilege AFL_WRAPPER_ERASER, it doesn't exist! I only have the generator.
I needed to execute an SQL Script for WRAPPER_ERASER?
Regards!
Hi again, I imagine that you can not select those options under "Package Privileges" because you are doing this for SYSTEM user.
Also, the AFL_WRAPPER_ERASER might not be needed. See if you can get SAP PA to connect in online mode now if you haven't already; otherwise, you need to make sure you have AFL installed on HANA and there are some scripts that you need to run I believe to create the stored procedures.
Hi Bimal and Kevin, thank you all for your good intention in helping me. But unfortunately I don't know exactly how to work with HANA, so I'm not sure how to check or add the privileges you sended before. In my HANA Studio, I already executed WRAPPER GENERATOR (wasn't installed in my Studio, so a friend of mine sended me, and than I executed).
Can anyone please write me some steps, teaching how to check or install the privileges?
Regards!
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Jürgen, if you are able to log in with the SYSTEM user in HDB Studio, you can assign these privileges to your user. If you get this far, you can go your system --> Security --> Users --> Select your user and edit the privileges.
See the following link to my wiki page documenting how to do this (look for the "online mode" section):
User | Count |
---|---|
72 | |
11 | |
10 | |
7 | |
6 | |
6 | |
6 | |
6 | |
5 | |
5 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.