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 6326011
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 24, 20262026-05-24T17:00:03+00:00 2026-05-24T17:00:03+00:00

I use the query Select t1.name as first, t2.name as second From products t1,

  • 0

I use the query

Select t1.name as first, t2.name as second From products t1, products t2

that creates two columns like below. (A,B are for explaining purposes)

Before the query

-name-
A
B
C
D
E

After the query

-first- -second-
A        A
B        A
C        A
D        A
E        A
A        B
B        B
C        B
D        B
E        B

How to check if a row of the first column is similar to the second ?

UPDATE

I run mySQL

With similar, I mean like to find their similarity percentage are more of a specified value. Like if the first contains this is a string and second i wear a string there is a percentage of similarity. If this % is more than 70 then they are similar.

  • 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-24T17:00:07+00:00Added an answer on May 24, 2026 at 5:00 pm

    there are many ways, here is one that will give you all the products that match your criteria (first = second)

    SELECT
      t1.name AS first, t2.name AS second 
    FROM
      products t1, products t2
    WHERE
      t1.name = t2.name
    

    or, if you need all the values

    Select
      t1.name as first t2.name as second, (if t1.name = t2.name THEN 1 ELSE 0) as match
    From 
      products t1, products t2
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a query like below select f.id, s.name, ss.name from first f left
I have a query that looks like the following SELECT t1.Name, t2.ID, t2.name FROM
I want to use a query like: sql(select name where id > 10 and
I am trying to use Zend_Db_Select to write a select query that looks somewhat
We can use solr range query like: http://localhost:8983/solr/select?q=queryStr&fq=x:[10 TO 100] AND y:[20 TO 300]
I have a query: declare @Code nvarchar(100) select @Code=BMW select name from NewCars where
I have the following query: SELECT wm_concat(DISTINCT NAME) as Methods FROM TPM_TRAININGPLAN JOIN TPM_DELIVERYMETHODS
My db tables look like that First table: Second table - lastsrvc (Last service
I use my first query to get the id and name of the user
Can a select query use different indexes if a change the value of a

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.