Page 1 of 1

Create class with constant strings from mysql table row values

Posted: Tue 30 Mar 2021 17:33
by francis
Hi,

Is there any template to create a class with constant strings from mysql table row values?

I am using .NET Core 5.

Code: Select all

CREATE TABLE list_permissions (
  permission_name varchar(255) binary NOT NULL,
  PRIMARY KEY (permission_name)
)
INSERT INTO list_permissions(permission_name) VALUES
('allowed_to_do_x'),
('allowed_to_do_y');
Desired imported class:

Code: Select all

using System;
namespace MyApp
{
    public static class Permissions
    {
        public  const string AllowedToDoX= "allowed_to_do_x";
        public  const string AllowedToDoY= "allowed_to_do_y";
    }
}

Re: Create class with constant strings from mysql table row values

Posted: Wed 31 Mar 2021 17:16
by Shalex
This functionality is currently not available. Please submit your suggestion at https://devart.uservoice.com/forums/386 ... -developer.