Skip to content

Settings and activity

2 results found

  1. 15 votes

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)

    We’ll send you updates on this idea

    1 comment  ·  SQL Prompt  ·  Admin →
    How important is this to you?

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)
    jbelina supported this idea  · 
  2. 7 votes

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)

    We’ll send you updates on this idea

    3 comments  ·  SQL Prompt  ·  Admin →
    How important is this to you?

    We're glad you're here

    Please sign in to leave feedback

    Signed in as (Sign out)
    An error occurred while saving the comment
    jbelina commented  · 

    Here's a workaround you can use in Excel...

    Step:
    1) Create a spreadsheet and paste in your list starting in A1.
    2) Insert a row above row 1
    3) In B1 put the following text: IN (
    4) In B2 put the following formula: =CONCATENATE($B1,"'",$A2,"',")
    5) Click B2 and Drag the bottom right corner down until it goes as far as your list
    6) Click on the last item in column B and change the formula replacing the last comma with a closing parenthesis similar to the following:
    =CONCATENATE($B3,"'",$A4,"')")
    7) Copy the item you just changed into your SQL Query and you should end up with something like your original clause:
    IN ('item 1','item 2','item 3')

    Works great for a long list... :D

    jbelina supported this idea  ·