cancel
Showing results for 
Search instead for 
Did you mean: 

BSEG, REGUP Data Extraction from MSSQL

Former Member
0 Kudos

Hi,

For an audit purpose we have an requirement to extract data from BSEG, REGUP tables.

We have an ECC 6 system with MSSQL database.

How can we extract BSEG data from MSSQL.

Regards

Rahul

Accepted Solutions (0)

Answers (2)

Answers (2)

Former Member
0 Kudos

Hi,

*BSEG : Accounting documents

*REGUP: processed payment detail for items

Since they are FI/CO related data you need to double check what exactly they are looking for and get prior approvals before proceeding.

You need to make Z program/FM in ABAP to extract data and display to auditors rather using MSSQL management studio or any other tools for extraction (extracting financial data from tools other than ABAP program is violation i guess).

Regards.

markus_doehr2
Active Contributor
0 Kudos

> For an audit purpose we have an requirement to extract data from BSEG, REGUP tables.

> We have an ECC 6 system with MSSQL database.

> How can we extract BSEG data from MSSQL.

I wouldn't extract the data but do the necessary programs in the system itself, those tables are usually very big.

However, there are many methods of doing this:

- write an ABAP that opens a file and writes it into a text file

- use SQL Server Management studio

- use an SQL script

- connect Excel and/or Access via ODBC and extract the data

The latter one is the most dangerous one since there's only one user for the whole system, and that use can even (accidentally) drop full tables.

Markus

Former Member
0 Kudos

A quick way is using bcp to extract the data. Could look like this (from command prompt):


bcp "select * from <SID>.<sid>.BSEG where <my search conditions>" queryout BSEG.txt -T -c

Have a look at the documentation of bcp or search the net. It's an excellent tool.

Regards,

Sven

Former Member
0 Kudos

Hi Markus,

At MSSQL Level, table BSEG is not available. It is a pool/cluster to RFBLG.

In this scenario, how can extract the BSEG data from MSSQL Management Studio.

Regards

Rahul

markus_doehr2
Active Contributor
0 Kudos

> At MSSQL Level, table BSEG is not available. It is a pool/cluster to RFBLG.

...so you can't use database methods but you have to use ABAP methods/FMs to extract the data.

Markus

William_Laverde
Product and Topic Expert
Product and Topic Expert
0 Kudos

Hello,

In SAP BSEG is a table (cluster-table) and it holds data related to Accounting Doc. Item (FI/CO), I would like to suggest you to check how many entries this table holds I am sure it can be well over 1 million. Tale a look at this note it may be of assistance to you 574350