SQL Streamline how to copy data from excel

Stephen Liang 21 Reputation points
2021-02-18T08:15:25.513+00:00

hi. I am new. I created Streamline database , with table [Records]. I then proceed to edit top 200 lines. then copy and paste datas row by row from excel into Streamline table [Records]. Error message ![69455-image.png][1] [1]: /api/attachments/69455-image.png?platform=QnA The table created : CREATE TABLE Archive.dbo.Records ( [Id] [uniqueidentifier] ROWGUIDCOL NOT NULL UNIQUE, Ref1 varchar (50) not null,Ref2 varchar (100) not null, Name1 varchar(max)not null, Date1 date not null,Currency varchar (5), Amount varchar (30),Memo1 varchar(max), Memo2 varchar(max), [Chart] VARBINARY(MAX) FILESTREAM NULL ) GO I can paste excel data into non streamline table ...Please advise how to do. thanks

Transact-SQL
Transact-SQL
A Microsoft extension to the ANSI SQL language that includes procedural programming, local variables, and various support functions.
4,575 questions
0 comments No comments
{count} votes

Accepted answer
  1. MelissaMa-MSFT 24,176 Reputation points
    2021-02-18T08:42:20.667+00:00

    HI @Stephen Liang ,

    Welcome to Microsoft Q&A!

    A column or local variable of uniqueidentifier data type can be initialized to a value in the following ways:

    • By using the NEWID or NEWSEQUENTIALID functions.
    • By converting from a string constant in the form xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx, in which each x is a hexadecimal digit in the range 0-9 or a-f. For example, 6F9619FF-8B86-D011-B42D-00C04FC964FF is a valid uniqueidentifier value.

    Please refer below example:

    DECLARE @id uniqueidentifier  
    SET @id = NEWID()  
      
    insert into Archive.dbo.Records (Id,Ref1,Ref2,Name1,Date1) values  
    (@id,'a','b','c',GETDATE())  
      
    select * from Archive.dbo.Records  
    

    Output:

    Id Ref1 Ref2 Name1 Date1 Currency Amount Memo1 Memo2 Chart  
    6845E57D-68DA-4544-9FFB-D2EF56562096 a b c 2021-02-18 NULL NULL NULL NULL NULL  
    

    Best regards
    Melissa


    If the answer is helpful, please click "Accept Answer" and upvote it.
    Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.


1 additional answer

Sort by: Most helpful
  1. Yusuf Brat 1 Reputation point
    2021-02-18T23:16:42.517+00:00

    69697-phpinfo-metadata.gif

    0 comments No comments