how we can the new number of entries in a table for one specific day . like the number of entries updated (inserted/deleted) in a table on particular date
update count in a particular table on a particular date
Sap Hana and R Configuration
Hi all,
I am trying to connect with RServe in Hana Studio to run my Rlang scripts. This causes the following error message:
SAP DBTech JDBC: [2048]: column store error: search table error: [34081] Connection error: Unable to connect with Rserve.;None of the Rserve can be connected: Cannot connect to the host with the port;
The default port is 7400 for rserve installation. I have given my IP & 7400 as the cer_rserve_address
I have not created any user/ password for authentication.
I have made my RServe setup accoiring to this tutorial
Guide: Setting up HANA integration with R for use with SAP Predictive Analysis
I have also installed kernlab on my R server. Now I am trying to run the following Script which casues the above error.
DROP TABLE "spamClassified";
CREATE COLUMN TABLE "spamClassified" LIKE "spamEval" WITH NO DATA;
ALTER TABLE "spamClassified" ADD ("classified" VARCHAR(5000));
DROP PROCEDURE USE_SVM; CREATE PROCEDURE USE_SVM(IN eval "spamEval", IN modeltbl SPAM_MODEL_T, OUT result "spamClassified")
LANGUAGE RLANG AS BEGIN
library(kernlab) svmModel <- unserialize(modeltbl$MODEL[[1]])
classified <- predict(svmModel, eval [,-(which(names(eval) %in% "type"))])
result <- as.data.frame(cbind(eval, classified))
END;
CALL USE_SVM("spamEval", SPAM_MODEL, "spamClassified") WITH OVERVIEW; SELECT * FROM "spamClassified";
I have read in this blog that someone has solved it with the firewall setiing in R server. However, it does not mention what exactly was done. In my R server running on Suse Enterpreise I have added port number 7400 using yast.
Any suggestions?
Lihas
How to find top x percent rows based on a column with numerical values?
I have a table with a couple of columns, only one of them holds numerical values. I was wondering if i could get the top x percent of rows based on the numerical values. I tried the basic select top query but it does not seem to work. Any help will be much appreciated.
In Excel a SYSTEM DSN ODBC Driver cannot access _SYS_BIC's Column View's
Hi,
I wonder about the following thing:
I configured a SYSTEM DSN 32Bit with the HDBODBC32 Driver with C:\Windows\SysWOW64\odbcad32.exe
With Crystal Reports I can access _SYS_BIC's Column Views:
With Excel I can not access _SYS_BIC's Column Views:
With Excel I get a:
"The database connection Wizard cannot obtain a list of databases from the specified datasource"
"You must either select a table or uncheck the 'Connect to a specific table/cube' checkbox in order to continue.
Unable to obtain al list of tables from the data source."
I wonder where is the uncheck Checkbox or what's the difference between Crystal and Excel ?
I'm useing the latest Releases, Reisions and SP's:
-Revision 51 for SAP HANA CLIENT 1.00 64 Bit / IMDB_CLIENT100_51-10009664.SAR-
-Revision 51 for SAP HANA CLIENT 1.00 32 Bit / IMDB_CLIENT100_51-10009665.SAR
-Revision 51 SP51 SAP HANA client 1.00 for MS Excel 32 Bit / HDBCLIENTXLS51_51-10011034.EXE
-CrystalReports 2011 FP3 14.0.4.738 / CRYSTALREPORTS03_0-20007350.EXE
-Microsoft Excel 14.0.6123.5001 (32Bit)
-Windows 7 Enterprise SP1 64Bit
Thank You
Best Wishes
Martin
SAP Hana WebIDE: 500 Hostname/IP doesn't match certificate's altnames
Hi,
if we try to use our odataservice we get this error:
500 Hostname/IP doesn't match certificate's altnames: "Host: .... is not cert's CN: ..."
I found two solutions:
One first solution was this, we had to set the parameter.
xs set-env app-js NODE_TLS_REJECT_UNAUTHORIZED 0
But after we set it we got a lot of other problems. We set it back again.
The second solution is described here by Thomas Jung:
SAP HANA SPS 11: New Developer Features; HDI
"Yes the hostname you are using to connect doesn't match the HTTPS certificate hostname. Perhaps you are tyring to connect with localhost or some other alias. You must use the same hostname to connect with the XS Client as you use to start the controller. It is very specific about this in order to validate the HTTPS certificates."
Does it mean, there must be a different hostname inside of the certificate to the hostname which we are connecting?
If I read the answer by AVK, I don't know why he is talking about the yml file. I'm not aware that we have to set there our hostname...?![]()
"yes in the .yml file the destination url that i had given was 'dcidshsapp01.dci.local' which was what i used to check if the xs controller was working. But when i changed the destination url in .yml file to dcidshsapp01 (which i thought was the host name in the certificate) everything started working fine. '.dci.local' was not required for the routing purposed I guess ."
Would be very nice, if one of you could help us.
Reg: Parameter Value help text not appearing
Hi All,
We are on SPS 10.
I have created a Calculation view which has Vendor id and Vendor description fields. Vendor Description is assigned as label column to vendor id at semantic level.
Parameter IP_VENDOR is used to filter the vendor value and it has master data attribute view assigned as value help table.
After I execute the Calculation view when I hit value help button I see only vendor values, the corresponding description doesn't appears.
Could you please suggest?
Regards,
Venkat
Some TA_TOKENS are not recognized even for simple English sentences
Dear Experts,
I am trying to analyse the phrase below. This is in response to Donald Trump's win in Indiana by a yahoo news reader.
"The first debate between Hillary and Trump is going to be like the super bowl with ratings. Iam going to get pizza and beer and enjoy the show."
SQL with logs
CREATE COLUMN TABLE "TA"."MYTABLE2"
(
ID INTEGER PRIMARY KEY,
REMARK NVARCHAR(5000)
);
Statement 'CREATE COLUMN TABLE "TA"."MYTABLE2" ( ID INTEGER PRIMARY KEY, REMARK NVARCHAR(5000) )'
successfully executed in 55 ms 858 µs (server processing time: 55 ms 28 µs) - Rows Affected: 0
insert into "TA"."MYTABLE2" values (1, 'The first debate between Hillary and Trump is going to be like the super bowl with ratings. Iam going to get pizza and beer and enjoy the show.')
Statement 'insert into "TA"."MYTABLE2" values (1, 'The first debate between Hillary and Trump is going to be ...'
successfully executed in 4 ms 571 µs (server processing time: 3 ms 613 µs) - Rows Affected: 1
create fulltext index MYIDX2 on "TA"."MYTABLE2"("REMARK")
configuration 'EXTRACTION_CORE_VOICEOFCUSTOMER'
text analysis on;
Statement 'create fulltext index MYIDX2 on "TA"."MYTABLE2"("REMARK") configuration ...'
successfully executed in 16 ms 135 µs (server processing time: 15 ms 478 µs) - Rows Affected: 0
Output from $TA_MYIDX2 table
| TA_RULE | TA_TOKEN | TA_TYPE | TA_RULE_COUNT |
|---|---|---|---|
| Entity Extraction | Hillary | PERSON | 1 |
| Entity Extraction | Iam | ORGANIZATION/OTHER | 1 |
| Entity Extraction | Trump | PERSON | 1 |
| Entity Extraction | Trump | Sentiment | 1 |
| Entity Extraction | Trump | StrongPositiveSentiment | 1 |
| Entity Extraction | enjoy | WeakPositiveSentiment | 1 |
| Entity Extraction | enjoy the show | Sentiment | 1 |
| Entity Extraction | the show | Topic | 1 |
What I am expecting is debate, super bowl, enjoy, beer. HANA doesn't seem to detect these words. Did I miss anything please advise.
My HANA version is SAP HANA Studio 2.0.16 run on MS SQL Server 2008.
Want to calculate the total number of days excluding holidays and weekends ....?
Hello all,
I am stuck with the situation here ,
what i need is to calculate the total number of days excluding the Holidays and Weekends in HANA. How can i calculate the same by not adding (excluding) the saturdays and sundays and also the holidays. I am not able to apply the logic here.
How can i achieve that. Need suggestions plz....
Thanks and Regards
Vaibhav
How to perform a join depending on a condition in graphical calculation view
Is it possible to perform a join depending on some condition in graphical calculation view or I have to use scripted calculation view.
memory exceeded, system locked
Hi all,
I see in our AWS Hana SPS8 the message "System locked; licensed memory has been exceeded". I've restarted Hana and requested new license, now the memory usage is well below the licensed limit, but the message keeps showing (and M_LICENSE.LOCKED_DOWN is true). The docs say that Hana should be restarted but apparently this does not help. Is it possible to unlock it at all?
-- Micha
Strange procedure performance issue
Hi!
I am new to HANA, maybe my question is obvious, but I can resolve it.
So there is this built in SP:
CREATE PROCEDURE SAP_HANA_DEMO."sap.hana.democontent.epm.Procedures::get_bp_addresses_by_role" (
IN im_partnerrole NVARCHAR(3),
OUT ex_bp_addresses SAP_HANA_DEMO."sap.hana.democontent.epm.data::Procedures.tt_bp_addresses")
LANGUAGE SQLSCRIPT
SQL SECURITY INVOKER
--DEFAULT SCHEMA <default_schema_name>
READS SQL DATA AS
BEGIN
/*****************************
Write your procedure logic
*****************************/
ex_bp_addresses =
select a."PARTNERID", a."PARTNERROLE", a."EMAILADDRESS", a."COMPANYNAME",
a."ADDRESSES.ADDRESSID" as "ADDRESSID" , b."CITY", b."POSTALCODE", b."STREET"
from "SAP_HANA_DEMO"."sap.hana.democontent.epm.data::MD.BusinessPartner" as a
inner join "SAP_HANA_DEMO"."sap.hana.democontent.epm.data::MD.Addresses" as b
on a."ADDRESSES.ADDRESSID" = b."ADDRESSID"
where a."PARTNERROLE" = '1';
END;
And I test this select by these 2 methods read below:
1./ CALL "SAP_HANA_DEMO"."sap.hana.democontent.epm.Procedures::get_bp_addresses_by_role"('1',NULL)
with this result:
successfully executed in 5:40.568 minutes (server processing time: 5:40.578 minutes)
Fetched 39 row(s) in 6 ms 276 µs (server processing time: 0 ms 212 µs)
2./ Running the select directly
select a."PARTNERID", a."PARTNERROLE", a."EMAILADDRESS", a."COMPANYNAME",
a."ADDRESSES.ADDRESSID" as "ADDRESSID" , b."CITY", b."POSTALCODE", b."STREET"
from "SAP_HANA_DEMO"."sap.hana.democontent.epm.data::MD.BusinessPartner" as a
inner join "SAP_HANA_DEMO"."sap.hana.democontent.epm.data::MD.Addresses" as b
on a."ADDRESSES.ADDRESSID" = b."ADDRESSID"
where a."PARTNERROLE" = '1';
with this result:
successfully executed in 4 ms 278 µs (server processing time: 1 ms 131 µs)
Fetched 39 row(s) in 2 ms 718 µs (server processing time: 0 ms 86 µs)
Result table is the same!
What can cause this huge difference in performance?
Thanks, in advance!
Peter
can SAP B1 hana use SP Transaction notification type calls
Hi All,
With SQL server and SAP B1 you can manage certain event validations using SQL SP_transaction notification stored proc. If we use SAP B1 with Hana database is there anything similar to trigger a validation and block events? For example user doesn't adhere to discount rules when creating a sales order.
Thanks
SAP HANA Live Authorization Assistant does not found package
Hi all,
I want to create an Analytic Privilege with the help of the SAP HANA Live Authorization Assistant. I installed the assistant correctly and generated AnalyticsMetaData for my view. However, after I clicked on AnalyticsAuthorization-> Generate Analytic Privileges and I want to select a Package to store analytic privileges it says "no packages found". When I click on change it still says no packages found.
However, if I select the View I want to create an AP for and click through the dialogs it creates the user-specific role for that AP, but does not create the AP and throws the following error: Folder does not exist
I also replicated the following tables: UST12, USRBF2, AGR_1016 and I also have the roles. SYS REPO user has SQL Execute privilege REPOSITORY_REST
with Grantable to others
option selected. My user also has import/export privileges and granted roles: AnalyticalAuthorizationAdministrator, AnalyticalAuthorizationDeveloper
It would be amazing if somebody could help out.
Thanks and best regards,
Manuel
SAP hana cockpit login not working.
I've registered SAP Hana Cloud. I coudn't login to Administration Tools->SAP HANA cockpit and developement workbench using system account which created during the database schema creation. Please advice me on it
DXC ERROR WHILE ACTIVATING DATASOURCE
Hello Experts,
We have SLT installed on our BW server, in which we are using only financial DS(ECC DATASource) to modeling in BW.
In the same system we will be using few of the DS(Ex. 2LIS_13_VDITM), to replicate the same to HANA using DXC,
I have created the table which stored DXC data sources, and made the settings(Schema name, datasourcename & table settings in BW),
But when i am trying to replicate the datasource(After maintaining the data in table which stores the DS names), i am getting the below error
Error in HANA DB system: Unable to modify DSO table '2LIS_13_VDITM': no key field defined (at least one of the defined columns m
Could any one please help.
Thanks & Regards,
Kishore
if condition error in HANA
Hi,
Please correct me in this condition:
if("Severity"!='Emergency','Outstanding',if("Severity"!='High','Outstanding',if("Severity"!='Medium','Outstanding',' '),' '),' ')
Kindly suggest what is wrong in this condition.
regards
Vaibhav
Error on UNION ALL in HANA PROCEDURE - exception 71000274
Hi,
I am trying to create a stored procedure in HANA , that calls 2 stored procedures and get the returned tables into 2 local variables.
Then the procedure union these 2 local tables into the one table which is the procedure output.
data volume of each local table is around 20,000 records.
Procedure defintion
CREATE PROCEDURE "SAP_HRF"."DHS_AGGREGATOR" (OUT aggr_output "SAP_HRF"."sap.DHS::DHS1.OUTPUT.TYPE")
language SQLSCRIPT sql security invoker reads sql data as
Begin
--local varibles
declare lt_output_1 "SAP_HRF"."sap.DHS::DHS1.OUTPUT.TYPE";
declare lt_output_2 "SAP_HRF"."sap.DHS::DHS1.OUTPUT.TYPE";
declare lt_action_placeholder "SAP_HRF"."sap.hrf.resources.rule.model::T_SERVICE_ACTIONS_RESULT";
-- rules execution
CALL "SAP_HRF"."sap.DHS::DHS1"( lt_output_1 , lt_action_placeholder );
CALL "SAP_HRF"."sap.DHS::DHS1"( lt_output_2 , lt_action_placeholder );
-- results aggregation
aggr_output =
select * from :lt_output_1
UNION ALL
select * from :lt_output_2;
End;
Procedure output type -
CREATE TYPE "SAP_HRF"."sap.DHS::DHS1.OUTPUT.TYPE" AS TABLE ( "HRF_RESULT_ID" CHAR(32) CS_FIXEDSTRING,
"RULE_ID" CHAR(32) CS_FIXEDSTRING,
"RULE_NAME" NVARCHAR(256) CS_STRING,
"RULE_PACKAGE" NVARCHAR(256) CS_STRING,
"RULE_TEMPLATE_NAME" NVARCHAR(256) CS_STRING,
"RULE_TEMPLATE_PACKAGE" NVARCHAR(256) CS_STRING,
"HEADER" VARCHAR CS_STRING,
"GUID" VARCHAR CS_STRING,
"ROW_ID" CHAR(32) CS_FIXEDSTRING,
"numericInput" DECIMAL(17,
5) CS_FIXED,
"secondNumericInput" DECIMAL(17,
5) CS_FIXED )
When trying to execute the procedure I am getting the following error -
Could not execute 'CALL "SAP_HRF"."DHS_AGGREGATOR"(?)' in 199 ms 727 µs .
[129]: transaction rolled back by an internal error: [129] transaction rolled back by an internal error: exception 71000274: Failed in "" column with the value '2E0717F9512534C7ABD9B1770BB9B23B'
(please check lines: 20)
When running each inner procedure by itself - get no error
When trying to comment out the union and return one of the tables - get no error
Did any one encounter that?
thanks!
Yaron
syntax error for dynamic column for update query
Hi Experts,
Please check following query. i have incorporated it in my store procedure.
| EXEC 'update TBL_M set '||:COL_NAME||' = '||:R."W_QTY"||'where WID ='||:R."W1"; |
i am getting following error.
Could not execute 'call USP_CW' in 131 ms 107 µs .
SAP DBTech JDBC: [257]: sql syntax error:--: line 29 col 5 (at pos 625): [257] (range 3) sql syntax error exception: sql syntax error: incorrect syntax near "W1": line 1 col 44 (at pos 44)
could you please let me know, where i am doing wrong.
SQL privilege consumption in Repository role
Hi Experts,
I am trying to consume the HANA SQL privilege in the HANA repository role using below syntax.
catalog analytic privilege: "ZANPSQL_MM_MATRL_RESERV_ALL";
but on activation it throws below error:
Unknown analytical privilege name [ZANPSQL_MM_MATRL_RESERV_ALL]
I have seen SAP HANA repository role help page but it does not show any syntax for SQL privileges.
Regards
Rajender Singh
Unable to Debug SQL Script Procedure Step by Step
Hi,
I am not able to Debug SQL Script Procedure in Step by Step manner. There are option availble such as Step-Over, Step-Into but all are disabled. Can anyone know, how to enabled them or debug in step wise manner, without setting breakpoint a every step(as we do it in Web base development).

