Collaborate to Innovate: How a Social Network Can Help You Find Your Dream Pair Programming Team
Tags: apacheage, postgres, pairprogramming, webdev
Published: 2023-03-29 21:52:43

## INTRODUCTION
**Software engineering** is a constantly growing field that offers a vast array of opportunities to improve your skills in various stacks. However, finding a team of like-minded programmers to grow and learn with can be a challenge. In this article, I'll introduce the idea of a social networking platform designed to help you find the perfect **programming partner**.

![Programming languages](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/q0flictzxzobsfokglqm.png)

 

## HOW DOES IT WORK?

With the right partner, you can accelerate your learning and development, push each other to new heights, and achieve your goals together. This social networking platform would bring together programmers with similar interests and skills, allowing them to connect, studying together, collaborate, and build meaningful projects.

![Programming partner](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/t4n3j2gl4v65zn05jfxe.png)


## GRAPH DATABASE BUILDING

To follow along with this project, I'll be using **Apache AGE**, a powerful graph database that can help manage connected data with ease. To get started, you'll need to install Apache AGE. You can find the link to the repository in the references section below.
- For create the database we need to run the following commands on our terminal.
```sql
SELECT * FROM ag_catalog.create_graph('devbook');
```
- Creating persons of the social networking

```sql
SELECT * FROM cypher('devbook', $$ CREATE 
   (:Person { name: 'Marcos', title: 'backend', languages:['C', 'Ruby'], age: 23 }), 
   (:Person  { name: 'Tito', title: 'backend', languages:['Python', 'Java'],  age: 20 }),
   (:Person  { name: 'Maria', title: 'frontend', languages:['Lua', 'React'],  age: 18 }),
   (:Person  { name: 'Daniel', title: 'backend', languages:['PostgreSQL', 'Java'], age: 19 }),
   (:Person  { name: 'Victor', title: 'frontend', languages:['HTML', 'MongoDB'],  age: 26 }),
   (:Person  { name: 'Sophie', title: 'frontend', languages:['Angular', 'R'],  age: 18 })
$$) as (Person agtype);
```

## OBJECTIVE
Match people based on the stack they know, for example, frontend or backend. In this way, we'll help people connect with others who are in their same area of interest.
- Backend Dev's
```sql
SELECT *
FROM cypher('devbook', $$
    MATCH (a: Person), (b: Person)
    WHERE a.title = 'backend' AND b.title = 'backend' AND id(a) <> id(b)
    CREATE (a)-[e:STACK_MATCHES { title: 'backend' }]->(b) RETURN e
$$) as (relationship agtype);
```
- Frontend Dev's

```sql
SELECT *
FROM cypher('devbook', $$
    MATCH (a: Person), (b: Person)
    WHERE a.title = 'frontend' AND b.title = 'frontend' AND id(a) <> id(b)
    CREATE (a)-[e:STACK_MATCHES { title: 'frontend' }]->(b) RETURN e
$$) as (relationship agtype);
```

## MATCHES

For visualize the vertices and nodes, I'm using the **APACHE AGE VIEWER** you can install it by the link in the references section.
![Apache AGE Viewer](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/zajqq9xppeq89nk00lpf.png)

## CONCLUSION 
Currently, I'm matching people based on the stacks they know, but there are many other ways to match people.
- Matching people based on their industry or domain expertise (e.g. finance, healthcare, education)
- Matching people based on their programming language knowledge (e.g. Python, Java, C++)
- Matching people based on their project experience (e.g. web development, mobile app development, data science)
- Matching people based on their soft skills (e.g. communication, collaboration, leadership)
- Matching people based on their location or time zone for better collaboration and communication.

By exploring different matching criteria, we can help people connect with others who share their interests and goals, ultimately leading to more productive and enjoyable collaborations.

**References:**
- [APACHE AGE](https://github.com/apache/age)
- [AGE VIEWER](https://github.com/apache/age-viewer)
- [POSTGRESQL](https://www.postgresql.org)