Click here to Skip to main content
15,886,799 members

Temporary tables in SQL 2005

NanaKwame asked:

Open original thread
Hi Friends,
I have created temporary table in my project and it works, that is when I runs it. But I do not know much about temporary tables.
I would like to know if that is all that it takes to create temporary tables. I also would like to know if I can use stored procedure to execute the temporary table when I want to insert data into the tables from the front end application.

If there's more to it I will be willing to know.
Any assistance will be helpful.

This the actual table that I will be creating the temporary table for.
SQL
CREATE TABLE ITEMCODE_REGISTRATION 
( 
	ITEMCODE NVARCHAR(20)NOT NULL,
	ITEMNAME CHAR(50)NOT NULL,
	CATEGORY CHAR(25)NOT NULL
)

Please this is the temporary table I created
--Temporary table
SQL
CREATE TABLE #ITEMCODE_REGISTRATION 
( 
	ITEMCODE NVARCHAR(20)NOT NULL,
	ITEMNAME CHAR(50)NOT NULL,
	CATEGORY CHAR(25)NOT NULL
)


Thanks.
Tags: SQL Server 2005, SQL Server

Plain Text
ASM
ASP
ASP.NET
BASIC
BAT
C#
C++
COBOL
CoffeeScript
CSS
Dart
dbase
F#
FORTRAN
HTML
Java
Javascript
Kotlin
Lua
MIDL
MSIL
ObjectiveC
Pascal
PERL
PHP
PowerShell
Python
Razor
Ruby
Scala
Shell
SLN
SQL
Swift
T4
Terminal
TypeScript
VB
VBScript
XML
YAML

Preview



When answering a question please:
  1. Read the question carefully.
  2. Understand that English isn't everyone's first language so be lenient of bad spelling and grammar.
  3. If a question is poorly phrased then either ask for clarification, ignore it, or edit the question and fix the problem. Insults are not welcome.
  4. Don't tell someone to read the manual. Chances are they have and don't get it. Provide an answer or move on to the next question.
Let's work to help developers, not make them feel stupid.
Please note that all posts will be submitted under the http://www.codeproject.com/info/cpol10.aspx.



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900