I have 2 tables in BigQuery. VIDEOS table contains video names and tags. CREATORS table contains information about video creators. The VIDEOS.tags field contains comma separated quoted strings. I need to select all the videos that were tagged with names in the CREATORS table with results looks like this: But what I have below does not return any results in
Tag: sql-like
SQL Query “like” operator error, when the field is null
this query returns 421 records: Now when I implement the “like” operator, it returns 349 records, it is not taking into account the records with the field “invoice_number” in null:
Execute SQL-LIKE with List attribute
I have this method on my Dao class: the sql works fine when the attribute is @Column or a @OneToOne`, but when it’s something like that: where the class Titulo has this attributes: causes this error: How I can change the method to make work for both types of attributes? Answer I manage to solve this issue with the approach
How to select from string array added in SQL column?
Below is my table, tried its not working for i want to select rows by passing colPar as ‘param1,param2’ so it will result me all the records containing param1 and param2 in colParam Answer This quiet tricky. to Return all matching values. Output:
concat only if column value does not contain any specific prefix
I want to add the prefix to column’s data those who not like if the column’s value is 123,OI:909, 456,OI:789 then it updates to OI:123,OI:909, OI:456, OI:789 I tried following SQL Answer You could try this syntax:
Sql reverse search for products and discounts
I have two table, one for products, and one for discounts. Discounts table look like: ID | Name | Percentage | Product Name Search Param ——————————————————-…
columnA like %columnB
I’m trying to do select * where column1 = % column2 %. this is my query The error: The data types varchar and text are incompatible in the add operator. Answer You can cast the text to a varchar(max): Or, if b.Client is a text too: Notes (most of which already were commented): text is deprecated; you want to use
SQL how to do a LIKE search on each value of a declared variable
I have a query where I am trying to do a LIKE search on each value of a declared variable, instead of doing a like search on the entire field value/string. Example: The record I am looking for is “John and Jane Smith”. The query above returns NO result. If the user searches just ‘John’ OR just ‘Smith’ there are
Provide the values for a ‘like’ function from a specific column in a Table?
I am using SQL Server 2014 and I need a T-SQL query which uses the like function to run on a specific column (c1) of a Table (t1) to find out if it contains one of the codes from a list of codes found …
I have problem to use like and where clause together in sql
I want to select data from the SQL table and fetch data from the table with the use of LIKE and BETWEEN clause together and I have tried below query. but it shows me the error You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use