473,383 Members | 1,868 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,383 software developers and data experts.

Inventory Problem - Field Validation

12
Here's the deal. I receive parts from one company, refurb them, and then send them back. So, they send me 10 parts on one MSO#, which is like a PO#, and I can only ship back a max of 10 parts that refer to that MSO#. What I need to do is limit a quantity field on a form so that I don't send back more parts than I receive on my MSO.

I've created a query that returns the maximum amount I can send back based on the MSO#.

How do you tie the quantity field on my form to the number I have in my query so that whatever quantity someone inputs in the quantity field does not exceed the number from the query? I've tried to using validation but haven't be able to make it work. I've also used the expression builder without success.
Sep 15 '08 #1
3 1547
glitke
12
Here's the expression I used in the "Validation Rule" but it doesn't like.

<=(Sum(([T - Main Frame]![Quantity]) WHERE ((([T - Main Frame]![Status] = "Received") OR ([T - Main Frame]![Status] = "Shipped") OR ([T - Main Frame]![Status] = "Scrapped")) AND ([T - Main Frame]![Part #] = [Part #]) AND ([T - Main Frame]![MSO #] = [MSO #])))))

After I created the Query I tried this:

<=([Q - Limit Quantity]![SumofQuantity])

Am I trying to do this the right way? Or is there another route that will work? What "syntax" am I using that isn't usable in "Validation Rules"?
Sep 15 '08 #2
NeoPa
32,556 Expert Mod 16PB
If you can post the data you're working with (the SQL of the query may be enough) then we will have something to work from.

While MSO# & PO# do give clues as to the type of data you're working with, it's very little help explaining what context you're starting from and we need to think within.
Sep 15 '08 #3
NeoPa
32,556 Expert Mod 16PB
This thread is now discontinued (locked) as another version has been posted (Validation Error - Invalid Syntax - Operand w/o operator).

Glitke did try to delete this thread to keep things tidy but was unable to.
Sep 16 '08 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

4
by: Oleg | last post by:
Hi, Not really a PHP specific question, but I am using PHP on Linux box so it's kinda relevant. I'm developing a site which will periodically update inventory via a large batch file. I'm...
2
by: Kenneth Courville | last post by:
Hello, I'm looking for a little input on this situation. I'm working on an inventory system and was thinking that I'd like to build it similiar to the way a bank keeps track of your funds. If...
7
by: simon | last post by:
Hi I know this has been done to death....but obviously at some point in the dim and distant past! I wish to program a retail database for my shop, I have trawled many forums and I only manage...
2
by: Doslil | last post by:
I am trying to validate the fields in my database.I have already validated the fields to check for not null.Here is what I have written for Numeric and text field. Private Function EENUM() On...
2
by: Norma | last post by:
I hope that someone will be able to help with this problem. It is probably an easy fix for mose of you so bear with me... I have 2 tables for this. One has item # and InventoryAmount. The other...
2
by: DS | last post by:
Hi, I'm building an Inventory form. I have a Product Form and ono that form I want to place a sub-form showing the sold products along with the Products that were received. I have a calculated...
5
by: tHeRoBeRtMiTcHeLL | last post by:
Well, I think I have bitten off a little more than I can chew (at least all at once), and I'm only trying to hammer out tables/relationships at the design level. Which translates to "Seasoned...
14
by: pietlinden | last post by:
Hi, Stupid question, but here goes. Someone wants me to design a database to keep track of fuel deliveries and orders/shipments. Essentially, he'll purchase fuel from some supplier and then...
10
by: mistb2002 | last post by:
I am trying to modify my program to add and delete inventory items. I tried just adding but I am getting mutliple errors help. This is what my program currently looks like // Display The...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.