Skip to Content
0

sql statements generated by BODS 4.2

Mar 02, 2017 at 03:09 PM

232

avatar image

hi there,

Im loading data from SAP ECC to Sql Server 2012 using BODS 4.2 I'm facing issues with date and datetime fields in the target table.

For date datatype in the target table following error message is displayed "ODBC data source <CUSIID0q\WARRANTY> error message for operation <SQLBindParameter>: <[Microsoft][ODBC SQL Server Driver]Optional feature not implemented>."

For the datetime datatype in the target table following error message is displayed "datetime field overflow".

I would like to see the sql statements that are being generated by BODS for writing to the target table. Is there any trace option that I can enable that shows me the sql code thats generated during the execution of the job to understand this error message better.

Regards,

samique

10 |10000 characters needed characters left characters exceeded
* Please Login or Register to Answer, Follow or Comment.

2 Answers

Luis Darui
Mar 03, 2017 at 05:24 PM
0

From SQL Server side you can try to use SQL Profiler. But I believe what you really want is to trace the statements from the BODS right?

Show 2 Share
10 |10000 characters needed characters left characters exceeded

yes Luis, I was trying to use the trace statements. Could you tell me how to do that in BODS.

Regarding the error message, I was able to able to resolve the issue by doing the following. I was facing this error only for fields that have date data type. so what I did is I converted the date field sourcing from SAP to character & changed the data type from date to vatchar(10) in the query transform. Is there anything else that you can think of that I could have done that would be a better solution than this.

0

Yes, this is something that BODS has to provide it. I don't have expertise on this product. Sorry!

0
Arun Sasi Mar 06, 2017 at 09:03 AM
0

Can you trying using SQL Server Native client instead of ODBC driver.

Are you fetching data directly from SAP tables or using an ABAP Data flow?

Regards

Arun Sasi

Show 5 Share
10 |10000 characters needed characters left characters exceeded

The ODBC driver is the "new" native client. SQL Server Native Client has been replaced with ODBC driver.

-> https://msdn.microsoft.com/en-us/library/cc280510(v=sql.130).aspx

0

Hey Luis,

Hope you are doing good!!

Thanks for the update. I wanted to mention SQL Server Database Datastore in which there is no need to provide ODBC DSN details. This will make life easier :)

If there are issues connecting to the datastore, then there should be only need to install SQL Server Client component on the Machine where Data Services Designer is installed.

Hope this makes sense.

Regards

Arun Sasi

syghs.png (8.0 kB)
0

You are right, with the new "ODBC Driver" there are some confusions about using a DSN to access SQL Server.

0

Thank-you Luis and Arun.

So here's how i figured out that the issue was related to date data type fields. Blog Link: https://blogs.sap.com/2013/06/14/sap-data-services-41-native-client-issue/#. To resolve this I converted the date field sourcing from SAP to character & changed the data type from date to varchar(10) in the query transform. Is there anything else that you can think of that I could have done that would be a better solution than this.

0

Samique,

This is correct. You need to understand the Date format of the Source SAP Table column.

For e.g. ERDAT_VBAK date column must be in the format

2016.11.21

Now when you run the job you might encounter an issue because the Date format in SQL Server table might be different. You need to convert the date into the desired format using to_char or to_date conversion functions.

Refer to Data Services reference Guide for more details about the conversion functions

http://help-legacy.sap.com/businessobject/product_guides/sbods42/en/ds_42_reference_en.pdf

Regards

Arun Sasi

0