<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"><channel><category>pcsoft.us.windev</category><copyright>Copyright 2026, PC SOFT</copyright><lastBuildDate>4 Dec 2015 13:39:00 Z</lastBuildDate><pubDate>4 Dec 2015 11:35:00 Z</pubDate><description>Hi,&#13;
&#13;
I have a SQL-coding problem and would like to ask for tips.&#13;
&#13;
I have 2 files TblBox and TblBoxMutatie like in the picture, with a 1:n relation, so one TblBox can have several TblBoxMutatie records:&#13;
&#13;
&#13;
&#13;
I would like to create a list of unique TblBox-records with items TblBoxID, Boxnummer, TblKaastypeID and the items TblBoxMutatieID, TblLocatieID, Mutatietijd from file TblBoxMutatie, but for each TblBox-record only using 1 TblBoxMutatie-record. Depending on a parameter pardtDateTime (containing a datetime value) I want the TblBoxMutatie-record with the highest Mutatietijd value before this parameter value.&#13;
&#13;
I've tried already. I can get the highest TblBoxMutatie.Mutatietijd value per TblBox, but I cannot get more items from that same TblBoxMutatie record.&#13;
&#13;
Someone can help me with the best way to get this via SQL, if possible ?</description><ttl>30</ttl><generator>WEBDEV</generator><language>en_US</language><link>https://forum.pcsoft.fr/es-ES/pcsoft.us.windev/55303-sql-question/read.awp</link><title>[OT] SQL question</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/55303-sql-question-55308/read.awp</comments><pubDate>4 Dec 2015 13:39:00 Z</pubDate><description>Hi Paulo,&#13;
&#13;
this works indeed. Thank you for your effort.</description><guid isPermaLink="true">https://forum.pcsoft.fr/es-ES/pcsoft.us.windev/55303-sql-question-55308/read.awp</guid><link>https://forum.pcsoft.fr/es-ES/pcsoft.us.windev/55303-sql-question-55308/read.awp</link><source url="https://forum.pcsoft.fr/es-ES/pcsoft.us.windev/55303-sql-question/read.awp">[OT] SQL question</source><title>Re: [OT] SQL question</title></item><item><author>guest</author><category>pcsoft.us.windev</category><comments>https://forum.pcsoft.fr/es-ES/pcsoft.us.windev/55303-sql-question-55307/read.awp</comments><pubDate>4 Dec 2015 12:41:00 Z</pubDate><description>try with something like this (not tested):&#13;
&#13;
Select TblBoxID, Boxnummer, TblKaastypeID,TblLocatieID, Mutatietijd&#13;
from TblBox&#13;
…</description><guid isPermaLink="true">https://forum.pcsoft.fr/es-ES/pcsoft.us.windev/55303-sql-question-55307/read.awp</guid><link>https://forum.pcsoft.fr/es-ES/pcsoft.us.windev/55303-sql-question-55307/read.awp</link><source url="https://forum.pcsoft.fr/es-ES/pcsoft.us.windev/55303-sql-question/read.awp">[OT] SQL question</source><title>Re: [OT] SQL question</title></item></channel></rss>
