DATETIME insert year only
Posted on 2009-04-22
I'm in Access. Let's say I have a table Test with one field Year in it. Type is DATETIME. I use this SQL statement: INSERT INTO Test VALUES (1977);
What I get in table is 5/30/1905. Why is that? Is there a SQL statement that would insert year only? Or should I use TEXT instead of DATETIME? But then it would allow for any value in that field; I don't want that. I don't want to use VBA either. What are my options here?
And one more simple question: from what I understand there is no way to create a SQL statement in Access that would drop a table only if it exists, is there? DROP TABLE IF EXISTS Test; not working. No VBA as well.