# Do Not Allow Change in Lot Number (Purchase) if Default Lot Number is specified

**YouTube:** [How to Restrict Lot/ Batch Number Editing When a Default Lot is Specified in Purchase?](https://www.youtube.com/watch?v=_6It1oexJp0)

## How to Restrict Lot/ Batch Number Editing When a Default Lot is Specified in Purchase?

This tutorial explains how to prevent users from changing the **lot number** in a purchase voucher when a **default lot number** has been configured.

***

### **Set Default Lot Number in Purchase Voucher Configuration**

* Open **Purchase Voucher Configuration**.
* Navigate to **Other Settings 2**.
* Locate the option Labeled: **"Default Lot No** **"**
* Specify the **default lot number** to be used during Purchase Entry.

<figure><img src="/files/aBDTVj2AXIXCkH4h1hGt" alt=""><figcaption><p>As shown in the picture, define the <strong>Default LOT Number</strong>.</p></figcaption></figure>

***

### **Access Logic Admin Settings:**

* Open the **Logic Folder** and run **Logic Admin**.
* Go to **Global Settings**.
* Navigate to the **Purchase** tab.
* Locate and enable the option: **"Do Not Allow Change in Lot Number in Purchase if default lot number is specified"**.

<figure><img src="/files/P2AtR2RtMOvH82ZCbhgk" alt=""><figcaption><p>Let's keep this feature enable to observe its impact in Purchase.</p></figcaption></figure>

* Click **Save** to confirm the configuration.
* **Restart the software** to activate the changes.

***

### **Verify Functionality During Purchase Entry**

* Open the **Purchase Voucher** module.
* While making a purchase entry:
  * The **default lot number** will be **automatically selected**.

<figure><img src="/files/mNIeefhNOFj8Y2VX6fmf" alt=""><figcaption><p>As you can see in the image above, the <strong>default LOT Number</strong> has been picked automatically, and you cannot make any changes to it.</p></figcaption></figure>

* The system will **restrict any attempt to modify** the selected lot number.

***

### **Conclusion**

By enabling this setting, you can enforce data consistency and avoid unintended modifications to lot numbers during purchase entries.


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://kb.logicerp.com/logic-erp-learning-hub-tutorials-and-best-practices/user-access/logic-global-admin/purchase/do-not-allow-change-in-lot-number-purchase-if-default-lot-number-is-specified.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
