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 8729659
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 13, 20262026-06-13T08:52:16+00:00 2026-06-13T08:52:16+00:00

I have a requirement to add an alternative language version of a single article

  • 0

I have a requirement to add an alternative language version of a single article in an ASP.NET MVC project. I currently have a db table called NewsArticle which has the fields ArticleId, Abstract, Headline, BodyText, and ImageUrl. I would like to essentially have an option when authoring a news article that provides the author with a field to enter an alternative langauge version of the article. This alternative content can then be displayed on the news articles view for that particular language through the language-switching control of the site.

Can anyone point me towards the right direction in as far re-designing the existing model to include this requirement?

  • 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-13T08:52:18+00:00Added an answer on June 13, 2026 at 8:52 am

    Managed to get around this by creating two tables for each multilingual object i.e. split NewsArticle into two tables NewsArticleText (with the localized content, one record per language, plus the ISO code of the language) and NewsArticle (with the language-neutral data; ArticleId, ImageUrl, etc.) A third table Languages is created with all the languages used and its ISO code as primary key.

    Example:

    Table "NewsArticle"
    -------------------
    ArticleId                 : uniqueidentifier
    <any other language-neutral fields>
    
    
    Table "NewsArticleText"
    -----------------------
    ArticleId          : uniqueidentifier (foreign key referencing the NewsArticle)
    LanguageCode       : varchar(6)  (e.g. "en-GB", "de-CH", foreign key referencing the Languages table)
    Headline           : varchar(100)
    BocyText           : varchar(max)
    <any other localized data>
    
    Table "Languages"
    -----------------
    LanguageId         : uniqueidentifier
    LangaugeCode       : varchar(6)
    Name               : varchar(20)
    

    Querying the db would be based on the language parameter, e.g. the following code returns all English language articles:

    // get all English language articles 
    var news = from na in datacontext.NewsArticles
        where na.Deleted == false
        join nt in datacontext.NewsArticlesText 
            on na.ArticleId equals nt.ArticleId
        where nt.LanguageCode == "en-GB"
        select new NewsArticleItem
        {
           ArticleId = na.ArticleId,
           ImageUrl = na.ImageUrl,
           Headline = nt.Headline,
           Abstract = nt.Abstract,
           BodyText = nt.BodyText,
           LanguageCode = nt.LanguageCode,
           DateCreated = na.DateCreated
        };
    return news.ToList();
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm working with Windows Azure Table Storage and have a simple requirement: add a
I have a requirement to add a standard drop-down from which you can select
Can i add two header text in Datagrid? My Requirement is to have two
I have requirement like, suppose I have a 'property' table which has 'ListingKey' field
I have a requirement to add commenting system to a page (similar to 'Post
I'm working in Drupal 6. I have a requirement to add a particular block
I recently moved to a project where I noticed there have a specific requirement
We have a requirement to add an event reminder when a user enters their
I have a requirement to add StringLengthAttribute validation to a lot of models in
In my native iPhone Application, I have a requirement to add a reminder to

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.