#1 2024-03-23 02:20:22

bigheart
Member
Registered: 2014-08-01
Posts: 53

How to create table on db server with same schema

Hello,

I just want to create multiple tables using same schema.

The table name will be added the different prefix charater to prevent duplicate table names.

How to create the table using TRestServerDB?

Last edited by bigheart (2024-03-23 02:20:37)

Offline

#2 2024-03-23 09:51:45

ab
Administrator
From: France
Registered: 2010-06-21
Posts: 14,718
Website

Re: How to create table on db server with same schema

Just inherit from the TOrm sub-class of the schema.
Each class will make its own table.

Offline

#3 2024-03-23 23:50:17

bigheart
Member
Registered: 2014-08-01
Posts: 53

Re: How to create table on db server with same schema

Hi, ab

Is there a any way to use it by passing the table name as a parameter?

Offline

#4 2024-03-24 19:47:41

ab
Administrator
From: France
Registered: 2010-06-21
Posts: 14,718
Website

Re: How to create table on db server with same schema

If you define the table as "external", you can customize the name.

Offline

Board footer

Powered by FluxBB