Re: Search program by name LIKE %%

Anonymous
Not applicable

Search program by name LIKE %%

Hello,

I need to search programs by name using a query parameter that may not be exactly the name of the program.
Example: Program name is "Search test" and the search name parameter is "Search".

Currently it only finds the program when I input exactly the same name, which is odd, because here http://developers.marketo.com/rest-api/assets/programs/#by_name you can clearly see an example with an incomplete parameter given.

Thanks.

Tags (1)
4 REPLIES 4
SanfordWhiteman
Level 10 - Community Moderator

Re: Search program by name LIKE %%

Numerous examples don't actually work, unfortunately (it seems like some are just the wild imaginings of the tech writer as opposed to being dropped-in code!).

I don't see your example of the partial match. It seems more like request and response are incorrectly paired.

Anonymous
Not applicable

Re: Search program by name LIKE %%

Request:
GET /rest/asset/v1/program/byName.json?name=Search&includeTags=true

Response:

{

  • success: true,
  • errors: [ ],
  • requestId: "16c73#1668935e89e",
  • warnings: [
    • "No assets found for the given search criteria."
    ]

}

Expected response:

{

  • success: true,
  • errors: [ ],
  • requestId: "134ed#16689359fcc",
  • warnings: [ ],
  • result:

    [

    • {
      • id: 1055,
      • name: "Search test",
      • description: "",
      • createdAt: "2018-09-04T14:06:13Z+0000",
      • updatedAt: "2018-10-18T21:42:34Z+0000",
      • url: "https://app-ab24.marketo.com/#ME1055A1",
      • type: "Event",
      • channel: "Live Event",
      • folder: {},
        • type: "Folder",
        • value: 132,
        • folderName: "Marketo Company Int"
      • status: "",
      • workspace: "Default",
      • tags: [ ],
      • costs: [ ],
      • startDate: "2018-09-04T14:00:00.000Z",
      • endDate: "2018-09-04T22:00:00.000Z"
      }

    ]

}

What it seems is that Marketo doesn't have any searching feature for programs. Is that correct?

SanfordWhiteman
Level 10 - Community Moderator

Re: Search program by name LIKE %%

Correct. I'm saying there's no example that specifically shows otherwise (example response is not a partial match to the request, it's a total disjunction).

Anonymous
Not applicable

Re: Search program by name LIKE %%

Oh, ok, I just noticed. Yes, they are not related.

Thanks!