cancel
Showing results for 
Search instead for 
Did you mean: 

maxDB SQL query log

Former Member
0 Kudos

Hi,

i was wondering if there is a way to see sql query logs.

I try to put some BLOBS in the database, on my development evironment this works fine.

But on a new machine with a new database this doesn't work.

It could be helpful so see some kind of query logs, to get en idea of what is going to be inserted

into the database.

It would be helpful anyway to get a log of the sql statements passed to the database system.

Thanks for any help

Accepted Solutions (0)

Answers (3)

Answers (3)

Former Member
0 Kudos

Hi,

you can check "Select * from INFO_STATE" to have an overview of all

statistics that are available

Eg: Select "Log (%)" From INFO_STATE

Select "Data (%)" From INFO_STATE

It will shows the overview of all statitics.

Regards,

Sekhar

thorsten_zielke
Contributor
0 Kudos

Hi,

although SAP MaxDB logs all data manipulating statements in the log volumes, this information cannot be retranslated into SQL statements.

If you wanted to track DDL (Data Definition Language) commands, you would find these via the SYSDDLHISTORY table. However, there is no such internal table for DML (Data Manipulation Language) commands in SAP MaxDB.

I think you should try to catch your insert statements on application level. If this is not possible, you could try to issue a 'select * from runningcommands' and enable the SAP MaxDB Command Monitor to check which commands are caugth by your constraint settings.

This might seem obvious, but have you verified that your transactions were actually commited, e.g. is either 'autocommit' enabled in your SQL client or did you make sure to manually commit your inserts?

Thorsten

Former Member
0 Kudos

Hi Thorsten,

it's a pity that this isn't possible. But if I imagine the amount of informations necessary to reproduce all the statements

I guess its ok. We already write wrong statements or debug information to log files. But the BLOB statements

appear only in a kind of prepared statement without blob data.

But we found out, that the problem was in the implementation of the odbc driver in php 3.3.5.

But thank you for your advice.

regards

Jan

hannes_kuehnemund
Active Contributor
0 Kudos

moved from Linux forum to MaxDB forum