Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8217741
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 7, 20262026-06-07T12:33:23+00:00 2026-06-07T12:33:23+00:00

I have created a new custom module and DB table for magento. What is

  • 0

I have created a new custom module and DB table for magento. What is the best wat to populate this with customer data.

For example when a new customer is created I want to store the ID of this customer in this new table as well and then use this ID to display various information in a new section within the admin.

I have created the new section but just not sure how to do the first part. The reason I want to do this is that I want to assign each customer a specific discount per category.

Thanks
Robert

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-07T12:33:24+00:00Added an answer on June 7, 2026 at 12:33 pm

    @Robert,
    there is a better way for doing this, and you do not need to create a module.

    You can associate your customers to groups in the Customer->Customer Groups menu.

    After create the customer groups, you can create a specific discount for this group and for each category. For doing this, you should:

    1. Go to Promotions -> Shopping cart price rules
    2. Click in Add new
    3. Set the name and select the group to apply
    4. Click on the Conditions tab
    5. Add a Product Attribute combination rule, and add Product Attribute Category as the attribute to verify.
    6. Select the category (or categories) that this rule applies.

    Example:
    enter image description here


    But if you want to proceed with the original idea, I suggest you create a customer attribute, instead of creating a new table. By doing this, the custom attribute can be shown at the customer information with no need to create another admin page.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I am new to Magento. I need two table in my custom module and
I have created a custom Magento module which extends the core sales order functionality
I have created a new table including a column note. The default is varchar(255)
I have created new aspx file within a module which I am going to
I am new to DNN and working with custom module in DNN, I have
I have created a new module in Orchard CMS, i have a new event
I have created a custom Rewrite Provider for IIS 7 following instructions in this
I have created a custom button called ModuleUIButton which inherits from UIButton . This
I am trying to create a custom module in magento admin. I have reached
I have a custom module in Drupal that outputs a serialized dump of data.

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.