<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"><channel><category>pcsoft.us.windev</category><copyright>Copyright 2026, PC SOFT</copyright><lastBuildDate>17 Oct 2017 06:10:00 Z</lastBuildDate><pubDate>16 Oct 2017 14:31:00 Z</pubDate><description>Hello,&#13;
&#13;
I have a table whose structure is:&#13;
p_product_id p_weight p_rate&#13;
This table contains following data:&#13;
p_product_id p_weight p_rate 1 0.250 1 1 0.500 4 1 0.750 7 1 0.900 7.5 1 1.000 10 2 0.250 2 2 0.500 3 2 1.150 10.5 3 0.700 6.5 3 0.900 7.5&#13;
&#13;
Now when a user enters Weight I need to find the rate applicable.&#13;
&#13;
So if user enters weight of 0.600 then based on the product selected the rate applicable is that of 0.750 that is 7&#13;
&#13;
What query should I use for retrieving this rate?&#13;
&#13;
TIA</description><ttl>30</ttl><generator>WEBDEV</generator><language>en_US</language><link>https://forum.pcsoft.fr/es-ES/pcsoft.us.windev/62953-how-retrive-values-based-slabs/read.awp</link><title>How to retrive values based on Slabs</title><managingEditor>moderateur@pcsoft.fr (El moderador)</managingEditor><webMaster>webmaster@pcsoft.fr (El webmaster)</webMaster><item><author>guest</author><category>pcsoft.us.windev</category><comments>https://forum.pcsoft.fr/es-ES/pcsoft.us.windev/62953-how-retrive-values-based-slabs-62968/read.awp</comments><pubDate>17 Oct 2017 06:10:00 Z</pubDate><description>Sascha,&#13;
&#13;
Quote&#13;
Sascha77&#13;
&#13;
if your logic needs to be the perfect match or take the next higher weight this query should do th…</description><guid isPermaLink="true">https://forum.pcsoft.fr/es-ES/pcsoft.us.windev/62953-how-retrive-values-based-slabs-62968/read.awp</guid><link>https://forum.pcsoft.fr/es-ES/pcsoft.us.windev/62953-how-retrive-values-based-slabs-62968/read.awp</link><source url="https://forum.pcsoft.fr/es-ES/pcsoft.us.windev/62953-how-retrive-values-based-slabs/read.awp">How to retrive values based on Slabs</source><title>Re: How to retrive values based on Slabs</title></item><item><author>guest</author><category>pcsoft.us.windev</category><comments>https://forum.pcsoft.fr/es-ES/pcsoft.us.windev/62953-how-retrive-values-based-slabs-62955/read.awp</comments><pubDate>16 Oct 2017 15:01:00 Z</pubDate><description>Yogi,&#13;
&#13;
if your logic needs to be the perfect match or take the next higher weight this query should do the trick.&#13;
&#13;
select * …</description><guid isPermaLink="true">https://forum.pcsoft.fr/es-ES/pcsoft.us.windev/62953-how-retrive-values-based-slabs-62955/read.awp</guid><link>https://forum.pcsoft.fr/es-ES/pcsoft.us.windev/62953-how-retrive-values-based-slabs-62955/read.awp</link><source url="https://forum.pcsoft.fr/es-ES/pcsoft.us.windev/62953-how-retrive-values-based-slabs/read.awp">How to retrive values based on Slabs</source><title>Re: How to retrive values based on Slabs</title></item><item><author>guest</author><category>pcsoft.us.windev</category><comments>https://forum.pcsoft.fr/es-ES/pcsoft.us.windev/62953-how-retrive-values-based-slabs-62954/read.awp</comments><pubDate>16 Oct 2017 15:00:00 Z</pubDate><description>Not tested but try something like this:&#13;
&#13;
select s.p_rate from your_table s&#13;
where s.p_product_id=the produtct you need&#13;
and s.…</description><guid isPermaLink="true">https://forum.pcsoft.fr/es-ES/pcsoft.us.windev/62953-how-retrive-values-based-slabs-62954/read.awp</guid><link>https://forum.pcsoft.fr/es-ES/pcsoft.us.windev/62953-how-retrive-values-based-slabs-62954/read.awp</link><source url="https://forum.pcsoft.fr/es-ES/pcsoft.us.windev/62953-how-retrive-values-based-slabs/read.awp">How to retrive values based on Slabs</source><title>Re: How to retrive values based on Slabs</title></item></channel></rss>
