<?xml version="1.0" encoding="utf-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
	<channel>
		<title><![CDATA[My Visual Database — Need help with adding calculated field or may be adding extra column?]]></title>
		<link>https://myvisualdatabase.com/forum/viewtopic.php?id=8937</link>
		<atom:link href="https://myvisualdatabase.com/forum/extern.php?action=feed&amp;tid=8937&amp;type=rss" rel="self" type="application/rss+xml" />
		<description><![CDATA[The most recent posts in Need help with adding calculated field or may be adding extra column?.]]></description>
		<lastBuildDate>Wed, 08 May 2024 10:13:53 +0000</lastBuildDate>
		<generator>PunBB</generator>
		<item>
			<title><![CDATA[Re: Need help with adding calculated field or may be adding extra column?]]></title>
			<link>https://myvisualdatabase.com/forum/viewtopic.php?pid=50845#p50845</link>
			<description><![CDATA[<p>thank you @derek I am still learning from your small script.</p><p>For now not implementing cascade delete - but created example and tested it how it works.</p><p>Refining whole project again. and working on reports designing.</p>]]></description>
			<author><![CDATA[null@example.com (kavinacomputers)]]></author>
			<pubDate>Wed, 08 May 2024 10:13:53 +0000</pubDate>
			<guid>https://myvisualdatabase.com/forum/viewtopic.php?pid=50845#p50845</guid>
		</item>
		<item>
			<title><![CDATA[Re: Need help with adding calculated field or may be adding extra column?]]></title>
			<link>https://myvisualdatabase.com/forum/viewtopic.php?pid=50835#p50835</link>
			<description><![CDATA[<p>Hi,<br />I&#039;m not sure if I understand all your points correctly but hopefully the following will make sense.<br />1.<br />I was looking at your data schema and would suggest instead of using a flag (is_inward = yes), you could just use a positive quantity and for is_inward = no, just use a negative quantity.&nbsp; <br />Personally I think this would be less confusing (and is one less thing for the user to input).<br />2.<br />The stock balance is already being calculated so Instead of &#039;is_open = no&#039;, just replace this with an automatic check whether &#039;stock balance = 0&#039;.&nbsp; You could also add a flag using a calculated field to show, for example if a job is &#039;not started&#039;, &#039;in progress&#039; or &#039;finished&#039; to make it even more obvious.<br />3. <br />With regard to your question about parent-child tablegrids, have a look at the attachment;&nbsp; form1.tablegrid2 and form1.tablegrid3 are both &#039;child&#039; tablegrids of form1.tablegrid1.&nbsp; Click in any row of tablegrid1 to see the associated &#039;child&#039; transactions.&nbsp; I&#039;ve chosen to split &#039;inwards&#039; and &#039;outwards&#039; transactions into two child tables but it&#039;s up to you how you best want to see the information.<br />4.<br />Cascade / delete is theoretically a good idea if you want to keep your data tidy.. However, if you have a lot of tables with relationships, you can end up deleting data that you might need without realising it.&nbsp; <br />But more importantly, if your application is to be used commercially, there might be legal requirements (depending on your country) to maintain all data and not delete anything.<br />If you&#039;re considering using cascade / delete from a business process point of view because, for example, there is a product that you no longer use, it&#039;s perhaps a better idea to add a &#039;do not use&#039; flag to the appropriate table so that it can be automatically excluded from any subsequent transactions..<br />5.&nbsp; Concerning your point about multiple transactions on the same day, you might want to consider re-defining your transaction date from a field type of &#039;date&#039; to a field type of &#039;date/time&#039;.<br />.<br />The attached project hopefully clarifies some of the above points.&nbsp; Also, perhaps it gives you some ideas of how your project might develop once you get more familiar with MVD.&nbsp; As always with MVD there are lots of different ways to do things and this isn&#039;t to say that one way is correct and another way is incorrect - it&#039;s more just to show you options.<br />There is a (relatively) small script attached to the project but this is more to do with a) the &#039;look and feel&#039; and b) to add some validation rather than the basic functionality which can be done using standard MVD.<br />If anything is not clear, just shout.<br />Derek.</p>]]></description>
			<author><![CDATA[null@example.com (derek)]]></author>
			<pubDate>Mon, 06 May 2024 17:48:56 +0000</pubDate>
			<guid>https://myvisualdatabase.com/forum/viewtopic.php?pid=50835#p50835</guid>
		</item>
		<item>
			<title><![CDATA[Re: Need help with adding calculated field or may be adding extra column?]]></title>
			<link>https://myvisualdatabase.com/forum/viewtopic.php?pid=50829#p50829</link>
			<description><![CDATA[<p>Logic behind using is_inward and is_open</p><p>Example <br />client gives 25 rolls of fabric total 25000 meters for printing - <br />inward transaction is_inward = yes and is_ open=yes for transections.</p><p>2 rolls printed today and given back to client total meters 2000.<br />outward transection is_inward = no and is_open=yes stock is available open for transections.</p><p>23 rolls printed another days and 23000 meters given back to client.<br />outward transection is_inward = no and is_open=no - no stock left to do transections. </p><p>tra_close will show that closed inward and outward - stock came - printed - outward done. task finished<br />at this point if both flag is no - outward not allowed</p><p>hope I explained properly</p><p>@derek</p><br /><p>I have few more qustions</p><p>1) when I was reading book dgs filter catalogue page 46</p><p>there was a concept called parent-child in tablegrid</p><p>is that&nbsp; good idea to incorporate in project also what about cascade delete.</p><br /><p>2) same example as above</p><p>Supplier/Client (MAIN parent) gives bill (one to many relationship) <br />add bill no(child(parent of bill multiple entries)) <br />multiple bill entries(child(parent of transections).</p><p>cascade delete will be good idea here?</p><p>3)I am confuse here how to go about it?</p><p>multiple outward&nbsp; can happen in one day or multiple time in month. how to achieve this<br />d-0001 - 2024-05-04<br />d-0002 - 2024-05-04<br />...................<br />.....<br />d-000n - 2024-05-04</p><p>same client merge all bills.<br />m-0001 - bill for May month. mention all the entries done. In month and all the total amount and taxes.</p><p>I will track q_out and q_in as per your suggestion.</p>]]></description>
			<author><![CDATA[null@example.com (kavinacomputers)]]></author>
			<pubDate>Sun, 05 May 2024 04:19:44 +0000</pubDate>
			<guid>https://myvisualdatabase.com/forum/viewtopic.php?pid=50829#p50829</guid>
		</item>
		<item>
			<title><![CDATA[Re: Need help with adding calculated field or may be adding extra column?]]></title>
			<link>https://myvisualdatabase.com/forum/viewtopic.php?pid=50826#p50826</link>
			<description><![CDATA[<p>Hi,<br />Looking at the screen shot in your attachment, I would use calculated fields to display the &#039;in&#039;, &#039;out&#039; and &#039;stock in hand&#039; balances per product for each supplier (please see attached as an example of how to create your calculated fields).&nbsp; <br />I haven&#039;t added a calculated field for &#039;tra close&#039; because I can&#039;t work out from your attachment what this is but the principle, in terms of indicating it with a calculated field, is the same as for the other calculated fields.<br />I have also added two calculated fields on your &#039;transactions&#039; table to show &#039;quantity in&#039; and &#039;quantity out&#039; rather than just using one table field with an indicator as you are currently doing.&nbsp; Moving forward, you might consider creating discrete fields (&#039;quantity in&#039;, &#039;quantity out&#039;) as this is perhaps more user-friendly than having just one field (&#039;quantity&#039;_ and using an indicator (&#039;is_inward&#039;).&nbsp; But these are just suggestions.<br />Regards,<br />Derek.</p>]]></description>
			<author><![CDATA[null@example.com (derek)]]></author>
			<pubDate>Sat, 04 May 2024 15:13:51 +0000</pubDate>
			<guid>https://myvisualdatabase.com/forum/viewtopic.php?pid=50826#p50826</guid>
		</item>
		<item>
			<title><![CDATA[Need help with adding calculated field or may be adding extra column?]]></title>
			<link>https://myvisualdatabase.com/forum/viewtopic.php?pid=50823#p50823</link>
			<description><![CDATA[<p>Not sure on this if there is a way to do add column <br />Or calculated field.</p><p>Working with this very small project and learning.</p><p>attached project is iteration of 4th revision. and now I am doing chunks only. and lot of normalization.<br />from 16 tables to 5 tables. (that was fun - 32 forms)</p><p>I need help with populating column.</p><p>image is in zip file what I am trying to do.</p><p>Thanks in advance.</p>]]></description>
			<author><![CDATA[null@example.com (kavinacomputers)]]></author>
			<pubDate>Sat, 04 May 2024 04:39:43 +0000</pubDate>
			<guid>https://myvisualdatabase.com/forum/viewtopic.php?pid=50823#p50823</guid>
		</item>
	</channel>
</rss>
