Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Create a Temp Table In SQL Server
Message
Information générale
Forum:
Visual Basic
Catégorie:
Bases de données DAO/RDO/ODBC/ADO
Divers
Thread ID:
00543280
Message ID:
00543472
Vues:
28
You can create local and global temporary tables. Local temporary tables are visible only in the current session; global temporary tables are visible to all sessions.
What if you try using stored procedure for your stuff?
(So this way it will be shure that's in the same session, well if not, we have a problem...)
Like:
(SQL)
CREATE PROCEDURE sp_Test
AS
SET NOCOUNT ON
SELECT 
    output_file.* 
INTO 
    #tblNewTables 
FROM 
    output_file
WHERE 
    output_file.Phys_Num = '000303'

-- Part II
SELECT
    * 
FROM 
    #tblNewNames
and then call your sp in your code like:
(you will need a command object)
set cmd.ActiveConnection = (Your connection obj)
cmd.CommandType = adStoredProc
cmd.CommandText = "sp_Test"
set rs = cmd.Execute
Hope this will help (and work...).
Patrice Merineau
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform