Apollo Server and MySQL: How to get data direct from the database?

currently I’m writing a GraphQL API with ApolloServer/NodeJS. I have a MySQL Database. Because I’m new at this topic, I dont have any idea how can I get data directly from my database. My api sends article information to the client (this is the only purpose of my api). The client can search a specific article via ID (every article/products has a specific ID in the database. The id which the client is typing in should be compared with the id in the database. So if the id = 1 then the api should look after the article which has the id = 1 in the DATABASE and sends the requested information about THIS article to the client. (I know that this might be better with PHP, but I have some trouble with PHP). But I don’t know how I can write this into my resolver.

NodeJS: Pass field value from ResolverQuery to another JS File

I would like to know, how can I pass a field value of a QueryResolver to another JS File (database.js) in GraphQL and NodeJS/Apollo. In the database.js file I connect with my MYSQL Database with MariaDB and get dynamically data information. The information should be get by the ID which the user enters in the query. The id is know in my QueryResolver but I don’t know how I can pass this ID to my database.js file, so that my user gets the data that he wants.

Graphql React Typescript error binding element ‘currency’ implicitly has an ‘any’ type

I have case like this. I wanna use EXCHANGE_RATES into renderedExchangeRates, but i have got error “Error Message: Binding element ‘currency’ implicitly has an ‘any’ type.”
I know its about type declaration but idont know how to write it correctly on data.rates.map(({ currency, rate }) => (...)).

Retrieving Array from Contentful GraphQL query for page created by slug build error

I’m using React and Contentful to build an app, this uses GraphQL for data querying and I’m trying to retrieve an array on a ‘post’ style page created by the slug. I’m able to pull through static data but I need to be able to display content from a couple of different arrays but I see to be running into either a routing or parsing issue.