database design question please ..!!

Results 1 to 4 of 4

Thread: database design question please ..!!

  1. #1
    mythili Guest

    Default database design question please ..!!

    I am developing a prj in asp which does the following.<BR><BR>Users may login and enter some data. This data should not be directly added into ORIGINAL tables database. It is stored in temporary tables in the same database. The data has to go through the administration and then transferred to ORIGINAL tables.<BR>But, all this process should be invisible to the user. So now I need to display his data from two data stores..<BR>One set from ORIGINAL tables - (if added in previous sessions)<BR>one set from tmp tables - (added in this session)<BR><BR>This is becoming very difficult esp. when I have 2 level hierarchy. Can some one suggest some other method? Please if some one has done it before let me know<BR><BR>thanks in advance<BR>mythili

  2. #2
    Adam Werner Guest

    Default RE: database design question please ..!!

    I worked on a similar sounding project and a direction we went with was adding a flag column to the original table. That way, we were able to discern which items had made it past the approval of the administer, and those that had just been entered.<BR><BR>If there&#039s no business reason that the data should be kept in two separate tables, I would strongly recommend that the data be kept in one with the addition of some sort of indicator.<BR><BR>The equivalent of your &#039ORIGINAL DATA&#039 table, in this design, is a simple query away.

  3. #3
    mythili Guest

    Default RE: database design question please ..!!

    Adam,<BR>thanks for responding quickly.<BR>I think I need to keep the data in tmp tables because I need to take care of every small modification the client does(changing of values). I certainly can&#039t keep these &#039modified records&#039 in the same table(original table). There will be a problem of Primary key and performance as the size increases.<BR>Now,<BR>I have a flag in the temp table to know whether that record<BR>is added/modified/deleted. Everything is fine except for that there is one table which is dependent on another table. To get the data, I need to do lot of excercise between Original and temp tables. I tried keeping only the flag in orig table and tmp table separately, but it does not make any difference with the queries.<BR><BR>Anyway thanks again.

  4. #4
    Join Date
    Dec 1969

    Default RE: database design question please ..!!

    I am looking for a solution to a problem that is very similar. Basically, every edit to the data in the database has to be approved by certain individuals. <BR><BR>My initial thoughts about this problem were to store the UPDATE SQL in a table, along with a description and an approval flag. For instance, "Change title to Three Blind Dogs", "Pending Approval", "UPDATE tblStory SET Name=&#039Three Blind Dogs&#039 WHERE ID=4".<BR><BR>Concerns though that I had with this were:<BR><BR>a) Being able to uniquely identify a row, even across time. I would not want an Update query sitting, and have the target record deleted and a new one put in it&#039s place that gets some data squashed when the update query runs.<BR><BR>b) Transactional updates, so that a set are done all at once, or not at all.<BR><BR><BR>I&#039d be interested in hearing about any solutions that other people have tried or come up with.<BR><BR>James Foster<BR>

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts