teleren/devto huggingface dataset:
🆕 Just released SurrealDB for Microsoft Windows! 🚀
Tags: database, programming, rust, webdev
Published: 2022-09-03 14:55:22

The easiest and preferred way to get going with [SurrealDB](https://github.com/surrealdb/surrealdb) on Windows is to install and use the SurrealDB command-line tool. Run the following command in your terminal and follow the on-screen instructions.

```bash
iwr https://windows.surrealdb.com -useb | iex
```

##What is SurrealDB?##

[SurrealDB](https://surrealdb.com/) is a newsql multi-model database, that operates in schemafull or schemaless mode, with tables, inter-document record links (no JOINs), and graph database modelling functionality. You can query it from the backend, or from frontend applications (Chrome, Firefox, Safari, Electron, Tauri) with javascript, with in-built permissions and authentication.

![Advanced querying & analysis](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/4lo7ye3qeb3jj092slpk.png)

With full graph 📈 database functionality, SurrealDB enables more advanced querying & analysis. Multi-table, multi-depth document relationships can be retrieved efficiently in the #database without complicated #JOINS, & without any table scans. 🥳

![Data constraints](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/le9n1cudytzy2zbt6ps3.png)

Easily ➕ add field and data constraints directly to your data in SurrealDB. Use schemafull or schemaless data access methods, so that the #database always fits to the needs of your data.

![Store and query geographical data](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/lqqywzvpbtt0texuk0od.png)

Store and query 📍🗺 geographical GeoJSON data directly in the database. SurrealDB is designed to be flexible to use for all developers. 👌

And much, much more...

More info on SurrealDB can be found below:
[SurrealDB.com](https://surrealdb.com/)
[Our GitHub repo](https://github.com/surrealdb/surrealdb)
[My previous DEV.to post](https://dev.to/jaimemh/just-launched-a-new-scalable-cloud-graph-database-any-feedbackuserstesters-appreciated-2ce1)
SASS Mixins Tutorial
Tags: programming, productivity, tutorial, webdev
Published: 2022-09-03 14:52:41

Mixins are an extremely powerful feature of Sass. We use them to group together multiple CSS declarations for reuse throughout our projects.

Say we want to create a mixin to hold the vendor prefixes for a transform property.

In SASS, we’d code it like so:
```sass
@mixin transform {
  -webkit-transform: rotate(180deg);
  -ms-transform: rotate(180deg);
  transform: rotate(180deg);
}
```
To add the mixin into our code, we then use the `@include` directive, like so:
```sass
.navbar {
  background-color: red;
  padding: 1rem;
  ul {
    list-style: none;
  }
  li {
    text-align: center;
    margin: 1rem;
    @include transform;
  }
}
```
All the code in the transform mixin will now be applied to the `li` element. You can also pass values into your mixins to make them even more flexible.

Instead of adding a specified value, add a name (using a variable, like `property`) to represent the value like so:
```sass
@mixin transform($property) {
  -webkit-transform: $property;
  -ms-transform: $property;
  transform: $property;
}
```
Now we can pass in whatever value we like, whenever we call the mixin:
```sass
@include transform (rotate(20deg));
```
## Conclusion
If you liked this blog post, follow me on [Twitter](https://twitter.com/RembertDesigns) where I post daily about Tech related things!
![Buy Me A Coffee](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/ijinng8k7bf23v0o6gkj.png) If you enjoyed this article & would like to leave a tip — click [here](https://www.buymeacoffee.com/rembertdesigns)

### 🌎 Let's Connect

- [Portfolio](https://www.rembertdesigns.co/)

- [Twitter](https://twitter.com/RembertDesigns)

- [LinkedIn](https://www.linkedin.com/in/rrembert/)

- [Hashnode](https://rembertdesigns.hashnode.dev/)

- [Devto](https://dev.to/rembertdesigns)

- [Medium](https://medium.com/@rembertdesigns)

- [Github](https://github.com/rembertdesigns)

- [Codepen](https://codepen.io/rembertdesigns)
Tech Geniuses Will Keep You Spinning (how to enjoy listening to tech podcasts)
Tags: genius, beginners, programming
Published: 2022-09-03 14:50:19

I’m listening to the [DotNet Rocks! Podcast](https://www.dotnetrocks.com/) while I’m writing this article.  It is a fantastic podcast that you should listen to whenever you get a chance.  They have great guests who share valuable information.

However, one thing struck me as I listened to the hosts & guest debate the value of microservices: 

**The Grass Is Always Greener**

> There is always a better technology to use for your project.

## As A Developer With Less Experience
If you’re a developer with less experience you may listen to one podcast or another or read various tech articles and you hear a lot of opinions.  Often, those opinions will oppose other ideas that you’ve held.  

### Best Technology Is Always The Thing You’re Currently Hearing About: Not!
As you’re reading those articles it can feel like the _current thing_ is the most important thing in software development and that all your future projects must be built on that technology or architecture or programming language.

## Leads To Feeling Like an Impostor 
All of this can often lead to feeling like an impostor.  This is just the nature of new technology arriving on the scene. 

## Resolving This Issue
Should you stop listening to podcasts and stop reading new tech articles?  Certainly not.
However, what you should do is:
1. Listen with a critical ear - Podcasters & article writers are focusing in on a specific technology or topic so you can evaluate if it is right for you and your project.  
2. Take what helps you and your project and drop the rest.
3. Keep in mind that this sparkly new technology you are hearing about is tomorrow’s legacy tech.
4. Keep in mind there are exceptions to every rule — this is especially true in the world of software.  You may hear a podcaster absolutely deriding a technology you’ve used to build your working project.  However, keep in mind that your actual working project is the important thing.
5.  Trust yourself - Even if you’ve used older technology you can always iterate and rebuild.
6. Most podcasters and article writers aren’t really trying to prove that their ideas are the absolute perfect best anyways.  They are just explaining a particular topic and concentrating on it so heavily that it can sound that way.

Keep these things in mind and you’ll enjoy listening to podcasts and reading new tech articles a whole lot more.

If you get a chance, check out the latest DotNet Rocks podcast. It’s a really great one.  All there podcasts are great discussions where you’ll learn a lot.
How Does Nesting Work in SASS
Tags: productivity, programming, webdev, tutorial
Published: 2022-09-03 14:45:18

When you observe the structure of an HTML file, you’ll notice it has a very clear hierarchy:
```html
<!DOCTYPE html>
<html>
  <head>
    <title>Page Title</title>
  </head>
<body>
 
<h1>My First Heading</h1>
<p>My first paragraph.</p>
 
</body>
</html>
```
As you can see, HTML has a structure that makes it quite easy to read.

CSS, on the other hand, lacks this visual structure. Which is why it has a tendency to become disorganized quite quickly.

Enter Sass `nesting`!

## Definition
Using nesting, we can nest child selectors inside of the parent selector.

This results in much cleaner and less repetitive code.

## Example
Take the following HTML:
```html
<nav class="navbar">
  <ul>
    <li>Home</li>
    <li>Services</li>
    <li>Contact Us</li>
  </ul>
</nav>
```
Using regular CSS, we would write this like so:
```css
.navbar {
  background-color: red;
  padding: 1rem;
}
.navbar ul {
  list-style: none;
}
.navbar li {
  text-align: center;
  margin: 1rem;
}
```
There’s a lot of repetition here. Each time we want to style a child of `navbar`, we have to repeat the class name.

With Sass nesting, we can write much cleaner code.

Like so:
```sass
.navbar {
  background-color: red;
  padding: 1rem;
  ul {
    list-style: none;
  }
  li {
    text-align: center;
    margin: 1rem;
  }
}
```
Using indentation, you can now see the `ul` and `li` selectors are neatly nested inside the `navbar` selector.

We have a much less repetitive syntax, which is far easier to read!

## Conclusion
If you liked this blog post, follow me on [Twitter](https://twitter.com/RembertDesigns) where I post daily about Tech related things!
![Buy Me A Coffee](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/ijinng8k7bf23v0o6gkj.png) If you enjoyed this article & would like to leave a tip — click [here](https://www.buymeacoffee.com/rembertdesigns)

### 🌎 Let's Connect

- [Portfolio](https://www.rembertdesigns.co/)

- [Twitter](https://twitter.com/RembertDesigns)

- [LinkedIn](https://www.linkedin.com/in/rrembert/)

- [Hashnode](https://rembertdesigns.hashnode.dev/)

- [Devto](https://dev.to/rembertdesigns)

- [Medium](https://medium.com/@rembertdesigns)

- [Github](https://github.com/rembertdesigns)

- [Codepen](https://codepen.io/rembertdesigns)
Common technical decisions you will make when building a SaaS product from scratch.
Tags: startup, aws, java, sql
Published: 2022-09-03 14:27:43

### 

In the course of building a product, we make technical decisions every other day. These decisions could be small decisions or big decisions. These could be reversible or irreversible decisions. Though there is no technical decision that is irreversible, it’s the amount of effort that makes it going back rather improbable. Architectural Design Decisions that a tech team makes at the start of product building fall into the category of big irreversible decisions.

Once these decisions are made, any tech lead will keep making smaller reversible decisions every other day with a few occasional big irreversible decisions. Here are some of those big technical decisions that we’ve made at [AnalyticsVerse](https://analyticsverse.com).

☁ AWS over Other Cloud Platforms
One of the major reasons why we chose AWS over other cloud providers was our familiarity with AWS. In addition, the amount of resources available on the internet for AWS is sufficient to get anyone up to speed in a couple of weeks.

☕ Java over Python
It is no secret that Java is much faster than Python. Speed of code execution was one of the biggest advantages of Java over Python. This has helped us provide a much better experience to our customers by generating reports faster.

🔢 SQL over NoSQL
Since AnalyticsVerse generates reports by correlating data across different tools such as Git Repositories and Task Tracking tools, all of this data had an inherent relation between them making SQL the go-to choice for us.

🖥 Server over Serverless
With Serverless, there comes the problem of warming/provisioning lambdas. This option turned out to be costlier as compared to running an instance behind a load balancer with autoscaling rules. In addition, the traffic that we serve is somewhat predictable which made not going serverless more suitable for our use case.

⌛ Airflow over Step Functions
Our first choice for setting up our data pipelines was Step Functions. However, one of the founders proposed we could evaluate Airflow. With airflow, we got an inbuilt scheduler as well in addition to being able to set up DAGs jobs. With airflow, we could easily support on-prem deployments from the get-go. We did face a challenge with scaling airflow a few months later, however that is an individual post in itself.

☁ Terraform over Cloudformation
In terms of the effort, it takes for setting up an Infra using terraform or cloud formation we found there was no difference. Terraform provided more control over state as compared to cloud formation and with terraform, we had an added advantage of being cloud-provider agnostic like most of our choices above.

The scaling challenge that I mentioned about airflow above was one such challenge that forced us to start thinking of alternatives. However, being a big irreversible decision, we were not very keen on moving out of airflow (given the effort it would take us :P) which forced us to think of creative ways to solve the scaling problem without having to increase compute power.
Why did I switch from an MNC to a Startup?
Tags: startup, career
Published: 2022-09-03 14:09:49

If a year ago someone would have come up to me and told me to quit my safe, conservative job, my reaction would have been, "Are you crazy!?".

But then, an opportunity came up which forced me to think about just that. And I had a choice to make.

But this was not the first time in my short life so far that I found myself standing at the crossroads. And every time, there would be the opinions of thousands of people regarding what I should and shouldn't do. But I have learned to trust my gut above anything else while making these decisions. And here I am today, doing exactly what I had never imagined I would!

Yes, I quit my job at Morgan Stanley to start an exciting new journey as one of the co-founding members of [AnalyticsVerse](https://analyticsverse.com/)!

In that context, many people in my network often ask me this question - Should I join a startup? Or should I work in an MNC? Well, the answer to that will always be subjective to what you are looking for in your career. But here are some key differences that I have noticed based on, but not limited to, my experience:


![Taking Ownership](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/3vr1qvbx0khdexk54red.jpg)
![Work Life Balance](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/ceeb4r5xg31b46zcjzrb.jpg)
![Quality of Work](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/guna9cimjelyeapnlbby.jpg)
![Brand Value and Stability](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/u2xtn8srwcx3krjyqha8.jpg)
![Learning Opportunities](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/y466bv42pwf5qw2pkonn.jpg)
This is what I gathered so far, and this is my attempt to give a clear - even if not exhaustive - picture.

I know for a fact that it is going to be challenging. It is going to be an uphill battle. There will be days when things won't work out as intended. And there will be sleepless nights (as Shharrnam will know :P)

I am glad that [Ankit, Dharin, and Shharrnam](https://analyticsverse.com/about-us/) welcomed me into the team.

But I also know that it will be worth every bit of it. It is going to be fulfilling. It is going to be fun. It is going to be a brilliant learning experience. And I will see a better version of myself on the other side. These are the key factors that helped me in making this choice.
incremental static site generation (ISR) remix
Tags: remix, react, javascript, webdev
Published: 2022-09-03 13:50:26

## To achieve Incremental static site generation in remix
, add the header `Cache-Control: s-maxage=60, stale-while-revalidate` to your responses. 

This tells the CDN to cache for one minute, after that keep sending the stale response while while it revalidates with the origin server
Merge Sort (Simple way to understanding Merge Sort)
Tags: algorithms, dsa, sorting, mergesort
Published: 2022-09-03 13:45:10

We are provided with an array with items and break down this array until each item is separated with each other and sorted. After that, they are merged to return the combined array of items sorted. That’s what merge sort is going to be doing. 
So simple! Let’s get started without further ado.

We start comparing items with each other, if an item is less than another, it goes to the combined array and increment index of the array of that smaller item.

Diagrams below explain well the algorithm used to quickly sort with merge.

![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/zr8r7y97ghtefz0j2vy8.png)

![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/rreakex6v380cgyqttwd.png)

![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/gcgkscf2qr1c3mqezh9t.png)

![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/cs1ea8uhv43vcsvfu785.png)

```
function merge(array1, array2) {
    let combined = []
    let i = 0
    let j = 0
    while(i < array1.length && j < array2.length) {
        if(array1[i] < array2[j]) {
            combined.push(array1[i])
            i++
        } else {
            combined.push(array2[j])
            j++
        }
    }
    while(i < array1.length) {
        combined.push(array1[i])
        i++
    }
    while(j < array2.length) {
        combined.push(array2[j])
        j++
    }
    return combined
}

function mergeSort(array) {
    if(array.length === 1) return array

    let mid = Math.floor(array.length/2)
    let left = array.slice(0,mid)
    let right = array.slice(mid)
    
    return merge(mergeSort(left), mergeSort(right))
}
```

Test Merge sort by calling this function: mergeSort([1,3,7,8,2,4,5,6])
Configure Ubuntu connection via WiFi
Tags: ubuntu
Published: 2022-09-03 13:35:05

Bismillah...

1. edit yaml file `sudo /etc/netplan/00-installer-config-wifi.yaml`

```
# This is the network config written by 'subiquity'
network:
  version: 2
  wifis:
    wlp3s0:
      access-points:
        <wifi.name>:
          password: <wifi.password>
      dhcp4: true
      optional: true
```

2. execute `sudo netplan apply`

3. execute `sudo reboot`
Configure Nginx on Ubuntu
Tags: nginx, ubuntu
Published: 2022-09-03 13:27:46

Bismillah...

1. Go to nginx configuration directory `cd /etc/nginx/sites-enabled`

2. create and edit file `vi myconfig`

```
server {
    listen 443 ssl;
    ssl_certificate /etc/ssl/<server.name>.pem-chain; 
    ssl_certificate_key /etc/ssl/<server.name>.key;
    server_name <server.name>;
    access_log /var/log/nginx/nginx.vhost.access.log;
    error_log /var/log/nginx/nginx.vhost.error.log;
    location / {
        proxy_pass http://localhost:8080;
    }
 }
```

3. reload nginx `sudo service nginx reload`

Done.
OCI Golden Gate Deployment Report files for Extracts and Replicats , here is my new utility !!!
Published: 2022-09-03 13:14:38

OCI Oracle Golden Gate enthusiasts are going to love this.

Here is my next OCI utility I created -- ogg_get_rptfile .sh

Very often as an Oracle Golden Gate Administrator you will have to handle with a lot of OGG Issues , such as process abending , lag in extracts or replicats ,etc. the navigation of Web UI OGG Deployment will be a tedious task , I have created this utility to get all the report files downloaded. This is also a handy utility when you need to get all the report log files for analysis or uploading to MOS SR's

You could pretty much investigate a Golden Gate Deployment without logging into it by getting all the report files downloaded.

Spend more time in Investigation than digging for the logs , this script ogg_get_rptfile .sh will do the digging for you.

https://github.com/abhilash-8/ogg_get_rptfile

PS : Few more such utilities are coming ,


##oracle #oci #oracledatabase #goldengate #curl #api #oraclecloud #oracledba #nabhaas
OCI Oracle Golden Gate utility - get report file downloaded instantly for extracts and replicats for OCI Deployments !!!
Published: 2022-09-03 13:10:01

OCI Oracle Golden Gate enthusiasts are going to love this.



Here is my next OCI utility I created -- ogg_get_rptfile.sh



Very often as an Oracle Golden Gate Administrator you will have to handle with a lot of OGG Issues , such as process abending , lag in extracts or replicats ,etc. the navigation of Web UI OGG Deployment will be a tedious task , I have created this utility to get all the report files downloaded. This is also a handy utility when you need to get all the report log files for analysis or uploading to MOS SR's



You could pretty much investigate a Golden Gate Deployment without logging into it by getting all the report files downloaded.



Spend more time in Investigation than digging for the logs , this script ogg_get_rptfile.sh will do the digging for you.



https://github.com/abhilash-8/ogg_get_rptfile



PS : Few more such utilities are coming ,
Is Railway app more popular than Heroku among developers?
Tags: heroku, railway, cloud, discuss
Published: 2022-09-03 12:58:24


May I know who of you have migrated from heroku to railway app now?

For me, using railway app is very easy for me like heroku.

### Survey of railway app users:
- All you have to do is just comment that  "I am using the railway or railway app".

### Survey of Heroku users:
Or if you're still using heroku,
- Just comment that "I am using heroku".

Feel free to post your other comments on this as well 😊

---

*This post includes affiliate links; 
I may receive compensation if you purchase products or services from the different links provided in this article.*

You can help me by opening account in railway app through this link 😊✨

Link: **https://railway.app?referralCode=jacksonkasi**
Hey I just created my first website
Tags: webdev, javascript, css, html
Published: 2022-09-03 11:25:53

this is my first personal website. It took me around one month to complete this project!!(I know it's a bit long time) but I enjoyed the journey very well. Of course I referred many articles videos and websites for building this web and I learned a lot from them.  After so many sleepless nights, fixing bugs and changing designs, finally I hosted my website on GitHub. Please Take a look at [my website](https://kaarthikrishna.github.io/) . Your valuable suggestions are highly appreciated :)
How can I build a time that changes every second on React.js?!
Tags: javascript, react, vscode, webdev
Published: 2022-09-03 11:11:21

--> The technicals which will use in this program **(React.js, React Hooks - useState).**

_________

The program..
1) add:

`import React, {useState} from "react";`

2) add function which name the same for the file e.g// App

`function App() {`

**setInterval(sayHi, 1000)** --> This function prints sayHi every second, but you will add `setInterval(updatetime, 1000); `

const now = new Date();  --> This is the object for the Date. For example// you can get the hour when you write const now = new Date ().getHours();, but here you want full-time (( hour: min: sec AM/PM )) for that, will use:
`const now = new Date().toLocaleTimeString();`

3) add hooks:

```
const [time,setTime] = useState(now);
```

4) update function time:
 

```
function updatetime() {
    const newtime = new Date().toLocaleTimeString();
    setTime(newtime);
  }
```

5) Program output to the user:
  

```
return(
    <div>
      <h1>{time}</h1>
    </div>
);
```

                 

Final file will be 🎈:


![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/78oq804z6oqdr6bw33ap.png)




![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/khb8eoegei8mj8py70eq.png)




😍
Thank you..
Always read through the Error messages
Published: 2022-09-03 11:06:59

No matter what you call it, exception, error, bug, glitch.....
No matter what interpreter,compiler or magic you use.....
No matter what machine you are on, a server, cloud interface, a phone.....

Read the output generated, all the answers are in the stack trace, trust the brother/sister who has coded before she is at least as you are and he was not for sure someone else has been, The truth is in the stack trace, whom ever seeks it shall find it.......