question

Patrick Cloutier avatar image
0 Likes"
Patrick Cloutier asked Patrick Cloutier answered

Trying to write this SQL statement

I'm trying to write this SQL Statement but there is a problem with the line before last:

  1. Table result = Table.query("SELECT * FROM FRList1 \
  2. WHERE [ChoiceC2] > 0 \
  3. AND [Content] > 0 \
  4. AND [Content] < 10 \
  5. AND 'token.item.Purity' = [Purity] \
  6. ORDER BY ChoiceC2 ASC");

token.item.Purity is a string label and [Purity] is a string column in my table.

But I never get a match because of that line although there are matches that I can see.

Is my synthax correct?

Thanks a lot,

FlexSim 21.2.4
sql query
· 3
5 |100000

Up to 12 attachments (including images) can be used with a maximum of 23.8 MiB each and 47.7 MiB total.

1 Answer

Patrick Cloutier avatar image
1 Like"
Patrick Cloutier answered

I found it !!!

  1. Table result = Table.query("SELECT * FROM FRList1 \
  2. WHERE [ChoiceC2] > 0 \
  3. AND [Content] > 0 \
  4. AND [Content] < 10 \
  5. AND [Purity] = $1 \
  6. ORDER BY ChoiceC2 ASC", token.item.Purity);
5 |100000

Up to 12 attachments (including images) can be used with a maximum of 23.8 MiB each and 47.7 MiB total.