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

  • SEARCH
  • Home
  • 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 8668211
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 12, 20262026-06-12T18:09:28+00:00 2026-06-12T18:09:28+00:00

My query in SQL Sever: INSERT INTO BIT_Dashboard.dse.L_Projectgroup (Projectgrouptype_CD) VALUES ( CASE Projectgroup_NAM WHEN

  • 0

My query in SQL Sever:

INSERT INTO BIT_Dashboard.dse.L_Projectgroup (Projectgrouptype_CD) VALUES
(
CASE Projectgroup_NAM

    WHEN ( 
         'BLA'
        | 'BI Projekt'
        | 'PDP'
        | 'VBM'
        ) THEN ('PRO')
END
)

I am getting the following error:
“Invalid column name ‘Projectgroup_NAM’.”

he thing is (maybe I forgot to emphasise that) is that I already have some rows in the table and I would like to update the Projectgrouptype_CD in the certain row with the query. What am I doing wrong?

Wha is my query not working?

  • 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-06-12T18:09:29+00:00Added an answer on June 12, 2026 at 6:09 pm

    Try to change it to select statement:

    INSERT INTO BIT_Dashboard.dse.L_Projectgroup (Projectgrouptype_CD)
    select
       CASE 
          WHEN Projectgroup_NAM in('BLA','BI Projekt','PDP','VBM') 
            THEN ('PRO')
       END
    from BIT_Dashboard.dse.L_Projectgroup
    

    I’m not sure table BIT_Dashboard.dse.L_Projectgroup is correct, but It’s an example.

    Update syntax:

    update BIT_Dashboard.dse.L_Projectgroup
      set Projectgrouptype_CD = 'PRO'
    WHERE Projectgroup_NAM in('BLA','BI Projekt','PDP','VBM') 
    

    If you need more case

    update BIT_Dashboard.dse.L_Projectgroup
          set Projectgrouptype_CD = 
            case 
              WHEN Projectgroup_NAM in('BLA','BI Projekt','PDP','VBM') then 'PRO'
              WHEN Projectgroup_NAM in('BIT') then 'BIT'
            END
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have comma-separated values. I need a query to insert into SQL Server 2008
I'm trying to convert a MS Access query into a SQL Sever stored procedure
I ran this query on my SQL Server database: begin transaction; insert into [db].[a].[Table1]
I have a SQL query, it looks like that: insert into tableA(order_id, contractnotenumber, shipmentdate,
I'm trying to find a query for sql that will just insert values but
I have a query in SQL Server: insert into [Sha1]( [IDTbl] ,[IDTbl_old] ,[IDold] ,[WordsAsl])
Consider the following sql server query , DECLARE @Table TABLE( Wages FLOAT ) INSERT
I'm trying to insert rows on SQL Server using a JDBC driver. The query
When I perform a select/Insert query, does SQL Server automatically create an implicit transaction
I want to insert a datetime value into a table (SQL Server) using the

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.