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

  • Home
  • SEARCH
  • 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 8113751
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 6, 20262026-06-06T02:55:49+00:00 2026-06-06T02:55:49+00:00

I’ve been searching for ages for an answer to this. Although I’ve seen lots

  • 0

I’ve been searching for ages for an answer to this. Although I’ve seen lots of similar posts, they all seem to be answered with “You need to read the mapping data directly form the XML”, but I can’t see an example of how to do it.

I’m using EF 4.1, Database first and Dbcontext. I’m trying to implement an auditing process, which is done by overriding SaveChanges in my custom context. I query the state manager to pull back modified records etc. All standard stuff and lots of good examples out there.

However, I want to write to a single audit table in the database, which has the column name being changed and the table name that the column belongs to. Currently I’m just writing out the entity property name for the column record and the entity type to the table record. OK this works, but it’s not strictly correct as I should be writing the mapped column/table name NOT the conceptual representation. So far all my entites use exact mapping, i.e. they are the same names as the database names. However, if a developer one day creates an entity from a new table and specifies a different name for the mapping, my auditing won’t be correct. I’ll have audit details of a column name for example that doesn’t exist! Also, I know you can map an entity to more than one table. So this is what I want to do ideally:

At the the entity property level I want to find out the column name from the database and the table name it belongs to (including the full schema – i.e. for a table MySchema.MyTable I want to write to the audit table MySchema.MyTable NOT just MyTable). This process would safeguard the auditing process form developers editing mapping names, or creating entities from more than one table etc.

All the examples say you need to use the CSSpace dataset as this holds the relationship info from the data store (SSpace) to the Conceptual store (CSpace). But this is used internally and cannot be access through the metadataworkspace API, apparently. Instead am I supposed to read the XML for CSSpace directly? If so, where is this file (embedded in to the assembly?) and how can I read it? I would think that what I want to do is very basic and an obvious requirement, yet it seems sooooo difficult to do.

Any help greatly appreciated!

  • 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-06T02:55:51+00:00Added an answer on June 6, 2026 at 2:55 am

    If I understand your question correctly, the XML for the model is the model file – If you right click on the model and choose “Open With – XML editor”, you can see it.

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

Sidebar

Related Questions

I have a string like this: La Torre Eiffel paragonata all’Everest What PHP function
I'm parsing an RSS feed that has an ’ in it. SimpleXML turns this
I have a jquery bug and I've been looking for hours now, I can't
link Im having trouble converting the html entites into html characters, (&# 8217;) i
For some reason, after submitting a string like this Jack’s Spindle from a text
this is what i have right now Drawing an RSS feed into the php,
I have this code to decode numeric html entities to the UTF8 equivalent character.
I have this code: - (void)parser:(NSXMLParser *)parser foundCDATA:(NSData *)CDATABlock { NSString *someString = [[NSString
I have a text area in my form which accepts all possible characters from
Does anyone know how can I replace this 2 symbol below from the string

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.