Application Development Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 

ABAP For HANA as secondary DB problem in execute query decleration.

Former Member
0 Kudos
157

Hello Experts,

I am fetching data from HANA DB as secondary database using ADBC. When I am going to concatenate native SQL query its geting more than 255 char and here is the problem.

Please suggest how can I deal with more than 255 char string query.

GV_SQL is query which is string.

e.g.  GO_RESULT = GO_SQL->EXECUTE_QUERY( GV_SQL ).


-

Regards,

Amol

1 ACCEPTED SOLUTION

former_member182114
Active Contributor
0 Kudos
103

Hi Amol,

I've tested on NW 740 SP6 and face no problem with statement with 1200 bytes.

What is the error you are facing?

What is the NW stack and support package are you using?

Regards, Fernando Da Rós

7 REPLIES 7

former_member182114
Active Contributor
0 Kudos
104

Hi Amol,

I've tested on NW 740 SP6 and face no problem with statement with 1200 bytes.

What is the error you are facing?

What is the NW stack and support package are you using?

Regards, Fernando Da Rós

0 Kudos
103

Hi Fernando,

We are using 730 SP7.

Actually I am trying to concatenate more than 255 char into string, but it is taking only up to 255 char in string variable.

Thanks,

Amol

0 Kudos
103

Hi Amol,

Please be more clear, don't know if you are facing problems with ADBC or just string concatenation.

What is the point raising error? It's a dump or if't a malfunction?

Post here de declaration of string variable and the usage of it.

Regards, Fernando Da Rós

0 Kudos
103

Hi Fernando,

     1.Actually I am not facing any problem with ADBC. Just ABAP predefined type STRING is not accepting more than 255 character length.

     2.At the time of concatenating fields, HANA view path and where conditions it is getting more than 255 character, hence at the time execution of query getting failed.

     3.  GV_SQL type string.

GV_SQL =  |SELECT MANDT....(more than 255 character length)| &&

                   |FROM _SYS_BIC."dev.re.e10.cal.fi.tr/CV_COSTELEMENT_TEST" |

             && |('PLACEHOLDER' = ('$$IP_BUKRS$$', '{ P_WERKS }')) |.

GV_SQL storing only 255 character, I wanted a string to store more than 1000 character length.

-

Regards,

Amol

0 Kudos
103

Hi Amol,
we changed that a while ago. I currently investigate which minimal kernel release you need or if there's an SAP note for your release.

Cheers,

  Jasmin

0 Kudos
103

Thanks Jasmin and Fernando for your prompt reply and  issue resolved.

0 Kudos
103

Hi Amol,
just for completeness: You can find the variable for the SQL Statement in class EXECUTE_QUERY. You should find a string variable holding the statement. In older releases an ABAP CHAR-like variable (32k or 64k has been used). So if you find a string variable in your systems, you should be fine.

Cheers,

  Jasmin