SQL Server Performance

Data Type Table

Discussion in 'General Developer Questions' started by Zambratp, Jul 9, 2003.

  1. Zambratp New Member

    Hi All:

    I am trying to hold 6 tables memory so developers can use them there without banging against the DB...I know the scope issue....I want to be able to set the tables in memory in one sp/batch/function and be able to manipulate all of them at the same time...I have tried a few things...BUT I get either no data, wrong data or syntax errors..is this possible....

    If you need to see what Iver tried Ill post that...
  2. Chappy New Member

    Table datatypes are primarily for an in-memory alternative to #temporary tabes, which exist on disk in tempdb. They are not designed to allow you to host a full table already in your database, into memory.
    Even if they were, you would need to hit the database in order to populate them.

    If you *really* need the tables to be held in memory and not on disk, then you can instruct sql server to pin them into memory, which will prevent pages for those tables from being flushed out of the memory cache, once they are in the cache. See DBCC PINTABLE for more details, but you should fully understand the consequences if you choose to do this.

    Can you tell us the real problem you are experiencing? Why do you want them in memory? poor performance, concurrency issues etc

    Regards

  3. Zambratp New Member

    Thanks....I will look into that....I am just trying to take the load off of the C/C++ developers ..they are considering using link lists to store data and hit against it..but if I could make a function or stored procedure that could take data into memory they would not have to write that code...

Share This Page