Thursday, March 19, 2020

Decline of Indus Valley Civilization Essays

Decline of Indus Valley Civilization Essays Decline of Indus Valley Civilization Paper Decline of Indus Valley Civilization Paper Essay Topic: The Long Valley The decline of the Indus Valley Civilization, also known as the Harpoon Civilization, was caused by both environmental and cultural factors. Spanning across the Indian subcontinent, the Indus River Valley Civilization was a strong society. There was a good agricultural system that allowed the cultivation of wheat, rye, and vegetables. There was also a prominent cultural and religious presence. The civilization also had a strong government that was ruled by priests from each city. Unfortunately, like many other ancient civilizations, the traits that made the Indus Valley Civilization strong were also the reasons for its decline. The civilization relied on the river to sustain them. Monsoon rains would replenish the river and ground every year allowing them to have an efficient agricultural system. However, the monsoon rains declined and this adversely affected the culture. Due to the lack of replenishment the river system was weakened and there was no longer any flooding to irrigate the land. This event was a major contributor to the collapse of the civilization because they could no longer sustain themselves. Another factor of the civilizations decline, which was also caused by the drought, was the decrease in trade between Mesopotamia and Egypt. As the river system weakened they were not able to trade as easily with the other civilizations. Additional reasons that lead to the decline were temperature and climate changes, geographical changes caused by movement in the tectonic plates, and other natural disasters. Although some people dated, it is also evident that many people began migrating out of this area? probably with the intention of seeking out fertile land. As the Indus Valley Civilization slowly declined, a group of warlike nomadic people from central Asia, called the Aryans, began Invading and settling Into the land. This led to the creation of the Indo-Aryan culture. The Indo-Aryans had a warrior culture that sustained Itself on livestock rather than the agriculture system of other groups. Their culture survived through oral tradition and was eventually recorded In the Veda.

Tuesday, March 3, 2020

Time Values for Access SQL in Delphi

Format Date/Time Values for Access SQL in Delphi Ever get the awful Parameter object is improperly defined. Inconsistent or incomplete information was provided JET error? Heres how to rectify the situation. When you need to create a SQL query against ​an Access database where a date (or a date time) value is used you need to make sure the correct formatting is used. For example, in a SQL query: SELECT * FROM TBL WHERE DateField 10/12/2008 you want to get all the records from the table named TBL where a general date field DateField equals 10/12/2008. Is the line above clear? Is that December, 10 or October, 12? Luckily, we are pretty sure the year in the query is 2008. Should the date part of the query be specified as MM/DD/YYYY or DD/MM/YYYY or maybe YYYYMMDD? And do regional settings play a role here? MS Access, Jet, Date Time Formatting When using Access and JET (dbGo - ADO Delphi controls) the formatting of the SQL for the date field should *always* be: #YYYY-MM-DD# Anything else might work in limited testing but can often lead to unexpected results or errors on the users machine. Heres a custom Delphi function you can use to format a date value for the Access SQL query. function DateForSQL(const date : TDate) : string;var   Ã‚  y, m, d : word; begin   Ã‚  DecodeDate(date, y, m, d) ;   Ã‚  result : Format(#%.*d-%.*d-%.*d#,[4, y, 2, m, 2, d]) ; end; For January 29, 1973 the function will return the string #1973-01-29#. Access SQL Date Time Format? As for the date and time formatting, the general format is: #yyyy-mm-dd HH:MM:SS# This is: #year-month-daySPACEhour:minute:second# As soon as you construct a valid date time string for the SQL using the above general format and try it using any of Delphis dataset components as TADOQuery, you will receive the awful Parameter object is improperly defined. Inconsistent or incomplete information was provided error at run-time! The problem with the format above is in the : character - as it is used for parameters in parametrized Delphi queries. As in ... WHERE DateField :dateValue - here dateValue is a parameter and the : is used to mark it. One way to fix the error is to use another format for date/time (replace : with .): #yyyy-mm-dd HH.MM.SS# And heres a custom Delphi function to return a string from a date time value you can use when constructing SQL queries for Access where you need to search for a date-time value: function DateTimeForSQL(const dateTime : TDateTime) : string;var   Ã‚  y, m, d : word;   Ã‚  hour, min, sec, msec : word; begin   Ã‚  DecodeDate(dateTime, y, m, d) ;   Ã‚  DecodeTime(dateTime, hour, min, sec, msec) ;   Ã‚  result : Format(#%.*d-%.*d-%.*d %.*d.%.*d.%.*d#,[4, y, 2, m, 2, d, 2, hour, 2, min, 2, sec]) ; end; The format looks weird but will result in the correctly formatted date time string value to be used in SQL queries! Heres a shorter version using the FormatDateTime routine: function DateTimeForSQL(const dateTime : TDateTime) : string;begin   Ã‚  result : FormatDateTime(#yyyy-mm-dd hh.nn.ss#, dateTime) ; end;