Results 1 to 4 of 4

Thread: [RESOLVED] Working with data question

  1. #1

    Thread Starter
    New Member
    Join Date
    Jan 2013
    Posts
    9

    Resolved [RESOLVED] Working with data question

    Hello friends.

    I am a ABAP (SAP programing language) programer and in ABAP we have the concept of "Internal Table".

    Internal table is a table resident in memory, not in the Database.

    For example, if we want to retrieve from database a list of clients (that are stored in database table KNA1) so that we can use later for any purpose, we do a select to that table and put the data into an Internal Table....afterwards when we need to access this data, instead of reading the database again, we read this Internal Table from memory. This is a way of reducing database reads and increase performance.

    The access to the Internal Table is almos the same as to a Database Table. To a database table we do "SELECT *" or "SELECT SINGLE" to read several or just one record, and to an Internal we do "LOOP AT" or "READ TABLE" to read several or just one record.

    My question is...is there anything like this in Visual Basic ?

    Thank you all for reading and I'll be waiting for your answers ,

    Bleeding_me

  2. #2
    Serge's Avatar
    Join Date
    Feb 1999
    Location
    Scottsdale, Arizona, USA
    Posts
    2,744

    Re: Working with data question

    Visual Basic is not a database engine, so the question should really be: does "this particular type of database engine" have this function?
    For SQL Server, you really have 2 options.

    1. Use global temp tables with "create ##MyTempTableName
    Global temporary tables (CREATE TABLE ##t) are visible to everyone, and are deleted when all connections that have referenced them have closed.
    2. Create a table in Temp database
    Tempdb permanent tables (USE tempdb CREATE TABLE t) are visible to everyone, and are deleted when the server is restarted.

  3. #3
    PowerPoster techgnome's Avatar
    Join Date
    May 2002
    Posts
    34,687

    Re: Working with data question

    SQL Server has a thrid option - table variables:

    Code:
    DECLARE @tempTabl table (
    Field1 int,
    Field2 nvarchar(10)
    )
    From there you can use it like any other "table" ... insert into it, select from it, update, etc...

    -tg
    * I don't respond to private (PM) requests for help. It's not conducive to the general learning of others.*
    * I also don't respond to friend requests. Save a few bits and don't bother. I'll just end up rejecting anyways.*
    * How to get EFFECTIVE help: The Hitchhiker's Guide to Getting Help at VBF - Removing eels from your hovercraft *
    * How to Use Parameters * Create Disconnected ADO Recordset Clones * Set your VB6 ActiveX Compatibility * Get rid of those pesky VB Line Numbers * I swear I saved my data, where'd it run off to??? *

  4. #4

    Thread Starter
    New Member
    Join Date
    Jan 2013
    Posts
    9

    Re: Working with data question

    Thank you all for your answers

Tags for this Thread

Posting Permissions

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



Click Here to Expand Forum to Full Width