Application Development and Automation 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: 
Read only

EXEC SQL - GET DATABASE STRUCTURE - RECREATE IN SAP

Former Member
0 Likes
451

Our system is connected to PS.

II'd like to write a program that does the following

  • get the structure of the database

  • create the structure in SAP

  • SELECT THE DATA OF THE TABLE

This would be done in order to maintain the structure manually

The problem is to get the structure from external database (exec sql)

Thanks for your help!

Regards,

2 REPLIES 2
Read only

Former Member
0 Likes
387

You will have to write a stored procedure in Oracle or SQL-Server in which you will fetch the structure .Now using native SQL commands (EXEC SQL) you can call the stored procedure in ABAP by passing the parameters if only.Refer the help on EXEC SQL for calling stored procedures.

Read only

Former Member
0 Likes
387

Hi stephan,

1. In oracle , there is one standard view

eg. V_ALL_TAB_FIELDS

in which we pass the table name,

and it returns, the records,

for the fieldnames, field type, its length, its sequence number etc.

2. Similarly u may discover for PS also.

regards,

amit m.