Options to ignore auto conversion id to _id

XMLWordPrintableJSON

    • None
    • Needed
    • Hide

      1. What would you like to communicate to the user about this feature?

      This setting is for backward compatibility with version < 5.

      2. Would you like the user to see examples of the syntax and/or executable code and its output?

      Maybe, you can check the new tests.

      3. Which versions of the driver/connector does this apply to?

      Laravel-MongoDB 5.3

      Show
      1. What would you like to communicate to the user about this feature? This setting is for backward compatibility with version < 5. 2. Would you like the user to see examples of the syntax and/or executable code and its output? Maybe, you can check the new tests. 3. Which versions of the driver/connector does this apply to? Laravel-MongoDB 5.3
    • None
    • None
    • None
    • None
    • None
    • None

      kbiits has created Issue #3184: [Feature Request] Options to ignore auto conversion id to _id in laravel-mongodb. This Jira ticket was filed by GromNaN

      Issue Text:

      Is your feature request related to a problem?

      We have a `merchant.id` field in our mongodb document, and after upgrading to mongodb driver 5.1 we encountered issue that mongodb driver modify the where query from `merchant.id` to `merchant._id` which results to unexpected query

      Describe the solution you'd like

      It would be good if there's mechanism to whitelisting the fields from auto conversion `.id` to `._id`

      Describe alternatives you've considered

      -

      Additional context

      This part of code modify all `.id` to `._id`
      <img width="931" alt="image" src="https://github.com/user-attachments/assets/c4aba8a0-aa18-4098-96e7-2134b6eed26b">

              Assignee:
              Jérôme Tamarelle
              Reporter:
              TPM Jira Automations Bot
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

                Created:
                Updated:
                Resolved:

                  Estimated:
                  Original Estimate - 1 week
                  1w
                  Remaining:
                  Remaining Estimate - 1 week
                  1w
                  Logged:
                  Time Spent - Not Specified
                  Not Specified