Filter Created in SP REST API












4















I have this code below:



jQuery.ajax({
url: res3 + "/_api/web/lists('" + normlistid + "')/items('" + normid +"')?$select=ID,Title,Created,QuemLeu/Id&$expand=QuemLeu",
method: "GET",
headers: {
"Accept": "application/json; odata=verbose"
},
success: function (data) {
if(data.d){
if(data.d.QuemLeu.results){
for (var i = 0; i < data.d.QuemLeu.results.length; i++){
if(data.d.QuemLeu.results[i].Id == userId){
document.getElementById(itemHTML).style.visibility = 'hidden';
console.log("User Found.");
break;
}
}
}
else
{
console.log("User Not Found");
}
}
},
error: function (error) {
console.log(error);
}
});


How can I filter if the created field (Sharepoint column) is greater than "2018/10/05"?










share|improve this question




















  • 1





    I don't understand you question but if you want to check if Created column is grater then '2018/10/05' (year/month/day?) usenew Date(data.d.Created) > new Date("2018-10-05").

    – Lukas Nespor
    2 days ago
















4















I have this code below:



jQuery.ajax({
url: res3 + "/_api/web/lists('" + normlistid + "')/items('" + normid +"')?$select=ID,Title,Created,QuemLeu/Id&$expand=QuemLeu",
method: "GET",
headers: {
"Accept": "application/json; odata=verbose"
},
success: function (data) {
if(data.d){
if(data.d.QuemLeu.results){
for (var i = 0; i < data.d.QuemLeu.results.length; i++){
if(data.d.QuemLeu.results[i].Id == userId){
document.getElementById(itemHTML).style.visibility = 'hidden';
console.log("User Found.");
break;
}
}
}
else
{
console.log("User Not Found");
}
}
},
error: function (error) {
console.log(error);
}
});


How can I filter if the created field (Sharepoint column) is greater than "2018/10/05"?










share|improve this question




















  • 1





    I don't understand you question but if you want to check if Created column is grater then '2018/10/05' (year/month/day?) usenew Date(data.d.Created) > new Date("2018-10-05").

    – Lukas Nespor
    2 days ago














4












4








4


1






I have this code below:



jQuery.ajax({
url: res3 + "/_api/web/lists('" + normlistid + "')/items('" + normid +"')?$select=ID,Title,Created,QuemLeu/Id&$expand=QuemLeu",
method: "GET",
headers: {
"Accept": "application/json; odata=verbose"
},
success: function (data) {
if(data.d){
if(data.d.QuemLeu.results){
for (var i = 0; i < data.d.QuemLeu.results.length; i++){
if(data.d.QuemLeu.results[i].Id == userId){
document.getElementById(itemHTML).style.visibility = 'hidden';
console.log("User Found.");
break;
}
}
}
else
{
console.log("User Not Found");
}
}
},
error: function (error) {
console.log(error);
}
});


How can I filter if the created field (Sharepoint column) is greater than "2018/10/05"?










share|improve this question
















I have this code below:



jQuery.ajax({
url: res3 + "/_api/web/lists('" + normlistid + "')/items('" + normid +"')?$select=ID,Title,Created,QuemLeu/Id&$expand=QuemLeu",
method: "GET",
headers: {
"Accept": "application/json; odata=verbose"
},
success: function (data) {
if(data.d){
if(data.d.QuemLeu.results){
for (var i = 0; i < data.d.QuemLeu.results.length; i++){
if(data.d.QuemLeu.results[i].Id == userId){
document.getElementById(itemHTML).style.visibility = 'hidden';
console.log("User Found.");
break;
}
}
}
else
{
console.log("User Not Found");
}
}
},
error: function (error) {
console.log(error);
}
});


How can I filter if the created field (Sharepoint column) is greater than "2018/10/05"?







sharepoint-online rest sharepoint-rest-api filter






share|improve this question















share|improve this question













share|improve this question




share|improve this question








edited 2 days ago







KmDroid

















asked 2 days ago









KmDroidKmDroid

406




406








  • 1





    I don't understand you question but if you want to check if Created column is grater then '2018/10/05' (year/month/day?) usenew Date(data.d.Created) > new Date("2018-10-05").

    – Lukas Nespor
    2 days ago














  • 1





    I don't understand you question but if you want to check if Created column is grater then '2018/10/05' (year/month/day?) usenew Date(data.d.Created) > new Date("2018-10-05").

    – Lukas Nespor
    2 days ago








1




1





I don't understand you question but if you want to check if Created column is grater then '2018/10/05' (year/month/day?) usenew Date(data.d.Created) > new Date("2018-10-05").

– Lukas Nespor
2 days ago





I don't understand you question but if you want to check if Created column is grater then '2018/10/05' (year/month/day?) usenew Date(data.d.Created) > new Date("2018-10-05").

– Lukas Nespor
2 days ago










4 Answers
4






active

oldest

votes


















5














SharePoint REST API endpoints take ISO formatted date string for filtering.



Try using below query for filtering on Date Field:





  1. To check greater than "2018/10/05":



    https://[tentat]/sites/[site]/Normativo/ComunicacoesDeNegocio/_api/web/lists('e97f928b-34e4-34e2-c2c7-150ea469fac3')/items?$select=ID,Title,Created,QuemLeu/Id&$expand=QuemLeu&$filter=(Created gt datetime'2018-10-05T00:00:00Z')




  2. To check greater than or equal to "2018/10/05":



    https://[tentat]/sites/[site]/Normativo/ComunicacoesDeNegocio/_api/web/lists('e97f928b-34e4-34e2-c2c7-150ea469fac3')/items?$select=ID,Title,Created,QuemLeu/Id&$expand=QuemLeu&$filter=(Created ge datetime'2018-10-05T00:00:00Z')




Answer For Updated Question:



Add one more IF statement inside if(data.d) like given below:



if(data.d){
if(new Date(data.d.Created) > new Date("2018-10-05")) {
console.log("Items is created after '2018-10-05'");
}else {
console.log("Items is created before '2018-10-05'");
//Add your other code here
}
}





share|improve this answer


























  • Does this works for you?

    – Ganesh Sanap
    2 days ago











  • The thing is I need /items('193')/ to my code working. There is another way?

    – KmDroid
    2 days ago











  • Actually /items('193')/ gives you the single item from list. So you cannot apply filter on such endpoint. Can you tell us what is the exact requirement of yours??

    – Ganesh Sanap
    2 days ago











  • I edited my post

    – KmDroid
    2 days ago











  • Please accept and upvote the answer and create new question instead of editing the existing question as other users have already answered on this question(by reading the original question).

    – Ganesh Sanap
    2 days ago



















3














Just add



&$filter=Created gt '2018-10-05'


At the end of your endpoint



For example:



https://[tentat]/sites/[site]/Normativo/ComunicacoesDeNegocio/_api/web/lists('e97f928b-34e4-34e2-c2c7-150ea469fac3')/items('193')?$select=ID,Title,Created,QuemLeu/Id&$expand=QuemLeu&$filter=Created gt '2018-10-05'


Gt operator means "greater than"



And also you can check all operators below:



Lt (less than)

Le (less than or equal)

Gt (greater than)

Ge (greater than or equal)

Eq (equal to)

Ne (not equal to)





share|improve this answer



















  • 1





    Hello, your filter is not working, is giving me the error "the query is not valid."

    – KmDroid
    2 days ago



















3














Add $filter to your query and use Created gt datetime'2018-10-05T00:00:00' or Created gt '2018-10-05'



/_api/web/lists('guid')/items?$select=ID,Title,Created,QuemLeu/Id&$expand=QuemLeu&$filter=Created gt '2018-10-05'





share|improve this answer





















  • 2





    Hello, your expression is not valid.

    – KmDroid
    2 days ago











  • Yes, you are right. I blindly copied your URL. The issue was with /items('193')/ it has to be only /items/.

    – Lukas Nespor
    2 days ago











  • Hmm, interesting. I did fixed it first and get down vote, awesome :D

    – Lukas Nespor
    2 days ago











  • The thing is I need /items('193')/ to my code working. There is another way?

    – KmDroid
    2 days ago











  • So what do you want to filter? Using /items(193)/ will give you only one item, so there is nothing to filter. Update your question please, because apparently you want something different.

    – Lukas Nespor
    2 days ago





















1














Use filter property $filter=Created gt '2018-10-17'






share|improve this answer





















  • 1





    Hello, your expression seems to be not valid.

    – KmDroid
    2 days ago











  • Now, is giving me "the query is not valid".

    – KmDroid
    2 days ago











  • You use this filter under Items: /_api/web/lists('guid')/items?$filter=Created gt '2018-10-17'

    – Zdeněk Vinduška
    2 days ago











  • The thing is I need /items('193')/ to my code working. There is another way?

    – KmDroid
    2 days ago






  • 1





    So you updated your post and now as I wroted, you need IF statement, cause you only need to check if Created is GT DATE. Thats everything.

    – Zdeněk Vinduška
    2 days ago











Your Answer








StackExchange.ready(function() {
var channelOptions = {
tags: "".split(" "),
id: "232"
};
initTagRenderer("".split(" "), "".split(" "), channelOptions);

StackExchange.using("externalEditor", function() {
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled) {
StackExchange.using("snippets", function() {
createEditor();
});
}
else {
createEditor();
}
});

function createEditor() {
StackExchange.prepareEditor({
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: false,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: null,
bindNavPrevention: true,
postfix: "",
imageUploader: {
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
},
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
});


}
});














draft saved

draft discarded


















StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fsharepoint.stackexchange.com%2fquestions%2f255543%2ffilter-created-in-sp-rest-api%23new-answer', 'question_page');
}
);

Post as a guest















Required, but never shown

























4 Answers
4






active

oldest

votes








4 Answers
4






active

oldest

votes









active

oldest

votes






active

oldest

votes









5














SharePoint REST API endpoints take ISO formatted date string for filtering.



Try using below query for filtering on Date Field:





  1. To check greater than "2018/10/05":



    https://[tentat]/sites/[site]/Normativo/ComunicacoesDeNegocio/_api/web/lists('e97f928b-34e4-34e2-c2c7-150ea469fac3')/items?$select=ID,Title,Created,QuemLeu/Id&$expand=QuemLeu&$filter=(Created gt datetime'2018-10-05T00:00:00Z')




  2. To check greater than or equal to "2018/10/05":



    https://[tentat]/sites/[site]/Normativo/ComunicacoesDeNegocio/_api/web/lists('e97f928b-34e4-34e2-c2c7-150ea469fac3')/items?$select=ID,Title,Created,QuemLeu/Id&$expand=QuemLeu&$filter=(Created ge datetime'2018-10-05T00:00:00Z')




Answer For Updated Question:



Add one more IF statement inside if(data.d) like given below:



if(data.d){
if(new Date(data.d.Created) > new Date("2018-10-05")) {
console.log("Items is created after '2018-10-05'");
}else {
console.log("Items is created before '2018-10-05'");
//Add your other code here
}
}





share|improve this answer


























  • Does this works for you?

    – Ganesh Sanap
    2 days ago











  • The thing is I need /items('193')/ to my code working. There is another way?

    – KmDroid
    2 days ago











  • Actually /items('193')/ gives you the single item from list. So you cannot apply filter on such endpoint. Can you tell us what is the exact requirement of yours??

    – Ganesh Sanap
    2 days ago











  • I edited my post

    – KmDroid
    2 days ago











  • Please accept and upvote the answer and create new question instead of editing the existing question as other users have already answered on this question(by reading the original question).

    – Ganesh Sanap
    2 days ago
















5














SharePoint REST API endpoints take ISO formatted date string for filtering.



Try using below query for filtering on Date Field:





  1. To check greater than "2018/10/05":



    https://[tentat]/sites/[site]/Normativo/ComunicacoesDeNegocio/_api/web/lists('e97f928b-34e4-34e2-c2c7-150ea469fac3')/items?$select=ID,Title,Created,QuemLeu/Id&$expand=QuemLeu&$filter=(Created gt datetime'2018-10-05T00:00:00Z')




  2. To check greater than or equal to "2018/10/05":



    https://[tentat]/sites/[site]/Normativo/ComunicacoesDeNegocio/_api/web/lists('e97f928b-34e4-34e2-c2c7-150ea469fac3')/items?$select=ID,Title,Created,QuemLeu/Id&$expand=QuemLeu&$filter=(Created ge datetime'2018-10-05T00:00:00Z')




Answer For Updated Question:



Add one more IF statement inside if(data.d) like given below:



if(data.d){
if(new Date(data.d.Created) > new Date("2018-10-05")) {
console.log("Items is created after '2018-10-05'");
}else {
console.log("Items is created before '2018-10-05'");
//Add your other code here
}
}





share|improve this answer


























  • Does this works for you?

    – Ganesh Sanap
    2 days ago











  • The thing is I need /items('193')/ to my code working. There is another way?

    – KmDroid
    2 days ago











  • Actually /items('193')/ gives you the single item from list. So you cannot apply filter on such endpoint. Can you tell us what is the exact requirement of yours??

    – Ganesh Sanap
    2 days ago











  • I edited my post

    – KmDroid
    2 days ago











  • Please accept and upvote the answer and create new question instead of editing the existing question as other users have already answered on this question(by reading the original question).

    – Ganesh Sanap
    2 days ago














5












5








5







SharePoint REST API endpoints take ISO formatted date string for filtering.



Try using below query for filtering on Date Field:





  1. To check greater than "2018/10/05":



    https://[tentat]/sites/[site]/Normativo/ComunicacoesDeNegocio/_api/web/lists('e97f928b-34e4-34e2-c2c7-150ea469fac3')/items?$select=ID,Title,Created,QuemLeu/Id&$expand=QuemLeu&$filter=(Created gt datetime'2018-10-05T00:00:00Z')




  2. To check greater than or equal to "2018/10/05":



    https://[tentat]/sites/[site]/Normativo/ComunicacoesDeNegocio/_api/web/lists('e97f928b-34e4-34e2-c2c7-150ea469fac3')/items?$select=ID,Title,Created,QuemLeu/Id&$expand=QuemLeu&$filter=(Created ge datetime'2018-10-05T00:00:00Z')




Answer For Updated Question:



Add one more IF statement inside if(data.d) like given below:



if(data.d){
if(new Date(data.d.Created) > new Date("2018-10-05")) {
console.log("Items is created after '2018-10-05'");
}else {
console.log("Items is created before '2018-10-05'");
//Add your other code here
}
}





share|improve this answer















SharePoint REST API endpoints take ISO formatted date string for filtering.



Try using below query for filtering on Date Field:





  1. To check greater than "2018/10/05":



    https://[tentat]/sites/[site]/Normativo/ComunicacoesDeNegocio/_api/web/lists('e97f928b-34e4-34e2-c2c7-150ea469fac3')/items?$select=ID,Title,Created,QuemLeu/Id&$expand=QuemLeu&$filter=(Created gt datetime'2018-10-05T00:00:00Z')




  2. To check greater than or equal to "2018/10/05":



    https://[tentat]/sites/[site]/Normativo/ComunicacoesDeNegocio/_api/web/lists('e97f928b-34e4-34e2-c2c7-150ea469fac3')/items?$select=ID,Title,Created,QuemLeu/Id&$expand=QuemLeu&$filter=(Created ge datetime'2018-10-05T00:00:00Z')




Answer For Updated Question:



Add one more IF statement inside if(data.d) like given below:



if(data.d){
if(new Date(data.d.Created) > new Date("2018-10-05")) {
console.log("Items is created after '2018-10-05'");
}else {
console.log("Items is created before '2018-10-05'");
//Add your other code here
}
}






share|improve this answer














share|improve this answer



share|improve this answer








edited 2 days ago

























answered 2 days ago









Ganesh SanapGanesh Sanap

2,1403724




2,1403724













  • Does this works for you?

    – Ganesh Sanap
    2 days ago











  • The thing is I need /items('193')/ to my code working. There is another way?

    – KmDroid
    2 days ago











  • Actually /items('193')/ gives you the single item from list. So you cannot apply filter on such endpoint. Can you tell us what is the exact requirement of yours??

    – Ganesh Sanap
    2 days ago











  • I edited my post

    – KmDroid
    2 days ago











  • Please accept and upvote the answer and create new question instead of editing the existing question as other users have already answered on this question(by reading the original question).

    – Ganesh Sanap
    2 days ago



















  • Does this works for you?

    – Ganesh Sanap
    2 days ago











  • The thing is I need /items('193')/ to my code working. There is another way?

    – KmDroid
    2 days ago











  • Actually /items('193')/ gives you the single item from list. So you cannot apply filter on such endpoint. Can you tell us what is the exact requirement of yours??

    – Ganesh Sanap
    2 days ago











  • I edited my post

    – KmDroid
    2 days ago











  • Please accept and upvote the answer and create new question instead of editing the existing question as other users have already answered on this question(by reading the original question).

    – Ganesh Sanap
    2 days ago

















Does this works for you?

– Ganesh Sanap
2 days ago





Does this works for you?

– Ganesh Sanap
2 days ago













The thing is I need /items('193')/ to my code working. There is another way?

– KmDroid
2 days ago





The thing is I need /items('193')/ to my code working. There is another way?

– KmDroid
2 days ago













Actually /items('193')/ gives you the single item from list. So you cannot apply filter on such endpoint. Can you tell us what is the exact requirement of yours??

– Ganesh Sanap
2 days ago





Actually /items('193')/ gives you the single item from list. So you cannot apply filter on such endpoint. Can you tell us what is the exact requirement of yours??

– Ganesh Sanap
2 days ago













I edited my post

– KmDroid
2 days ago





I edited my post

– KmDroid
2 days ago













Please accept and upvote the answer and create new question instead of editing the existing question as other users have already answered on this question(by reading the original question).

– Ganesh Sanap
2 days ago





Please accept and upvote the answer and create new question instead of editing the existing question as other users have already answered on this question(by reading the original question).

– Ganesh Sanap
2 days ago













3














Just add



&$filter=Created gt '2018-10-05'


At the end of your endpoint



For example:



https://[tentat]/sites/[site]/Normativo/ComunicacoesDeNegocio/_api/web/lists('e97f928b-34e4-34e2-c2c7-150ea469fac3')/items('193')?$select=ID,Title,Created,QuemLeu/Id&$expand=QuemLeu&$filter=Created gt '2018-10-05'


Gt operator means "greater than"



And also you can check all operators below:



Lt (less than)

Le (less than or equal)

Gt (greater than)

Ge (greater than or equal)

Eq (equal to)

Ne (not equal to)





share|improve this answer



















  • 1





    Hello, your filter is not working, is giving me the error "the query is not valid."

    – KmDroid
    2 days ago
















3














Just add



&$filter=Created gt '2018-10-05'


At the end of your endpoint



For example:



https://[tentat]/sites/[site]/Normativo/ComunicacoesDeNegocio/_api/web/lists('e97f928b-34e4-34e2-c2c7-150ea469fac3')/items('193')?$select=ID,Title,Created,QuemLeu/Id&$expand=QuemLeu&$filter=Created gt '2018-10-05'


Gt operator means "greater than"



And also you can check all operators below:



Lt (less than)

Le (less than or equal)

Gt (greater than)

Ge (greater than or equal)

Eq (equal to)

Ne (not equal to)





share|improve this answer



















  • 1





    Hello, your filter is not working, is giving me the error "the query is not valid."

    – KmDroid
    2 days ago














3












3








3







Just add



&$filter=Created gt '2018-10-05'


At the end of your endpoint



For example:



https://[tentat]/sites/[site]/Normativo/ComunicacoesDeNegocio/_api/web/lists('e97f928b-34e4-34e2-c2c7-150ea469fac3')/items('193')?$select=ID,Title,Created,QuemLeu/Id&$expand=QuemLeu&$filter=Created gt '2018-10-05'


Gt operator means "greater than"



And also you can check all operators below:



Lt (less than)

Le (less than or equal)

Gt (greater than)

Ge (greater than or equal)

Eq (equal to)

Ne (not equal to)





share|improve this answer













Just add



&$filter=Created gt '2018-10-05'


At the end of your endpoint



For example:



https://[tentat]/sites/[site]/Normativo/ComunicacoesDeNegocio/_api/web/lists('e97f928b-34e4-34e2-c2c7-150ea469fac3')/items('193')?$select=ID,Title,Created,QuemLeu/Id&$expand=QuemLeu&$filter=Created gt '2018-10-05'


Gt operator means "greater than"



And also you can check all operators below:



Lt (less than)

Le (less than or equal)

Gt (greater than)

Ge (greater than or equal)

Eq (equal to)

Ne (not equal to)






share|improve this answer












share|improve this answer



share|improve this answer










answered 2 days ago









Thales ChemenianThales Chemenian

4971312




4971312








  • 1





    Hello, your filter is not working, is giving me the error "the query is not valid."

    – KmDroid
    2 days ago














  • 1





    Hello, your filter is not working, is giving me the error "the query is not valid."

    – KmDroid
    2 days ago








1




1





Hello, your filter is not working, is giving me the error "the query is not valid."

– KmDroid
2 days ago





Hello, your filter is not working, is giving me the error "the query is not valid."

– KmDroid
2 days ago











3














Add $filter to your query and use Created gt datetime'2018-10-05T00:00:00' or Created gt '2018-10-05'



/_api/web/lists('guid')/items?$select=ID,Title,Created,QuemLeu/Id&$expand=QuemLeu&$filter=Created gt '2018-10-05'





share|improve this answer





















  • 2





    Hello, your expression is not valid.

    – KmDroid
    2 days ago











  • Yes, you are right. I blindly copied your URL. The issue was with /items('193')/ it has to be only /items/.

    – Lukas Nespor
    2 days ago











  • Hmm, interesting. I did fixed it first and get down vote, awesome :D

    – Lukas Nespor
    2 days ago











  • The thing is I need /items('193')/ to my code working. There is another way?

    – KmDroid
    2 days ago











  • So what do you want to filter? Using /items(193)/ will give you only one item, so there is nothing to filter. Update your question please, because apparently you want something different.

    – Lukas Nespor
    2 days ago


















3














Add $filter to your query and use Created gt datetime'2018-10-05T00:00:00' or Created gt '2018-10-05'



/_api/web/lists('guid')/items?$select=ID,Title,Created,QuemLeu/Id&$expand=QuemLeu&$filter=Created gt '2018-10-05'





share|improve this answer





















  • 2





    Hello, your expression is not valid.

    – KmDroid
    2 days ago











  • Yes, you are right. I blindly copied your URL. The issue was with /items('193')/ it has to be only /items/.

    – Lukas Nespor
    2 days ago











  • Hmm, interesting. I did fixed it first and get down vote, awesome :D

    – Lukas Nespor
    2 days ago











  • The thing is I need /items('193')/ to my code working. There is another way?

    – KmDroid
    2 days ago











  • So what do you want to filter? Using /items(193)/ will give you only one item, so there is nothing to filter. Update your question please, because apparently you want something different.

    – Lukas Nespor
    2 days ago
















3












3








3







Add $filter to your query and use Created gt datetime'2018-10-05T00:00:00' or Created gt '2018-10-05'



/_api/web/lists('guid')/items?$select=ID,Title,Created,QuemLeu/Id&$expand=QuemLeu&$filter=Created gt '2018-10-05'





share|improve this answer















Add $filter to your query and use Created gt datetime'2018-10-05T00:00:00' or Created gt '2018-10-05'



/_api/web/lists('guid')/items?$select=ID,Title,Created,QuemLeu/Id&$expand=QuemLeu&$filter=Created gt '2018-10-05'






share|improve this answer














share|improve this answer



share|improve this answer








edited 2 days ago

























answered 2 days ago









Lukas NesporLukas Nespor

896315




896315








  • 2





    Hello, your expression is not valid.

    – KmDroid
    2 days ago











  • Yes, you are right. I blindly copied your URL. The issue was with /items('193')/ it has to be only /items/.

    – Lukas Nespor
    2 days ago











  • Hmm, interesting. I did fixed it first and get down vote, awesome :D

    – Lukas Nespor
    2 days ago











  • The thing is I need /items('193')/ to my code working. There is another way?

    – KmDroid
    2 days ago











  • So what do you want to filter? Using /items(193)/ will give you only one item, so there is nothing to filter. Update your question please, because apparently you want something different.

    – Lukas Nespor
    2 days ago
















  • 2





    Hello, your expression is not valid.

    – KmDroid
    2 days ago











  • Yes, you are right. I blindly copied your URL. The issue was with /items('193')/ it has to be only /items/.

    – Lukas Nespor
    2 days ago











  • Hmm, interesting. I did fixed it first and get down vote, awesome :D

    – Lukas Nespor
    2 days ago











  • The thing is I need /items('193')/ to my code working. There is another way?

    – KmDroid
    2 days ago











  • So what do you want to filter? Using /items(193)/ will give you only one item, so there is nothing to filter. Update your question please, because apparently you want something different.

    – Lukas Nespor
    2 days ago










2




2





Hello, your expression is not valid.

– KmDroid
2 days ago





Hello, your expression is not valid.

– KmDroid
2 days ago













Yes, you are right. I blindly copied your URL. The issue was with /items('193')/ it has to be only /items/.

– Lukas Nespor
2 days ago





Yes, you are right. I blindly copied your URL. The issue was with /items('193')/ it has to be only /items/.

– Lukas Nespor
2 days ago













Hmm, interesting. I did fixed it first and get down vote, awesome :D

– Lukas Nespor
2 days ago





Hmm, interesting. I did fixed it first and get down vote, awesome :D

– Lukas Nespor
2 days ago













The thing is I need /items('193')/ to my code working. There is another way?

– KmDroid
2 days ago





The thing is I need /items('193')/ to my code working. There is another way?

– KmDroid
2 days ago













So what do you want to filter? Using /items(193)/ will give you only one item, so there is nothing to filter. Update your question please, because apparently you want something different.

– Lukas Nespor
2 days ago







So what do you want to filter? Using /items(193)/ will give you only one item, so there is nothing to filter. Update your question please, because apparently you want something different.

– Lukas Nespor
2 days ago













1














Use filter property $filter=Created gt '2018-10-17'






share|improve this answer





















  • 1





    Hello, your expression seems to be not valid.

    – KmDroid
    2 days ago











  • Now, is giving me "the query is not valid".

    – KmDroid
    2 days ago











  • You use this filter under Items: /_api/web/lists('guid')/items?$filter=Created gt '2018-10-17'

    – Zdeněk Vinduška
    2 days ago











  • The thing is I need /items('193')/ to my code working. There is another way?

    – KmDroid
    2 days ago






  • 1





    So you updated your post and now as I wroted, you need IF statement, cause you only need to check if Created is GT DATE. Thats everything.

    – Zdeněk Vinduška
    2 days ago
















1














Use filter property $filter=Created gt '2018-10-17'






share|improve this answer





















  • 1





    Hello, your expression seems to be not valid.

    – KmDroid
    2 days ago











  • Now, is giving me "the query is not valid".

    – KmDroid
    2 days ago











  • You use this filter under Items: /_api/web/lists('guid')/items?$filter=Created gt '2018-10-17'

    – Zdeněk Vinduška
    2 days ago











  • The thing is I need /items('193')/ to my code working. There is another way?

    – KmDroid
    2 days ago






  • 1





    So you updated your post and now as I wroted, you need IF statement, cause you only need to check if Created is GT DATE. Thats everything.

    – Zdeněk Vinduška
    2 days ago














1












1








1







Use filter property $filter=Created gt '2018-10-17'






share|improve this answer















Use filter property $filter=Created gt '2018-10-17'







share|improve this answer














share|improve this answer



share|improve this answer








edited 2 days ago

























answered 2 days ago









Zdeněk VinduškaZdeněk Vinduška

421110




421110








  • 1





    Hello, your expression seems to be not valid.

    – KmDroid
    2 days ago











  • Now, is giving me "the query is not valid".

    – KmDroid
    2 days ago











  • You use this filter under Items: /_api/web/lists('guid')/items?$filter=Created gt '2018-10-17'

    – Zdeněk Vinduška
    2 days ago











  • The thing is I need /items('193')/ to my code working. There is another way?

    – KmDroid
    2 days ago






  • 1





    So you updated your post and now as I wroted, you need IF statement, cause you only need to check if Created is GT DATE. Thats everything.

    – Zdeněk Vinduška
    2 days ago














  • 1





    Hello, your expression seems to be not valid.

    – KmDroid
    2 days ago











  • Now, is giving me "the query is not valid".

    – KmDroid
    2 days ago











  • You use this filter under Items: /_api/web/lists('guid')/items?$filter=Created gt '2018-10-17'

    – Zdeněk Vinduška
    2 days ago











  • The thing is I need /items('193')/ to my code working. There is another way?

    – KmDroid
    2 days ago






  • 1





    So you updated your post and now as I wroted, you need IF statement, cause you only need to check if Created is GT DATE. Thats everything.

    – Zdeněk Vinduška
    2 days ago








1




1





Hello, your expression seems to be not valid.

– KmDroid
2 days ago





Hello, your expression seems to be not valid.

– KmDroid
2 days ago













Now, is giving me "the query is not valid".

– KmDroid
2 days ago





Now, is giving me "the query is not valid".

– KmDroid
2 days ago













You use this filter under Items: /_api/web/lists('guid')/items?$filter=Created gt '2018-10-17'

– Zdeněk Vinduška
2 days ago





You use this filter under Items: /_api/web/lists('guid')/items?$filter=Created gt '2018-10-17'

– Zdeněk Vinduška
2 days ago













The thing is I need /items('193')/ to my code working. There is another way?

– KmDroid
2 days ago





The thing is I need /items('193')/ to my code working. There is another way?

– KmDroid
2 days ago




1




1





So you updated your post and now as I wroted, you need IF statement, cause you only need to check if Created is GT DATE. Thats everything.

– Zdeněk Vinduška
2 days ago





So you updated your post and now as I wroted, you need IF statement, cause you only need to check if Created is GT DATE. Thats everything.

– Zdeněk Vinduška
2 days ago


















draft saved

draft discarded




















































Thanks for contributing an answer to SharePoint Stack Exchange!


  • Please be sure to answer the question. Provide details and share your research!

But avoid



  • Asking for help, clarification, or responding to other answers.

  • Making statements based on opinion; back them up with references or personal experience.


To learn more, see our tips on writing great answers.




draft saved


draft discarded














StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fsharepoint.stackexchange.com%2fquestions%2f255543%2ffilter-created-in-sp-rest-api%23new-answer', 'question_page');
}
);

Post as a guest















Required, but never shown





















































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown

































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown







Popular posts from this blog

"Incorrect syntax near the keyword 'ON'. (on update cascade, on delete cascade,)

Alcedinidae

Origin of the phrase “under your belt”?