Quantcast
Channel: SCN : Discussion List - SAP HANA Developer Center
Viewing all 6412 articles
Browse latest View live

OData permissions: GET succeeds but POST/PUT fail

$
0
0

Hi all

I have several OData services on my HANA instance (on HCP) where the following happens:

the OData service is very simple with just one or two entities, no forbidden instruction is defined.

Authentication has been set to SAML+Basic+Form, so almost everything is accepted.

The content-type is set to application/json and charset is specified to utf-8

Authentication headers are specified correctly

Payload is correctly formatted in JSON

But any call other than GET (e.g. POST/PUT) results in a 403 HTTP error.

I'm testing this through the Chrome Postman tool

 

Any idea why this happens?

Thanks

Vincenzo


HANA dynamic tiering [ODBC Driver] All IQ large memory has been used, allocation canceled

$
0
0

Hello - we are working on SPS10 and has implemented dynamic tiering. I was able to create extended table successfully and load data to it. I have 18 MM records in the extended table. I am getting the below error while quering the results using SQL or via Calc view data preview. tried all possible configurations changes within esservier.ini file...such as load_memory_mb, delta_memory_mb, catalog_cache etc...also tried extending the storage size..

 

Below is the error

All IQ large memory  has been used, allocation canceled.

 

Any help or guidance is highly appreciated

No SAP HANA perspectives in Eclipse 4.5 Mars

$
0
0

I was using Eclipse 4.4 (Luna) for SAP HANA Studio and everything worked well.

Today I decided to install the newest version of Eclipse 4.5 (Mars). In order to install SAP HANA Studio I added the following software site to Eclipse: https://tools.hana.ondemand.com/mars

I got the link from: https://tools.hana.ondemand.com/

 

But unfortunately I don't see any HANA perspectives after the installation of the HANA tools:

1.png

I definitely installed SAP HANA:

2.png

 

Then, I installed the SAP HANA tools from the site from the older Eclipse Version 4.4: https://tools.hana.ondemand.com/luna

(still using Eclipse 4.5) and all HANA perspectives appeared.

 

The interesting thing is, the software site from the newest Eclipse Version 4.5 offers less HANA software:

mars.png

than the older Eclipse Version 4.4:

luna.png

 

Any suggestions?

Cambiar ubicación de logs SAP HANA

$
0
0

Buena tarde, necesito saber como cambiar la ruta de los logs para poder realizar la recuperación de mi sistema ya que el espacio en la ubicación actual ya llego a su limite y me impide realizar alguna acción.

 

Lo que hice fue mover los logs a una disco externo y desde SAP HANA Studio  en la pestaña de configuración de los Bakcups cambie la ruta, pero al querer hacer la recuperación al ultimo punto no me permite esto.

 

Quedo a la espera de sus comentarios.

Saludos!!!

SAP DBTech JDBC: [260] (at 12): invalid column name:

$
0
0

I am working on the INV1 table.

 

When I run select * from INV1, it returns all the columns data with no problem

 

But when I run select LineTotal from INV1, it gives me the error "SAP DBTech JDBC: [260] (at 12): invalid column name:", but LineTotal is one of the columns in the INV1 table.

 

Am I missing anything in HANA? I used to work a lot with MS SQL Server, but this HANA gives me too much headache.

How to run sql statement in xsjs and get the result as json?

$
0
0

Hi,

 

I am trying to run sql statement in xsjs and get the result as json.

 

Sql Statement on SQL console

SELECT SUM("Column")  AS sum FROM "Table";

This is returning sum= 10000;

 

Now My XSJS file

 

var query = "SELECT SUM(\"Schema_Name\".\"Table_Name\".\"Column_Name\") AS sum FROM \"Schema_Name\".\"Table_Name\"";
var conn = $.db.getConnection();
//var pcall = conn.prepareCall(query);
var pcall = conn.prepareStatement(query);
pcall.execute();
var rs = pcall.getResultSet();
var output = {};
//Here you parse rs and put it to output
while (rs.next()) {  output.total = rs.getString(1);  output.results.push(output);
}
rs.close();
pcall.close();
conn.commit();
conn.close();
$.response.contentType = "application/json; charset=UTF-8";
$.response.setBody(JSON.stringify(output));
$.response.status = $.net.http.OK;

Still not getting it. its giving a blank JSON file.

XSJOB and its log

$
0
0

Hello,

 

I've created a XSJob and it really was really easy to setup. However, my job has a quite short call frequency, its set to

 

* * * * * */3 meaning each 3 seconds its triggered. It all works perfect, but I noticed that the browser view of its job-admin page gets quite sluggish. This, of course, comes from the great amount of log entries that gets created (1200 / hour).

So I wonder how I can limit these log entries?

Having 28800 lines each day doesnt make big sence in case the job executes without problem - is there a way to only log errors?

 

Best,

 

Korbinian

table color,delete

$
0
0

Hi Experts,

 

I have the following requirements:

 

1) I have Input field and table (sap.m). In change event I'm getting the value for the Input and if that value is there in table I'm changing the color of the Icon.but I want to change total color of the row. How can I achieve that?

 

eg:

 

Initially my table is like below

 

Table:  Status    name    id

 

row1     red        As       123

 

row2    red        hi         456

 

Input:As   now I changed my table to

 

 

Table:  Status    name    id

 

row1     Green        As       123

 

row2    red        hi         456

 

 

sample Code:

 

handleChange:function(oEvent){

  var oValue = this.getView().byId("idInput").getValue()

  var olength=this.getView().byId('idTable').getModel().getData().results.length;

  for(i=0;i<olength;i++){

  var ocell1 = this.getView().byId('idTable').getItems()[i].getCells()[1].getText()

  if(ocell1 == oValue){

  var ocell2 =this.getView().byId('idTable').getItems()[i].getCells()[0].setColor('#FF0000');

 

  }

  }

 

   }

 

I tried like below code to change the color of the text, but it's not working

 

this.getView().byId('idTable').getItems()[i].getCells()[1].getText().fontColor('#FF0000');

 

 

 

 

2) And, I have mode="Delete" for table. If I'm deleting any records from the table the colors are changing to initial color(which is red in my case). But I want to delete selected row and keep remaining .


Retrieving column names of table from HANA through Java is slow.

$
0
0

Using Metadata.getColumns(String catalog, String schemaPattern, String tableNamePattern, String columnNamePattern) to get column names takes around 500ms-1000ms to complete.

 

com.sap.db.jdbc.trace.DatabaseMetaData's implementation of the the getColumns method takes much longer than Oracle.

The Oracle implementation of the getColumns method takes around 10ms to complete.

 

Is this a known issue with the HANA jdbc driver?

If so, will this be fixed in the near future?

Can't DECLARE table variable.

$
0
0

Hi, everyone.

 

I'm trying to declare a table variable in my procedure, however, SAP HANA can not create the procedure due to the "... incorrect syntax near "(" ...". I deliberately copied the example from the SAP HANA SQL Script References, and it returns the same issue.

 

-- For instance:

 

SET SCHEMA "MyDB";

DROP PROCEDURE "MyProc001";

 

CREATE PROCEDURE "MyProc001" () LANGUAGE SQLSCRIPT AS

BEGIN

  DECLARE temp TABLE(DocEntryINTEGER, DocNum INTEGER); -- here HANA says: "... incorrect syntax near "(" ..."

  temp = SELECT "DocEntry", "DocNum"  FROM OPOR;

END;

 

What do I make wrong?

Regards, Evgeny.

IMPORT FROM insufficient privilege: Not authorized

$
0
0

I want to import some csv-data:

 

IMPORT FROM '/users/Perslist/data/data.ctl';

But I get the following error:

insufficient privilege: Not authorized

 

Which privileges are missing? How do i figure out by myself in the future which privileges I need to perform an action??

 

Greetungs

Difference between 'parameter via key' and 'parameter via entity'

$
0
0

Hello Experts,

 

I am very new to HANA & OData and i am following the SAP HANA Developers Guide for learning.

 

I came across the keywords "PARAMETER VIA KEY" and "PARAMETER VIA ENTITY". But I didn't understand the difference between these and when exactly to go for "via key" and "via entity". Kindly help me here to understand the actual purpose of use and its difference.

 

Note: Apart from getting the user input I didn't get any difference between these keywords.

 

Regards,

Satish D R

Functions in CDS VIEW

$
0
0
select mandt,werks,matnr,zltno,vcode,zmsta,ersda,row_number() over(partition by mandt,werks,matnr,zltno order by ersda desc)rid from ytest002

The result is: 20150907182411.jpg

 

Can I make a cds view like this?

what function can i use in cds view?

i can use substring function, but any other functions i can't use in the cds view.

 

it tell me there is an error,and i can't active it

 

20150907182725.jpg

Generated Columns in HANA modelling

$
0
0

Hi,

 

What are generated columns in HANA modeling? How they improve the performance of an information model?

Also why they are better than calculated attributes? What are steps involved to create or use these generated columns.

Connection problems between HANA and Hadoop/Hive

$
0
0

Hi all,

 

I got some connection issues between HANA and Cloudera Hadoop/Hive.

 

Unfortunately, I have to use a newer Version of Hadoop/Hive than the metioned ones of SAP.

The system landscape is Hadoop 2.6 with Hive 1.1.0 on Linux and HANA SPS 09 on Windows.

 

I've been able to build up a connection via Smart Data Access using the cloudera odbc driver.

The connection is doing fine so far, but the response times of queries is way too Long compared to an iSQL query. Via iSQL the response times for 10 datasets is about 20sec, in HANA the response time is 4min for 10 datasets.

 

Do you have any idea what's causing the delay?

Or do you have any idea how I can find the cause of the delay?

 

For me it seems like there are 3 different options:

1. it's an an issue relayed to the supported versions. (but it would be nice to get a confirmation for that)

2. the driver version is not working fine with HANA (I tried different versions of the Hive ODBC driver and also different versions of the Impala driver) (any suggestions which driver/version I should use?)

3. the cause is something I'm not looking at. (any suggestions where to look at or how to trace?)

 

Does the connection via Smart Data Integration or SAP Data Services work with the mentioned Hadoop/Hive version?

 

Many thanks for your help!

 

Best regards

Mo


Regarding SQL Logic

$
0
0

Hi,

 

I have a requirement as below.

 

I just tried with Select + update ( inner query ) But the only challenge I am facing is how to fetch data for previous row. ie for n column 'B' is blank so get the data from n-1 'B' column and insert the same. Do we need to use the loops here? I am just afraid if we use the same it may hamper the performance of a query. Any suggestion please?

 

Source Table:

 

A          B

ABC     100

ABC     200

DEF    
ABC     600

GHI    

MNO     900

 

 

Target Table:

 

 

A          B

ABC     100

ABC     200

DEF     200   
ABC     600

GHI      600

MNO     900

 

Br

Sumeet

Error message in calculated column

$
0
0

Hi,

 

There is a "MONTH" field in my view with values 1,2,....12 and I am trying to create a "MONTH_TXT" field from this which should show Jan for 1, Feb for 2 like that. For this I am trying to create a calculated column in calculation view as shown in the attachement.

 

I am trying to create this c.column in final aggregation node of c.view.Please let me know how to solve this.

 

Thanks,

Jyothirmayi

HOW TO COMPARE DATE IN A TABLE WITH CURRENT DAY .

$
0
0

Hi All I have  a requirement like to compare the tables date with Current_day -15 . Presently I am running this.

 

select "ID", "ZDATE"  FROM "DS_TIME" WHERE "ZDATE"  <= CURRENT_DATE -'15' ORDER BY "ZDATE" DESC;

 

but i am having datatype issues.

HANA Studio's Extract Semantics tool

$
0
0

HANA Studio’s Extract Semantics tool supposedly alleviates the issues frequently encountered when modifying a view; e.g., when removing a join below the top-level aggregation node so as to insert a new join node, the metadata (user-defined column labels, aggregation types, etc.) are lost. It's my understanding that the tool is supposed to help in this regard.

 

I’ve been trying the tool with various project but am having poor results. The first confusing thing is that it requires me to specify the data source for many of my outputted fields, presumably because those fields come from multiple sources in lower nodes; however, it’s not obvious what the repercussions of the selections are such as when I later re-apply the metadata (i.e., the copied semantics) after the new join node has been connected to the top-level aggregation node. Also, when re-applying the metadata, some of the column labels are not restored.

 

At this point, I don’t have much confidence in the tool because I don't know what metadata will be lost.

 

Has anyone here tried using this tool? If so, what has been your experience?

SQL Analytic Privilege

$
0
0

Hi,

 

In the Apply Privilege Property of any Information view (In View Properties Tab), there exists two options

  • Analytic Privilege
  • SQL Analytic Privilege

 

When I select SQL Analytic Privilege and activate the view it gets activated. But when I do Data Preview it throws error.

Could some one explain what does SQL analytic privilege mean?

 

Regards

Monissha

Viewing all 6412 articles
Browse latest View live