Skip to main content

Hi, I am using Create table syntax to create a global temp table and then use insert to insert 5000 rows into the temp table. However, only 400 to 900 rows get inserted. Is this the limitation in table or am I missing anything ? Below is the create and insert code use:

 

IF OBJECT_ID('tempdb..##id') IS NOT NULL

BEGIN

DROP TABLE ##id

END

CREATE TABLE ##id(Id VARCHAR(50))

Insert INTO ##id(Id) VALUES('14452')

Insert INTO ##id(Id)  VALUES('33666')

 

Many thanks in advance for the help!

 

Amy

답변 3개
  1. 2022년 2월 16일 오전 4:58

    Yes I think so, sorry @Amy Amy​. Depending on your version, do you have the option to join onto a CSV file with those ids as well potentially? E.g. in the example below I've added and then joined a separate Excel sheet on the Superstore sample data set (in this case for some data densification hence the join on 1=1, you would join on Id presumably).

    Yes I think so, sorry @Amy Amy​. Depending on your version, do you have the option to join onto a CSV file with those ids as well potentially? E.g.Please do upvote anything that's been helpful and, if appropriate, mark an answer as "best" to close off the thread and help people searching in the future.

    Ta, Steve.

    Ta, Steve.

0/9000