We can make some requests to the server using both Query and Mutation. In these queries we can pass some params and we will get some results from the server in both cases. The only one obligatory difference is that we can call the mutation from our props like "this.props.mutation", but it looks like a syntax sugar, because we can wrap our HOC in "withApollo" and we'll receive "query" method in props too. So what is the main difference between these two types of requests?
difference between Query and Mutation in Apollo?
1k Views Asked by Zheka Dzecina At
1
There are 1 best solutions below
Related Questions in APOLLO
- use message driven bean to get message from topic apache apollo
- How to fetch data with apollo and react native
- how to update a query props.data after a query onClick
- How to create service for angular2 + apollo-client with graphql
- Apache Apollo - java and stomp-websocket connecting to the same topic
- SEND frame fails if it is in a transaction (STOMP)
- How to pass array in Lokka mutation?
- How to send GraphQL mutation from one server to another?
- How to force Apollo Client to use cached data
- Apollo Client Write Query Not Updating UI
- Dispatching actions in Redux while using Apollo Client causes Apollo client to reset query
- Apollo graphql-connected React component isn't rerendering
- Apollo client: mutate is not a function
- id cannot be used in graphQL where clause?
- Invalid variable referenced in @include directive
Related Questions in REACT-APOLLO
- Getting checksum invalid warning when using apollo client isomorphically with react starter kit
- How to view client markup to debug checksum errors in react
- ApolloClient.query with fragment gives error on react-native
- How to fetch data with apollo and react native
- how to update a query props.data after a query onClick
- How to pass variables to a GraphQL query?
- How to force Apollo Client to use cached data
- Request Graphql api running on different port from Next.js app in development mode localhost
- Apollo Client Write Query Not Updating UI
- How to reuse fiedls in graphql queries
- Dispatching actions in Redux while using Apollo Client causes Apollo client to reset query
- invoking Query of GraphQL of Apollo Client
- Apollo breaks when a client is stated in a mutation
- React Apollo MockProvider always loading, never giving data
- Dispatch redux action after apollo-react query
Related Questions in APOLLO-CLIENT
- NativeScript with ApolloClient issue
- How to pass array in Lokka mutation?
- How to force Apollo Client to use cached data
- Request Graphql api running on different port from Next.js app in development mode localhost
- Dispatching actions in Redux while using Apollo Client causes Apollo client to reset query
- Apollo graphql-connected React component isn't rerendering
- Apollo client: mutate is not a function
- Invalid variable referenced in @include directive
- Apollo breaks when a client is stated in a mutation
- appbar responsive with options with react router v4, material-ui and apollo client
- All GraphQL Scalars coming up as String (Apollo)
- Apollo GraphQL: How to Set Up Secure Websockets?
- How to merge graphQL fragments for request with apollo client
- creation react component for apollo client, simple model with object parameters
- Calling a graphQL query from within react client
Related Questions in APOLLO-SERVER
- Keep two values in sync when data changes
- In Apollo GraphQL, how do I setup a resolver to not loop values?
- Apollo: Required Shape of Server Response?
- GraphQL redirect when resolver throws error
- How to design the following resolver for GraphQL server?
- function with parameters inside an object
- Setting up auth0 with apollo server
- Apollo GraphQL: How to Set Up Secure Websockets?
- Apollo GraphQL: Setting Port for HTTPBatchedNetworkInterface?
- How do I represent Neo4j relationship properties in my Graphql Schema?
- Apollo resetStore is not working in Angular client
- How to run nodejs with apollo graphql server
- GraphQL nested query arguments?
- How to debug my really slow resolver connected to Firebase Realtime Database?
- Graphql playground stuck at loading when accessing my server in heroku
Related Questions in APOLLOSTACK
- In Apollo GraphQL, how do I setup a resolver to not loop values?
- how to update a query props.data after a query onClick
- Apollo: Required Shape of Server Response?
- Apollo GraphQL: How to Insert Mutated Object at Correct Index in Existing Array?
- NativeScript with ApolloClient issue
- Apollo GraphQL: Setting Port for HTTPBatchedNetworkInterface?
- How to delete cache record from Apollo GraphQL client with readQuery and writeQuery
- How can I make managed federation work offline?
- Apollo Server - Confusion about cache/datasource options
- Apollo typepolicies how to read sibling field of Query?
- Why when I upload file with apollo-server the file is uploaded but the file is 0kb?
- difference between Query and Mutation in Apollo?
- Having trouble using graphql's fragments with Apollo
- Apollo GraphQL: Can One Query Support Lookup Different Lookup Fields?
- Apollo Link State Default Resolver Not Working (@client query parameter variables)
Trending Questions
- UIImageView Frame Doesn't Reflect Constraints
- Is it possible to use adb commands to click on a view by finding its ID?
- How to create a new web character symbol recognizable by html/javascript?
- Why isn't my CSS3 animation smooth in Google Chrome (but very smooth on other browsers)?
- Heap Gives Page Fault
- Connect ffmpeg to Visual Studio 2008
- Both Object- and ValueAnimator jumps when Duration is set above API LvL 24
- How to avoid default initialization of objects in std::vector?
- second argument of the command line arguments in a format other than char** argv or char* argv[]
- How to improve efficiency of algorithm which generates next lexicographic permutation?
- Navigating to the another actvity app getting crash in android
- How to read the particular message format in android and store in sqlite database?
- Resetting inventory status after order is cancelled
- Efficiently compute powers of X in SSE/AVX
- Insert into an external database using ajax and php : POST 500 (Internal Server Error)
Popular Questions
- How do I undo the most recent local commits in Git?
- How can I remove a specific item from an array in JavaScript?
- How do I delete a Git branch locally and remotely?
- Find all files containing a specific text (string) on Linux?
- How do I revert a Git repository to a previous commit?
- How do I create an HTML button that acts like a link?
- How do I check out a remote Git branch?
- How do I force "git pull" to overwrite local files?
- How do I list all files of a directory?
- How to check whether a string contains a substring in JavaScript?
- How do I redirect to another webpage?
- How can I iterate over rows in a Pandas DataFrame?
- How do I convert a String to an int in Java?
- Does Python have a string 'contains' substring method?
- How do I check if a string contains a specific word?
Strictly speaking there is no difference.
However, the reference implementation does enforce the following.
Both quotes can be found from the links below.
http://graphql.org/learn/queries/#mutations
http://graphql.org/learn/queries/#multiple-fields-in-mutations