Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6247367
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 24, 20262026-05-24T12:51:27+00:00 2026-05-24T12:51:27+00:00

I come from mySQL to SQL Server. Doesn’t the following syntax work in SQL

  • 0

I come from mySQL to SQL Server. Doesn’t the following syntax work in SQL Server?

 INSERT INTO table SET fil1="234", fil2="324"

Is there an comparable statement in SQL Server?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-24T12:51:29+00:00Added an answer on May 24, 2026 at 12:51 pm

    The SET way to insert records is not standard SQL. If you need it to use similar sql’s for updates and inserts, you should use Stored-Procedures in MS SQL-Server instead, for example:

    CREATE Procedure tableInsertUpdate
    (
         @ID int,
         @fil1 int,
         @fil2 int,
         @IDOut int OUTPUT
    )
    AS
         IF EXISTS(SELECT ID from table WHERE ID=@ID)
         BEGIN
            UPDATE table SET
                fil1 = @fil1 
                fil2 = @fil2 
            WHERE ID=@ID
            SET @IDOut=null
          END
          ELSE
          BEGIN
             INSERT INTO table 
             (fil1, fil2)
             VALUES
             (@fil1, @fil2 )
             SET @IDOut=scope_identity()
          END
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I come from a SQL Server background and thought that it might mean it
I have a MySQL Server set to UTC (@@global.time_zone = '+00:00') and a table
folks, from the following code int a = mysql_query(conn,INSERT into data VALUES (NULL,'tes','aja')); how
as SQL server support .net well because both come from MSFT. but mostly i
I am converting mysql sprocs to SQL Server. I've come across a select statement
I am somewhat new to MySQL (come from MS SQL) and have recently come
I come from a linux/apache/php/mysql background. For my current project, I am forced to
I come from a Java background, where packages are used, not namespaces. I'm used
I come from the Microsoft world (and I come in peace). I want to
I come from a .NET world and I'm new to writting C++. I'm just

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.